Skip to content

Commit

Permalink
ng::configure_engine: enable setting of side_cfg_
Browse files Browse the repository at this point in the history
  • Loading branch information
Vultraz committed Aug 15, 2016
1 parent e31615b commit 168cc67
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
5 changes: 5 additions & 0 deletions src/game_initialization/configure_engine.cpp
Expand Up @@ -42,6 +42,11 @@ configure_engine::configure_engine(saved_game& state) :
}
}

void configure_engine::update_side_cfg()
{
side_cfg_ = state_.get_starting_pos().child_or_empty("side");
}

void configure_engine::set_default_values() {
set_use_map_settings(use_map_settings_default());
set_game_name(game_name_default());
Expand Down
4 changes: 3 additions & 1 deletion src/game_initialization/configure_engine.hpp
Expand Up @@ -111,6 +111,8 @@ class configure_engine

const std::vector<std::string>& entry_point_titles() const;
void write_parameters();

void update_side_cfg();
private:
saved_game& state_;
mp_game_settings& parameters_;
Expand All @@ -121,7 +123,7 @@ class configure_engine
* This might change in the future.
* NOTE when 'load game' is selected there are no sides.
*/
const config &side_cfg_;
config side_cfg_;

std::vector<const config*> entry_points_;

Expand Down

0 comments on commit 168cc67

Please sign in to comment.