Sprite#events
  • References/Game Development/Phaser/Display/Sprite

events : Phaser.Events All Phaser Game Objects

2025-01-10 15:47:30
Sprite#loadTexture()
  • References/Game Development/Phaser/Display/Sprite

loadTexture(key, frame, stopAnimation) Changes the base texture the Game

2025-01-10 15:47:30
Sprite#key
  • References/Game Development/Phaser/Display/Sprite

key : string | Phaser.RenderTexture |

2025-01-10 15:47:30
Sprite#destroy()
  • References/Game Development/Phaser/Display/Sprite

destroy(destroyChildren, destroyTexture) Destroys the Game Object. This

2025-01-10 15:47:30
Sprite#y
  • References/Game Development/Phaser/Display/Sprite

y : number The position of the Game Object on the y axis relative to the local coordinates of the parent.

2025-01-10 15:47:30
Sprite#alive
  • References/Game Development/Phaser/Display/Sprite

alive : boolean A useful flag to control if the Game Object is alive or dead. This is set automatically by the Health components

2025-01-10 15:47:30
Sprite#crop()
  • References/Game Development/Phaser/Display/Sprite

crop(rect, copy) Crop allows you to crop the texture being used to display this Game Object.Setting

2025-01-10 15:47:30
Sprite#world
  • References/Game Development/Phaser/Display/Sprite

world : Phaser.Point The world coordinates of this

2025-01-10 15:47:30
Sprite#setTexture()
  • References/Game Development/Phaser/Display/Sprite

setTexture(texture, destroy) Sets the texture of the sprite. Be warned that this doesn't remove or destroy

2025-01-10 15:47:30
Sprite#centerX
  • References/Game Development/Phaser/Display/Sprite

centerX : number The center x coordinate of the Game Object.This is the same as (x - offsetX) + (width / 2)

2025-01-10 15:47:30