Created
June 9, 2020 22:59
-
-
Save Srushtika/9cf0a0ca43f9bc9410fb336fa789e4e3 to your computer and use it in GitHub Desktop.
Code snippet 28 - For multiplayer space invaders article
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Explosion extends Phaser.GameObjects.Sprite { | |
constructor(scene, x, y) { | |
super(scene, x, y, "explosion"); | |
scene.add.existing(this); | |
this.play("explode"); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment