Allowing clients to track this state
remove_player(id) {
const index = this._players.findIndex(player => player.id === id);
this._players.splice(index, 1);
+
+ this.broadcast("player-deregister", `{"id": ${id}}`);
}
remove_all_players() {
* the API specification which we want here. */
let captor = this._players.find(player => player.id === captor_id);
captor.captures.push(captee_id);
+
+ this.broadcast("capture", `{"captor": ${captor_id}, "captee": ${captee_id}}`);
}
liberate(captee_id) {