causing side turn events to be fired even when the turn was not
refreshed.
This commit is contained in:
Jon Daniel 2005-01-21 02:14:55 +00:00
parent d052181e64
commit a223a51df3

View file

@ -508,7 +508,6 @@ LEVEL_RESULT play_level(game_data& gameinfo, const config& game_config,
std::stringstream player_number_str;
player_number_str << player_number;
game_events::set_variable("side_number",player_number_str.str());
game_events::fire("side turn");
//we want to work out if units for this player should get healed, and the
//player should get income now. healing/income happen if it's not the first
@ -517,6 +516,7 @@ LEVEL_RESULT play_level(game_data& gameinfo, const config& game_config,
const bool turn_refresh = !first_time || loading_game && team_it != teams.begin()+first_player;
if(turn_refresh) {
game_events::fire("side turn");
for(unit_map::iterator i = units.begin(); i != units.end(); ++i) {
if(i->second.side() == player_number) {
i->second.new_turn();