Created
June 9, 2020 23:04
-
-
Save Srushtika/700d44c31f16ba14dbf2bc7def2f90d9 to your computer and use it in GitHub Desktop.
Code snippet 29 - For multiplayer space invaders article
This file contains 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
publishMyDeathNews(bullet, avatar) { | |
if (amIalive) { | |
deadPlayerCh.publish("dead-notif", { | |
killerBulletId: bulletThatShotMe, | |
deadPlayerId: myClientId, | |
}); | |
} | |
amIalive = false; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment