-
Notifications
You must be signed in to change notification settings - Fork 2
object
aqua.game()
Creates a Game instance.
aqua.gameObject()
Creates a GameObject instance.
aqua.component()
Creates a Component instance.
All types are at aqua.types.
Game.add(gameObject)
Add a GameObject.
Game.destroy(gameObject)
Remove a GameObject when appropriate.
Game.task(options)
Add a task to the game. Options are same as Task's.
Game.step()
Take a step in game time.
Game.Priorities
Map of named priorities for game tasks.
GameObject.add(component)
GameObject.destroy([component])
If the component
argument is given, remove that, otherwise remove this GameObject from it's parent Game.
GameObject.get(componentType)
Return a component on the GameObject with a matching prototype to componentType
.
Component.destroy()
Remove component from parent GameObject.
Component.onadd(gameObject)
Called when the Component is added to a GameObject.
Component.ongameadd(gameObject, game)
Called when the Component's GameObject is added to a Game object. If the GameObject is in a Game object when the Component is added, both onadd and ongameadd will be called.
Component.ondestroy(gameObject)
Called when the Component is removed from a GameObject.
This method is only called when a component is explicitly removed from the Gameobject. Any WebGL referenced resources that may be triggered for deletion should probably be handled when ongamedestroy is called instead.
Component.ongamedestroy(gameObject, game)
Called when the Component's GameObject is removed from it's Game object.