Change KickPlayer event to RemovePlayer

This commit is contained in:
Oliver-Akins 2020-10-21 21:44:42 -06:00
parent aebbdf877e
commit 86acbe62e4

View file

@ -92,7 +92,7 @@ export default {
}); });
}; };
} else { } else {
this.$socket.emit(`KickPlayer`, { this.$socket.emit(`RemovePlayer`, {
game_code: this.game_code, game_code: this.game_code,
target: this.username, target: this.username,
user: this.username, user: this.username,
@ -101,7 +101,7 @@ export default {
}; };
}, },
kick_player(player) { kick_player(player) {
this.$socket.emit(`KickPlayer`, { this.$socket.emit(`RemovePlayer`, {
game_code: this.game_code, game_code: this.game_code,
user: this.username, user: this.username,
target: player, target: player,
@ -123,7 +123,7 @@ export default {
NewPlayer(data) { NewPlayer(data) {
this.players.push(data.player); this.players.push(data.player);
}, },
PlayerKicked(data) { PlayerRemoved(data) {
if (data.player === this.username) { if (data.player === this.username) {
this.$emit(`alert`, { this.$emit(`alert`, {
message: `You have been removed from the game.`, message: `You have been removed from the game.`,