Regular API function

simGetObjectParent / sim.getObjectParent

Description Retrieves the handle of an object's parent object. See also sim.setObjectParent and sim.getObjectChild.
C synopsis simInt simGetObjectParent(simInt objectHandle)
C parameters
objectHandle: handle of the object
C return value
handle of parent or -1 if the parent doesn't exist or in case of an error
Lua synopsis number parentHandle=sim.getObjectParent(number objectHandle)
Lua parameters
Same as C-function
Lua return values
Same as C-function
Remote API equiv.
B0-based remote API: simxGetObjectParent
Legacy remote API: simxGetObjectParent

All regular API functions on one page