~~NOTOC~~
<=[[4rpl:start| Index]]
* [[4rpl:commands:GetObjPosition|Get]]
* [[4rpl:commands:SetObjPosition|Set]]
====== GetObjPosition ======
GetObjPosition(<-Unit "ObjName" <-world) ->point
===== Description =====
Returns a position vector (X,Y,Z coordinates) of a unit's object. Objects are the sub-parts that make up a unit.
If world is false, then local coordinates are returned, otherwise world coordinates are returned.
Note, use "" (empty string) to indicate the root level object.
Note: If this call is attempted on an non-existing obj name, nothing will be put on the stack.
===== Examples =====
GetObjPosition(self "Arm" false) ->pos
trace(<-pos.x)
<=[[4rpl:start| Index]]