40 const char *
what() const noexcept {
return "reset_gamestate_exception"; }
72 virtual bool is_host()
const {
return true; }
A config object defines a single node in a WML file, with access to child nodes.
Base class for exceptions that want to be thrown 'through' lua.
void store() const noexcept
Stores a copy the current exception to be rethrown.
bool player_type_changed_
true when the controller of the currently playing side has changed.
virtual void play_human_turn()
void end_turn_enable(bool enable)
virtual void play_network_turn()
Will handle networked turns in descendent classes.
void set_player_type_changed()
virtual void init_gui() override
void on_replay_end(bool is_unit_test)
std::string describe_result() const
std::unique_ptr< replay_controller > replay_controller_
non-null when replay mode in active, is used in singleplayer and for the "back to turn" feature in mu...
bool ai_fallback_
true when the current side is actually an ai side but was taken over by a human (usually for debuggin...
void sync_end_turn() override
virtual void check_objectives() override
ses_result skip_empty_sides(int side_num)
Calculates the current side, starting at side_num that is non-empty.
bool is_team_visible(int team_num, bool observer) const
void force_end_turn() override
replay_controller * get_replay_controller() const override
level_result::type play_scenario(const config &level)
virtual bool is_host() const
bool get_player_type_changed() const
virtual bool should_return_to_play_side() const override
~playsingle_controller()
Defined here to reduce file includes.
const cursor::setter cursor_setter_
void update_viewing_player() override
playsingle_controller(const config &level, saved_game &state_of_game)
virtual void handle_generic_event(const std::string &name) override
virtual void do_idle_notification()
Will handle sending a networked notification in descendent classes.
bool end_turn_requested_
true iff the user has pressed the end turn button this turn.
void play_scenario_main_loop()
virtual void on_not_observer() override
int find_viewing_side() const override
returns 0 if no such team was found.
virtual void play_idle_loop()
void play_scenario_init(const config &level)
virtual void after_human_turn()
void enable_replay(bool is_unit_test=false)
virtual void maybe_linger()
#define IMPLEMENT_LUA_JAILBREAK_EXCEPTION(type)
Helper macro for classes deriving from lua_jailbreak_exception.
std::shared_ptr< config > stats_
const char * what() const noexcept
std::shared_ptr< config > level
reset_gamestate_exception(std::shared_ptr< config > l, std::shared_ptr< config > stats, bool s=true)
static map_location::direction s