colyseus / colyseus-examples

Examples for learning how Colyseus works
https://examples.colyseus.dev/
MIT License
178 stars 90 forks source link

room.state.players.onRemove is never called #20

Closed dogwatch closed 5 years ago

dogwatch commented 5 years ago

1) Open two tabs with http://localhost:2567/02-state-handler.html 2) Look https://i.imgur.com/j7Wlnpm.png 3) Close one of the tabs. 4) Look https://i.imgur.com/1Y6L0sM.png

Instead of room.state.players.onRemove, called room.state.players.onAdd without a second argument.

Node v13.0.1

endel commented 5 years ago

Hi @dogwatch, thanks for reporting, It was a versioning issue. The colyseus.js distribution file wasn't updated, and the module versions of this repo wasn't the latest ones. Cheers!