Public Types | |
typedef map_command_handler < console_handler > | chmap |
Public Member Functions | |
console_handler (menu_handler &menu_handler, mouse_handler &mouse_handler, const unsigned int team_num) | |
Protected Member Functions | |
virtual void | register_command (const std::string &cmd, chat_command_handler::command_handler h, const std::string &help="", const std::string &usage="", const std::string &flags="") |
virtual void | assert_existence (const std::string &cmd) |
virtual void | register_alias (const std::string &to_cmd, const std::string &cmd) |
virtual std::string | get_arg (unsigned i) const |
virtual std::string | get_cmd () const |
virtual std::string | get_data (unsigned n=1) const |
void | do_refresh () |
void | do_droid () |
void | do_theme () |
void | do_control () |
void | do_clear () |
void | do_sunset () |
void | do_fps () |
void | do_benchmark () |
void | do_save () |
void | do_save_quit () |
void | do_quit () |
void | do_ignore_replay_errors () |
void | do_nosaves () |
void | do_next_level () |
void | do_debug () |
void | do_nodebug () |
void | do_custom () |
void | do_set_alias () |
void | do_set_var () |
void | do_show_var () |
void | do_unit () |
void | do_buff () |
void | do_unbuff () |
void | do_create () |
void | do_fog () |
void | do_shroud () |
void | do_gold () |
void | do_event () |
std::string | get_flags_description () const |
std::string | get_command_flags_description (const chmap::command &c) const |
bool | is_enabled (const chmap::command &c) const |
void | print (const std::string &title, const std::string &message) |
void | init_map () |
Private Attributes | |
menu_handler & | menu_handler_ |
mouse_handler & | mouse_handler_ |
const unsigned int | team_num_ |
Definition at line 2267 of file menu_events.cpp.
Definition at line 2271 of file menu_events.cpp.
events::console_handler::console_handler | ( | menu_handler & | menu_handler, | |
mouse_handler & | mouse_handler, | |||
const unsigned int | team_num | |||
) | [inline] |
Definition at line 2272 of file menu_events.cpp.
virtual void events::console_handler::register_command | ( | const std::string & | cmd, | |
chat_command_handler::command_handler | h, | |||
const std::string & | help = "" , |
|||
const std::string & | usage = "" , |
|||
const std::string & | flags = "" | |||
) | [inline, protected, virtual] |
virtual void events::console_handler::assert_existence | ( | const std::string & | cmd | ) | [inline, protected, virtual] |
Reimplemented from events::map_command_handler< Worker >.
Definition at line 2289 of file menu_events.cpp.
virtual void events::console_handler::register_alias | ( | const std::string & | to_cmd, | |
const std::string & | cmd | |||
) | [inline, protected, virtual] |
Reimplemented from events::map_command_handler< Worker >.
Definition at line 2292 of file menu_events.cpp.
Referenced by do_set_alias().
virtual std::string events::console_handler::get_arg | ( | unsigned | i | ) | const [inline, protected, virtual] |
Reimplemented from events::map_command_handler< Worker >.
Definition at line 2297 of file menu_events.cpp.
Referenced by do_control(), do_droid(), and do_unit().
virtual std::string events::console_handler::get_cmd | ( | ) | const [inline, protected, virtual] |
Reimplemented from events::map_command_handler< Worker >.
Definition at line 2301 of file menu_events.cpp.
Referenced by do_debug(), and do_nodebug().
virtual std::string events::console_handler::get_data | ( | unsigned | n = 1 |
) | const [inline, protected, virtual] |
Reimplemented from events::map_command_handler< Worker >.
Definition at line 2305 of file menu_events.cpp.
Referenced by do_buff(), do_create(), do_custom(), do_event(), do_gold(), do_ignore_replay_errors(), do_nosaves(), do_save(), do_save_quit(), do_set_alias(), do_set_var(), do_show_var(), do_sunset(), and do_unit().
void events::console_handler::do_refresh | ( | ) | [protected] |
Definition at line 2705 of file menu_events.cpp.
References image::flush_cache(), events::menu_handler::gui_, menu_handler_, and display::redraw_everything().
Referenced by init_map().
void events::console_handler::do_droid | ( | ) | [protected] |
Definition at line 2710 of file menu_events.cpp.
References gui::floating_textbox::close(), events::map_command_handler< Worker >::command_failed(), get_arg(), events::menu_handler::gui_, lexical_cast(), menu_handler_, team_num_, events::menu_handler::teams_, events::menu_handler::textbox_info_, and vgettext().
Referenced by init_map().
void events::console_handler::do_theme | ( | ) | [protected] |
Definition at line 2741 of file menu_events.cpp.
References events::menu_handler::gui_, menu_handler_, and preferences::show_theme_dialog().
Referenced by init_map().
void events::console_handler::do_control | ( | ) | [protected] |
Definition at line 2744 of file menu_events.cpp.
References events::menu_handler::change_side_controller(), gui::floating_textbox::close(), events::map_command_handler< Worker >::command_failed(), events::map_command_handler< Worker >::command_failed_need_arg(), get_arg(), events::menu_handler::gui_, lexical_cast(), preferences::login(), menu_handler_, network::nconnections(), events::menu_handler::teams_, events::menu_handler::textbox_info_, and vgettext().
Referenced by init_map().
void events::console_handler::do_clear | ( | ) | [protected] |
Definition at line 2782 of file menu_events.cpp.
References game_display::clear_chat_messages(), events::menu_handler::gui_, and menu_handler_.
Referenced by init_map().
void events::console_handler::do_sunset | ( | ) | [protected] |
Definition at line 2785 of file menu_events.cpp.
References get_data(), events::menu_handler::gui_, menu_handler_, and display::sunset().
Referenced by init_map().
void events::console_handler::do_fps | ( | ) | [protected] |
Definition at line 2789 of file menu_events.cpp.
References preferences::set_show_fps(), and preferences::show_fps().
Referenced by init_map().
void events::console_handler::do_benchmark | ( | ) | [protected] |
Definition at line 2792 of file menu_events.cpp.
References events::menu_handler::gui_, menu_handler_, and display::toggle_benchmark().
Referenced by init_map().
void events::console_handler::do_save | ( | ) | [protected] |
Definition at line 2795 of file menu_events.cpp.
References get_data(), menu_handler_, gui::NULL_DIALOG, and events::menu_handler::save_game().
Referenced by init_map().
void events::console_handler::do_save_quit | ( | ) | [protected] |
Definition at line 2798 of file menu_events.cpp.
References get_data(), menu_handler_, gui::NULL_DIALOG, QUIT, and events::menu_handler::save_game().
Referenced by init_map().
void events::console_handler::do_quit | ( | ) | [protected] |
void events::console_handler::do_ignore_replay_errors | ( | ) | [protected] |
Definition at line 2805 of file menu_events.cpp.
References get_data(), and game_config::ignore_replay_errors.
Referenced by init_map().
void events::console_handler::do_nosaves | ( | ) | [protected] |
Definition at line 2808 of file menu_events.cpp.
References game_config::disable_autosave, and get_data().
Referenced by init_map().
void events::console_handler::do_next_level | ( | ) | [protected] |
Definition at line 2811 of file menu_events.cpp.
References LEVEL_CONTINUE_NO_SAVE.
Referenced by init_map().
void events::console_handler::do_debug | ( | ) | [protected] |
Definition at line 2814 of file menu_events.cpp.
References _, events::map_command_handler< Worker >::command_failed(), game_config::debug, get_cmd(), network::nconnections(), and print().
Referenced by init_map().
void events::console_handler::do_nodebug | ( | ) | [protected] |
Definition at line 2822 of file menu_events.cpp.
References _, game_config::debug, get_cmd(), and print().
Referenced by init_map().
void events::console_handler::do_custom | ( | ) | [protected] |
Definition at line 2828 of file menu_events.cpp.
References get_data(), and preferences::set().
Referenced by init_map().
void events::console_handler::do_set_alias | ( | ) | [protected] |
Definition at line 2831 of file menu_events.cpp.
References command, data, get_data(), and register_alias().
Referenced by init_map().
void events::console_handler::do_set_var | ( | ) | [protected] |
Definition at line 2840 of file menu_events.cpp.
References events::map_command_handler< Worker >::command_failed(), events::map_command_handler< Worker >::command_failed_need_arg(), data, events::menu_handler::gamestate_, get_data(), menu_handler_, name, game_state::set_variable(), and value.
Referenced by init_map().
void events::console_handler::do_show_var | ( | ) | [protected] |
Definition at line 2855 of file menu_events.cpp.
References events::menu_handler::gamestate_, get_data(), game_state::get_variable(), events::menu_handler::gui_, and menu_handler_.
Referenced by init_map().
void events::console_handler::do_unit | ( | ) | [protected] |
Definition at line 2859 of file menu_events.cpp.
References cfg, events::map_command_handler< Worker >::command_failed(), events::commands_disabled, events::menu_handler::current_unit(), unit_map::end(), get_arg(), get_data(), events::menu_handler::gui_, game_display::invalidate(), game_display::invalidate_unit(), events::menu_handler::map_, menu_handler_, mouse_handler_, events::menu_handler::status_, events::menu_handler::teams_, events::menu_handler::units_, and value.
Referenced by init_map().
void events::console_handler::do_buff | ( | ) | [protected] |
Definition at line 2886 of file menu_events.cpp.
References events::map_command_handler< Worker >::command_failed(), events::menu_handler::current_unit(), unit_map::end(), get_data(), events::menu_handler::gui_, game_display::invalidate(), game_display::invalidate_unit(), menu_handler_, mouse_handler_, and events::menu_handler::units_.
Referenced by init_map().
void events::console_handler::do_unbuff | ( | ) | [protected] |
Definition at line 2896 of file menu_events.cpp.
References events::map_command_handler< Worker >::command_failed(), events::menu_handler::current_unit(), unit_map::end(), events::menu_handler::gui_, game_display::invalidate(), game_display::invalidate_unit(), menu_handler_, mouse_handler_, and events::menu_handler::units_.
Referenced by init_map().
void events::console_handler::do_create | ( | ) | [protected] |
Definition at line 2907 of file menu_events.cpp.
References unit_map::add(), events::map_command_handler< Worker >::command_failed(), boost::foreach_detail_::end(), unit_map::erase(), get_data(), events::mouse_handler::get_last_hex(), events::menu_handler::gui_, game_display::invalidate(), game_display::invalidate_unit(), events::menu_handler::map_, menu_handler_, mouse_handler_, gamemap::on_board(), events::menu_handler::status_, events::menu_handler::teams_, unit_type_data::types(), and events::menu_handler::units_.
Referenced by init_map().
void events::console_handler::do_fog | ( | ) | [protected] |
Definition at line 2925 of file menu_events.cpp.
References events::menu_handler::gui_, events::menu_handler::map_, menu_handler_, recalculate_fog(), display::recalculate_minimap(), display::redraw_everything(), team_num_, events::menu_handler::teams_, and events::menu_handler::units_.
Referenced by init_map().
void events::console_handler::do_shroud | ( | ) | [protected] |
Definition at line 2931 of file menu_events.cpp.
References events::menu_handler::clear_shroud(), events::menu_handler::gui_, menu_handler_, display::recalculate_minimap(), display::redraw_everything(), team_num_, and events::menu_handler::teams_.
Referenced by init_map().
void events::console_handler::do_gold | ( | ) | [protected] |
Definition at line 2937 of file menu_events.cpp.
References get_data(), events::menu_handler::gui_, menu_handler_, display::redraw_everything(), team_num_, and events::menu_handler::teams_.
Referenced by init_map().
void events::console_handler::do_event | ( | ) | [protected] |
Definition at line 2941 of file menu_events.cpp.
References game_events::fire(), get_data(), events::menu_handler::gui_, menu_handler_, and display::redraw_everything().
Referenced by init_map().
std::string events::console_handler::get_flags_description | ( | ) | const [inline, protected, virtual] |
Reimplemented from events::map_command_handler< Worker >.
Definition at line 2347 of file menu_events.cpp.
std::string events::console_handler::get_command_flags_description | ( | const chmap::command & | c | ) | const [inline, protected, virtual] |
Reimplemented from events::map_command_handler< Worker >.
Definition at line 2351 of file menu_events.cpp.
References events::map_command_handler< Worker >::command::has_flag().
bool events::console_handler::is_enabled | ( | const chmap::command & | c | ) | const [inline, protected, virtual] |
Reimplemented from events::map_command_handler< Worker >.
Definition at line 2357 of file menu_events.cpp.
References game_config::debug, events::map_command_handler< Worker >::command::has_flag(), and network::nconnections().
void events::console_handler::print | ( | const std::string & | title, | |
const std::string & | message | |||
) | [inline, protected, virtual] |
Implements events::map_command_handler< Worker >.
Definition at line 2362 of file menu_events.cpp.
Referenced by do_debug(), and do_nodebug().
void events::console_handler::init_map | ( | ) | [inline, protected, virtual] |
Implements events::map_command_handler< Worker >.
Definition at line 2366 of file menu_events.cpp.
References _, do_benchmark(), do_buff(), do_clear(), do_control(), do_create(), do_custom(), do_debug(), do_droid(), do_event(), do_fog(), do_fps(), do_gold(), do_ignore_replay_errors(), do_next_level(), do_nodebug(), do_nosaves(), do_quit(), do_refresh(), do_save(), do_save_quit(), do_set_alias(), do_set_var(), do_show_var(), do_shroud(), do_sunset(), do_theme(), do_unbuff(), do_unit(), and events::chat_command_handler::init_map().
Definition at line 2435 of file menu_events.cpp.
Referenced by do_benchmark(), do_buff(), do_clear(), do_control(), do_create(), do_droid(), do_event(), do_fog(), do_gold(), do_refresh(), do_save(), do_save_quit(), do_set_var(), do_show_var(), do_shroud(), do_sunset(), do_theme(), do_unbuff(), and do_unit().
Definition at line 2436 of file menu_events.cpp.
Referenced by do_buff(), do_create(), do_unbuff(), and do_unit().
const unsigned int events::console_handler::team_num_ [private] |
Definition at line 2437 of file menu_events.cpp.
Referenced by do_droid(), do_fog(), do_gold(), and do_shroud().
Generated by doxygen 1.5.5 on 23 May 2008 for The Battle for Wesnoth | Gna! | Forum | Wiki | CIA | devdocs |