diff options
Diffstat (limited to 'src/game/game.cc')
| -rw-r--r-- | src/game/game.cc | 8 | 
1 files changed, 6 insertions, 2 deletions
| diff --git a/src/game/game.cc b/src/game/game.cc index 311a696..a76d5e7 100644 --- a/src/game/game.cc +++ b/src/game/game.cc @@ -30,6 +30,8 @@ void func_join(core::Player *player, std::string const &args)  	std::string message(player->name());  	message.append(" joins the game.");  	core::server()->broadcast(message); + +	player->player_dirty = true;  }  /// a player joins the spectators @@ -44,9 +46,11 @@ void func_spectate(core::Player *player, std::string const &args)  	if (player->control) {  		// player has only ship for now -		core::Entity::remove(player->control->id()); +		player->control->die();  		player->control = 0;  	} + +	player->player_dirty = true;  }  /*----- Game ------------------------------------------------------ */ @@ -136,7 +140,7 @@ void Game::player_disconnect(core::Player *player)  {  	if (player->control) {  		// player has only one ship for now -		core::Entity::remove(player->control->id()); +		player->control->die();  		player->control = 0;  	}  } | 
