Defines | Functions | Variables

playcampaign.cpp File Reference

Controls setup, play, (auto)save and replay of campaigns. More...

#include "global.hpp"
#include "foreach.hpp"
#include "game_preferences.hpp"
#include "gui/dialogs/message.hpp"
#include "gui/dialogs/transient_message.hpp"
#include "gui/widgets/window.hpp"
#include "playcampaign.hpp"
#include "map_create.hpp"
#include "persist_manager.hpp"
#include "playmp_controller.hpp"
#include "replay_controller.hpp"
#include "log.hpp"
#include "map_exception.hpp"
#include "dialogs.hpp"
#include "gettext.hpp"
#include "resources.hpp"
#include "savegame.hpp"
#include "sound.hpp"
#include "wml_exception.hpp"
#include "formula_string_utils.hpp"
Include dependency graph for playcampaign.cpp:

Go to the source code of this file.

Defines

#define LOG_G   LOG_STREAM(info, lg::general)
#define LOG_NG   LOG_STREAM(info, log_engine)

Functions

void play_replay (display &disp, game_state &gamestate, const config &game_config, CVideo &video)
static LEVEL_RESULT playsingle_scenario (const config &game_config, const config *level, display &disp, game_state &state_of_game, const config::const_child_itors &story, bool skip_replay, end_level_data &end_level)
static LEVEL_RESULT playmp_scenario (const config &game_config, config const *level, display &disp, game_state &state_of_game, const config::const_child_itors &story, bool skip_replay, io_type_t &io_type, end_level_data &end_level)
LEVEL_RESULT play_game (display &disp, game_state &gamestate, const config &game_config, io_type_t io_type, bool skip_replay)

Variables

static lg::log_domain log_engine ("engine")

Detailed Description

Controls setup, play, (auto)save and replay of campaigns.

Definition in file playcampaign.cpp.


Define Documentation

#define LOG_G   LOG_STREAM(info, lg::general)

Definition at line 44 of file playcampaign.cpp.

Referenced by play_game().

#define LOG_NG   LOG_STREAM(info, log_engine)

Definition at line 47 of file playcampaign.cpp.

Referenced by playsingle_scenario().


Function Documentation

LEVEL_RESULT play_game ( display disp,
game_state gamestate,
const config game_config,
io_type_t  io_type,
bool  skip_replay 
)

Todo:
Fix logic to use network_ai controller

Definition at line 203 of file playcampaign.cpp.

References _, game_classification::abbrev, config::add_child(), replay::at_end(), game_classification::campaign_type, gui2::twindow::CANCEL, config::child(), config::child_range(), game_state::classification(), savegame::clean_saves(), config::clear(), replay::clear(), config::clear_children(), preferences::client_type(), game_classification::completion, preferences::compress_saves(), DEFEAT, preferences::delete_saves(), config::empty(), sound::empty_playlist(), config::find_child(), game_state::get_variables(), utils::interpolate_variables_into_string(), IO_CLIENT, IO_NONE, IO_SERVER, game_classification::label, LOG_G, preferences::login(), preferences::map(), game::error::message, game_state::mp_settings(), game_logic::msg(), dialogs::network_receive_dialog(), game_classification::next_scenario, OBSERVER_END, playmp_scenario(), playsingle_scenario(), end_level_data::prescenario_save, random_generate_map(), random_generate_scenario(), recorder, game_state::replay_data, end_level_data::replay_save, game_state::rng(), rand_rng::simple_rng::rotate_random(), save(), savegame::savegame::save_game_automatic(), preferences::save_replays(), game_classification::scenario, network::send_data(), game_state::set_menu_items(), game_state::set_variables(), twml_exception::show(), gui2::show_error_message(), gui2::show_message(), game_state::snapshot, game_state::starting_pos, mp_game_settings::to_config(), type, VICTORY, display::video(), cursor::WAIT, write_players(), and game_state::write_snapshot().

Referenced by enter_connect_mode(), enter_wait_mode(), game_controller::launch_game(), test_utils::play_scenario::play(), game_controller::play_multiplayer_mode(), and game_controller::play_test().

Here is the call graph for this function:

Here is the caller graph for this function:

void play_replay ( display disp,
game_state gamestate,
const config game_config,
CVideo video 
)
static LEVEL_RESULT playmp_scenario ( const config game_config,
config const *  level,
display disp,
game_state state_of_game,
const config::const_child_itors story,
bool  skip_replay,
io_type_t io_type,
end_level_data end_level 
) [static]

Definition at line 157 of file playcampaign.cpp.

References _, DEFEAT, persist_manager::end_transaction(), CVideo::faked(), IO_CLIENT, IO_SERVER, end_level_data::linger_mode, resources::persist, QUIT, end_level_exception::result, gui2::show_transient_message(), and display::video().

Referenced by play_game().

Here is the call graph for this function:

Here is the caller graph for this function:

static LEVEL_RESULT playsingle_scenario ( const config game_config,
const config level,
display disp,
game_state state_of_game,
const config::const_child_itors story,
bool  skip_replay,
end_level_data end_level 
) [static]

Definition at line 118 of file playcampaign.cpp.

References _, DEFEAT, persist_manager::end_transaction(), CVideo::faked(), end_level_data::linger_mode, LOG_NG, resources::persist, QUIT, end_level_exception::result, gui2::show_transient_message(), and display::video().

Referenced by play_game().

Here is the call graph for this function:

Here is the caller graph for this function:


Variable Documentation

lg::log_domain log_engine("engine") [static]
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated by doxygen 1.7.1 on Fri May 25 2012 01:08:41 for The Battle for Wesnoth
Gna! | Forum | Wiki | CIA | devdocs