89 throw "No scenariodata found";
184 {
return (!
cfg_[
"save_id"].empty()) ?
cfg_[
"save_id"] :
cfg_[
"id"]; }
187 {
return (!
cfg_[
"previous_save_id"].empty()) ?
cfg_[
"previous_save_id"] :
save_id(); }
240 const std::string& name,
const std::string& controller_value);
A config object defines a single node in a WML file, with access to child nodes.
optional_config_impl< config > optional_child(config_key_type key, int n=0)
Equivalent to mandatory_child, but returns an empty optional if the nth child was not found.
A class grating read only view to a vector of config objects, viewed as one config with all children ...
const config & level() const
const std::vector< team_data_pod > & team_data() const
std::vector< const config * > era_factions_
std::vector< team_data_pod > team_data_
std::vector< side_engine_ptr > & side_engines()
bool first_scenario() const
const ng::controller default_controller_
config * current_config()
std::set< std::string > & connected_users_rw()
std::pair< bool, bool > process_network_data(const config &data)
void import_user(const std::string &name, const bool observer, int side_taken=-1)
bool sides_available() const
bool force_lock_settings_
std::vector< side_engine_ptr > side_engines_
const bool first_scenario_
void update_and_send_diff()
bool force_lock_settings() const
void save_reserved_sides_information()
const std::set< std::string > & connected_users() const
const mp_game_settings & params() const
const mp_game_settings & params_
void send_level_data() const
connect_engine & operator=(const connect_engine &)=delete
void load_previous_sides_users()
mp_game_metadata * mp_metadata_
void update_side_controller_options()
connect_engine(saved_game &state, const bool first_scenario, mp_game_metadata *metadata)
void start_game_commandline(const commandline_options &cmdline_opts, const game_config_view &game_config)
connect_engine(const connect_engine &)=delete
int find_user_side_index_by_id(const std::string &id) const
bool can_start_game() const
FLG stands for faction, leader and gender.
const std::string team_name() const
const config & cfg() const
void set_team(unsigned team)
unsigned current_controller_index_
void update_controller_options()
bool waiting_to_choose_faction() const
std::string previous_save_id() const
const bool controller_lock_
const bool allow_changes_
void set_controller_commandline(const std::string &controller_name)
void set_income(int income)
void set_faction_commandline(const std::string &faction_name)
void place_user(const std::string &name)
void set_side_children(const std::multimap< std::string, config > &children)
void add_controller_option(ng::controller controller, const std::string &name, const std::string &controller_value)
const std::vector< std::string > & color_options() const
void resolve_random(randomness::mt_rng &rng, const std::vector< std::string > &avoid_faction_ids=std::vector< std::string >())
void update_current_controller_index()
side_engine(const config &cfg, connect_engine &parent_engine, const int index)
std::vector< controller_option > controller_options_
const std::string user_team_name() const
std::string save_id() const
side_engine(const side_engine &engine)=delete
std::string ai_algorithm_
side_engine & operator=(const side_engine &)=delete
void set_reserved_for(const std::string &reserved_for)
bool allow_player() const
std::string reserved_for_
void set_index(int index)
std::vector< std::string > color_options_
void set_controller(ng::controller controller)
void set_waiting_to_choose_status(bool status)
void set_color(int color)
bool controller_changed(const int selection)
std::string user_description() const
ng::controller controller_
const std::string & ai_algorithm() const
bool allow_shuffle() const
std::multimap< std::string, config > get_side_children()
const std::string color_id() const
bool ready_for_start() const
void set_ai_algorithm(const std::string &ai_algorithm)
config new_config() const
bool waiting_to_choose_faction_
bool allow_changes() const
const std::vector< controller_option > & controller_options() const
const std::string & player_id() const
const std::string & reserved_for() const
ng::controller controller() const
bool available_for_user(const std::string &name="") const
unsigned current_controller_index() const
static t_string from_serialized(const std::string &string)
This class stores all the data for a single 'side' (in game nomenclature).
Definitions for the interface to Wesnoth Markup Language (WML).
Game configuration data as global variables.
static std::string controller_name(const team &t)
std::pair< ng::controller, std::string > controller_option
std::shared_ptr< side_engine > side_engine_ptr
std::string user_team_name