variable_info_mutable< variable_info_implementation::vi_policy_throw > variable_access_throw
'Throw if nonexistent' access.
randomness::mt_rng & rng()
map_location last_selected
the last location where a select event fired.
Variant for storing WML attributes.
config & get_variable_cfg(const std::string &varname)
throws invalid_variablename_exception if varname is no valid variable name.
void set_next_scenario(const std::string &next_scenario)
const randomness::mt_rng & rng() const
bool allow_end_turn() const
const std::string & get_theme() const
Additional functionality for a non-const variable_info.
const std::string & get_id() const
Contains the exception interfaces used to signal completion of a scenario, campaign or turn...
const config & get_variables() const
Definitions for the interface to Wesnoth Markup Language (WML).
config::attribute_value & get_variable(const std::string &varname)
throws invalid_variablename_exception if varname is no valid variable name.
void set_phase(PHASE phase)
variable_info< const variable_info_implementation::vi_policy_const > variable_access_const
Read-only access.
void set_defeat_music(std::vector< std::string > value)
const t_string & cannot_end_turn_reason()
std::string next_scenario_
the scenario coming next (for campaigns)
variable_access_create get_variable_access_write(const std::string &varname)
returns a variable_access that can be used to change the game variables
void set_variable(const std::string &varname, const t_string &value)
does nothing if varname is no valid variable name.
void set_id(const std::string &value)
variable_access_throw get_variable_access_throw(const std::string &varname)
Used to delete variables.
void activate_scope_variable(std::string var_name) const
Encapsulates the map of the game.
std::vector< scoped_wml_variable * > scoped_variables
void set_theme(const std::string &value)
t_string cannot_end_turn_reason_
void clear_variable_cfg(const std::string &varname)
Clears only the config children does nothing if varname is no valid variable name.
const std::string & next_scenario() const
variable_info_mutable< variable_info_implementation::vi_policy_create > variable_access_create
'Create if nonexistent' access.
std::vector< std::string > defeat_music_
const std::vector< std::string > & get_defeat_music() const
virtual config::attribute_value get_variable_const(const std::string &varname) const
returns a blank attribute value if varname is no valid variable name.
Information on a WML variable.
void set_victory_music(std::vector< std::string > value)
std::vector< std::string > victory_music_
config & add_variable_cfg(const std::string &varname, const config &value=config())
throws invalid_variablename_exception if varname is no valid variable name.
void set_allow_end_turn(bool value, const t_string &reason="")
void clear_variable(const std::string &varname)
Clears attributes config children does nothing if varname is no valid variable name.
void write_snapshot(config &cfg) const
A config object defines a single node in a WML file, with access to child nodes.
const std::vector< std::string > & get_victory_music() const
game_data(const config &level)
variable_access_const get_variable_access_read(const std::string &varname) const
returns a variable_access that cannot be used to change the game variables