|
GameBaseData Class Reference
[Game Objects]
Scriptable, demo-able datablock. Used by GameBase objects. More...
Inheritance diagram for GameBaseData:
Public Member Functions | |
Callbacks | |
void | onAdd (GameBase obj) |
Called when the object is added to the scene. | |
void | onMount (GameBase obj, SceneObject mountObj, int node) |
Called when the object is mounted to another object in the scene. | |
void | onNewDataBlock (GameBase obj) |
Called when the object has a new datablock assigned. | |
void | onRemove (GameBase obj) |
Called when the object is removed from the scene. | |
void | onUnmount (GameBase obj, SceneObject mountObj, int node) |
Called when the object is unmounted from another object in the scene. | |
Public Attributes | |
Scripting | |
caseString | category |
The group that this datablock will show up in under the "Scripted" tab in the World Editor Library. |
Detailed Description
Scriptable, demo-able datablock. Used by GameBase objects.
- See also:
- GameBase
Member Function Documentation
void GameBaseData::onAdd | ( | GameBase | obj | ) |
Called when the object is added to the scene.
- Parameters:
-
obj the GameBase object
- Example:
datablock GameBaseData(MyObjectData) { category = "Misc"; }; function MyObjectData::onAdd( %this, %obj ) { echo( "Added " @ %obj.getName() @ " to the scene." ); } function MyObjectData::onNewDataBlock( %this, %obj ) { echo( "Assign " @ %this.getName() @ " datablock to " %obj.getName() ); } function MyObjectData::onRemove( %this, %obj ) { echo( "Removed " @ %obj.getName() @ " to the scene." ); } function MyObjectData::onMount( %this, %obj, %mountObj, %node ) { echo( %obj.getName() @ " mounted to " @ %mountObj.getName() ); } function MyObjectData::onUnmount( %this, %obj, %mountObj, %node ) { echo( %obj.getName() @ " unmounted from " @ %mountObj.getName() ); }
void GameBaseData::onMount | ( | GameBase | obj, | |
SceneObject | mountObj, | |||
int | node | |||
) |
void GameBaseData::onNewDataBlock | ( | GameBase | obj | ) |
void GameBaseData::onRemove | ( | GameBase | obj | ) |
void GameBaseData::onUnmount | ( | GameBase | obj, | |
SceneObject | mountObj, | |||
int | node | |||
) |
Member Data Documentation
caseString GameBaseData::category |
The group that this datablock will show up in under the "Scripted" tab in the World Editor Library.
Copyright © GarageGames, LLC. All Rights Reserved.