partey_workadventure/front/src/Phaser/Entity/Sprite.ts
2021-09-06 14:31:59 +02:00

8 lines
292 B
TypeScript

export class Sprite extends Phaser.GameObjects.Sprite {
constructor(scene: Phaser.Scene, x: number, y: number, texture: string, frame?: number | string) {
super(scene, x, y, texture, frame);
scene.sys.updateList.add(this);
scene.sys.displayList.add(this);
}
}