Defines is this game object enabled in game.
Readonly
idThe unique id of this game object.
Defines is this game object ignoring mouse events.
The name of this game object.
Defines is this game object has hitbox visible in game.
The order in game objects hierarchy.
The tag of this game object.
The Transform - position, width, height and rotation of this game object.
Defines is this game object visible in game.
Invoked at last update in every frame.
Update(event){
this.transform.translate(new JSGL.Vector2(1, 0).multiply(event.deltaTime));
}
Invoked at frame when drawing
OnDraw(event){
event.renderer.drawRectangle(0, 0, 1, 1);
}
Invoked at click on drawed game object
Invoked at hover end on drawed game object
is handled?
Invoked at hover start on drawed game object
is handled?
Invoked at game object spawn.
Start(event){
console.log('I have been spawned!');
}
Invoked at every frame.
Update(event){
this.transform.translate(new JSGL.Vector2(1, 0).multiply(event.deltaTime));
}
Static
Is
Represents drawable, clickable shape on canvas