Prevent whiteboard from activating during replay.

This commit is contained in:
Gabriel Morin 2010-08-15 01:34:20 +00:00
parent d5c944469b
commit 84af35ca6a
3 changed files with 6 additions and 3 deletions

View file

@ -510,7 +510,7 @@ void play_controller::init_side(const unsigned int team_index, bool is_replay){
gamestate_.get_variable("side_number") = player_number_;
gamestate_.last_selected = map_location::null_location;
resources::whiteboard->on_init_side();
resources::whiteboard->on_init_side(is_replay);
/**
* We do this only for local side when we are not replaying.

View file

@ -205,8 +205,11 @@ bool manager::allow_leader_to_move(unit const& leader) const
return true;
}
void manager::on_init_side()
void manager::on_init_side(bool is_replay)
{
if (is_replay)
return;
validate_viewer_actions();
highlighter_.reset(new highlight_visitor(*resources::units, viewer_actions()));
wait_for_side_init_ = false;

View file

@ -61,7 +61,7 @@ public:
bool can_execute_hotkey() const;
bool allow_leader_to_move(unit const& leader) const;
void on_init_side();
void on_init_side(bool is_replay);
void on_finish_side_turn();
void on_mouseover_change(const map_location& hex);
void on_select_hex(){}