{"name":"position","title":"position","type":"command","url":"https://community.bistudio.com/wiki/position","revid":377525,"updated":"2026-01-02T06:52:45Z","groups":["Positions"],"status":"ok","games":{"ofp":null,"arma1":"1.00","arma2":"1.00","arma2oa":"1.50","tkoh":"1.00","arma3":"0.50"},"since":"ofp","arma3_since":"0.50","description":"Returns position of an object (alias of getPos) or location (alias of locationPosition).\n\n> [!IMPORTANT]\n> Do **not** use this command to get an object's position in 3D. See getPos for an explanation and alternatives.","syntaxes":[{"syntax":"position object","params":[{"name":"object","type":"Object","type_expr":"Object"}],"returns":{"type":"PositionAGLS","type_expr":"PositionAGLS"},"form":"unary","right":{"text":"object"}},{"syntax":"position location","params":[{"name":"location","type":"Location","type_expr":"Location"}],"returns":{"type":"PositionAGL","type_expr":"PositionAGL","description":"see locationPosition\n> [!IMPORTANT] > This position is the location's position regardless of attachObject usage - see Example 3.","text":"PositionAGL - see locationPosition\n\n> [!IMPORTANT]\n> This position is the location's position **regardless of attachObject usage** - see Example 3."},"form":"unary","right":{"text":"location"}}],"examples":[{"code":["private _pos = position player;"]},{"code":["_myLocationHomePos = position myLocation;"]},{"text":"```sqf\nprivate _location = createLocation [\"b_inf\", [1000, 1000], 1, 1];\n_location attachObject player;\nlocationPosition _location;    // [1916.03,5711.98,12.208]\ngetPos _location;            // [1916.03,5711.98,12.208]\nposition _location;            // [1000,1000,0]\n```","code":["private _location = createLocation [\"b_inf\", [1000, 1000], 1, 1];\n_location attachObject player;\nlocationPosition _location;\t// [1916.03,5711.98,12.208]\ngetPos _location;\t\t\t// [1916.03,5711.98,12.208]\nposition _location;\t\t\t// [1000,1000,0]"]}],"see_also":["getPos","getPosATL","getPosASL","getPosASLW","visiblePosition","getPosVisual","visiblePositionASL","locationPosition"]}