Behaviour
info
Behaviour inherits from Component
Behaviours are Components that can be enabled or disabled.
Members
Properties
Name | Description |
---|---|
Behaviour .enabled | Enabled Behaviours are Updated, disabled Behaviours are not. |
Behaviour .isActiveAndEnabled | Has the Behaviour had active and enabled called? |
Inherited Members
Inherited Properties
Name | Description |
---|---|
Behaviour .gameObject | The game object this component is attached to. A component is always attached to a game object. |
Behaviour .tag | The tag of this game object. |
Behaviour .transform | The Transform attached to this GameObject. |
Behaviour .hideFlags | Should the object be hidden, saved with the Scene or modifiable by the user? |
Behaviour .name | The name of the object. |
Inherited Methods
Name | Description |
---|---|
Behaviour .BroadcastMessage(methodName, parameter=nil) | Calls the method named methodName on every Lua Script in this game object or any of its children. |
Behaviour .CompareTag(tag) | Is this game object tagged with tag ? |
Behaviour .GetAllLuaScripts() | Returns an array of all Lua scripts that attached to the game object. |
Behaviour .GetComponent(type) | Returns the component of Type type if the game object has one attached, nil if it doesn't. |
Behaviour .GetComponentInChildren(t) | Returns the component of Type type in the GameObject or any of its children using depth first search. |
Behaviour .GetComponentInParent(t) | Returns the component of Type type in the GameObject or any of its parents. |
Behaviour .GetComponents(type) | Returns all components of Type type in the GameObject. |
Behaviour .GetComponentsInChildren(t) | Returns all components of Type type in the GameObject or any of its children. |
Behaviour .GetComponentsInParent(t) | Returns all components of Type type in the GameObject or any of its parents. |
Behaviour .SendMessage(methodName, value=nil) | Calls the method named methodName on every Lua Script in this game object. |
Behaviour .SendMessageUpwards(methodName, value=nil) | Calls the method named methodName on every LuaScript in this game object and on every ancestor of the behaviour. |
Behaviour .TryGetComponent(type) | Gets the component of the specified type, if it exists. |
Behaviour .GetInstanceID() | Returns the instance id of the object. |