#include <upload_log.hpp>
Public Member Functions | |
upload_log (bool enable) | |
~upload_log () | |
void | start (game_state &state, const team &team, unsigned int team_number, const unit_map &map, const t_string &turn, int num_turns) |
void | defeat (int turn) |
void | victory (int turn, int gold) |
void | quit (int turn) |
Private Member Functions | |
config & | add_game_result (const std::string &str, int turn) |
bool | game_finished (config *game) |
Private Attributes | |
config | config_ |
config * | game_ |
std::string | filename_ |
bool | enabled_ |
Static Private Attributes | |
static struct thread_info | thread_ |
static manager * | manager_ = 0 |
Friends | |
struct | manager |
Classes | |
struct | manager |
struct | thread_info |
Definition at line 25 of file upload_log.hpp.
upload_log::upload_log | ( | bool | enable | ) |
Definition at line 143 of file upload_log.cpp.
References filename_, get_upload_dir(), upload_log::thread_info::lastfile, upload_log::manager::manage(), manager_, next_filename(), upload_log::thread_info::t, thread_, preferences::upload_log(), and upload_logs().
upload_log::~upload_log | ( | ) |
Definition at line 156 of file upload_log.cpp.
References config::add_child(), config_, game_config::debug, config::empty(), enabled_, file_name(), filename_, game_, game_finished(), get_upload_dir(), upload_log::thread_info::lastfile, lexical_cast(), upload_log::manager::manage(), manager_, next_filename(), ostream_file(), upload_log::thread_info::t, thread_, preferences::upload_id(), preferences::upload_log(), upload_logs(), VERSION, and write().
void upload_log::start | ( | game_state & | state, | |
const team & | team, | |||
unsigned int | team_number, | |||
const unit_map & | map, | |||
const t_string & | turn, | |||
int | num_turns | |||
) |
Referenced by playsingle_controller::play_scenario().
void upload_log::defeat | ( | int | turn | ) |
Definition at line 286 of file upload_log.cpp.
References add_game_result().
Referenced by playsingle_controller::play_scenario().
void upload_log::victory | ( | int | turn, | |
int | gold | |||
) |
Definition at line 294 of file upload_log.cpp.
References add_game_result(), and lexical_cast().
Referenced by playsingle_controller::play_scenario().
void upload_log::quit | ( | int | turn | ) |
Definition at line 303 of file upload_log.cpp.
References add_game_result(), and lexical_cast().
Referenced by playsingle_controller::linger(), playmp_controller::linger(), and playsingle_controller::play_scenario().
config & upload_log::add_game_result | ( | const std::string & | str, | |
int | turn | |||
) | [private] |
Definition at line 193 of file upload_log.cpp.
References config::add_child(), game_, and lexical_cast().
bool upload_log::game_finished | ( | config * | game | ) | [private] |
Definition at line 185 of file upload_log.cpp.
References config::child().
Referenced by ~upload_log().
friend struct manager [friend] |
Definition at line 61 of file upload_log.hpp.
struct thread_info upload_log::thread_ [static, read, private] |
Definition at line 59 of file upload_log.hpp.
Referenced by upload_log::manager::manage(), upload_log(), upload_log::manager::~manager(), and ~upload_log().
upload_log::manager * upload_log::manager_ = 0 [static, read, private] |
Definition at line 60 of file upload_log.hpp.
Referenced by upload_log::manager::manager(), upload_log(), upload_log::manager::~manager(), and ~upload_log().
config upload_log::config_ [private] |
config* upload_log::game_ [private] |
std::string upload_log::filename_ [private] |
bool upload_log::enabled_ [private] |
Generated by doxygen 1.5.5 on 23 May 2008 for The Battle for Wesnoth | Gna! | Forum | Wiki | CIA | devdocs |