Module GameTypes :: Class KX_ParentActuator
[frames] | no frames]

Class KX_ParentActuator

PyObjectPlus --+            
               |            
          CValue --+        
                   |        
     SCA_ILogicBrick --+    
                       |    
           SCA_IActuator --+
                           |
                          KX_ParentActuator

The parent actuator can set or remove an objects parent object.

Instance Methods
 
setObject(object)
Sets the object to set as parent.
string, KX_GameObject or None if no object is set
getObject(name_only=1)
Returns the name of the object to change to.
bool
isA(game_type)
Check if this is a type or a subtype game_type. (Inherited from GameTypes.PyObjectPlus)
    Deprecated
integer
getExecutePriority()
Gets the execution priority of this logic brick. (Inherited from GameTypes.SCA_ILogicBrick)
string
getName()
Returns the name of the CValue. (Inherited from GameTypes.CValue)
KX_GameObject
getOwner()
Gets the game object associated with this logic brick. (Inherited from GameTypes.SCA_ILogicBrick)
 
setExecutePriority(priority)
Sets the priority of this logic brick. (Inherited from GameTypes.SCA_ILogicBrick)
Instance Variables
bool compound
Whether the object shape should be added to the parent compound shape when parenting Effective only if the parent is already a compound shape
int executePriority
This determines the order controllers are evaluated, and actuators are activated (lower priority is executed first). (Inherited from GameTypes.SCA_ILogicBrick)
bool ghost
whether the object should be made ghost when parenting Effective only if the shape is not added to the parent compound shape
bool invalid
Test if the object has been freed by the game engine and is no longer valid. (Inherited from GameTypes.PyObjectPlus)
int from 0 to 1 GameLogic.Parent Actuator mode
The mode of this actuator
string name
The name of this CValue derived object (read-only). (Inherited from GameTypes.SCA_ILogicBrick)
KX_GameObject or None object
the object this actuator sets the parent too.
KX_GameObject or None in exceptional cases. owner
The game object this logic brick is attached to (read-only). (Inherited from GameTypes.SCA_ILogicBrick)
Method Details

setObject(object)

 

Sets the object to set as parent.

Object can be either a KX_GameObject or the name of the object.

Parameters:

Deprecated: Use the object property.

getObject(name_only=1)

 

Returns the name of the object to change to.

Parameters:
  • name_only (bool) - optional argument, when 0 return a KX_GameObject
Returns: string, KX_GameObject or None if no object is set

Deprecated: Use the object property.