#include <actions.hpp>


Public Types | |
| enum | tresult { E_NOT_AVAILABLE_FOR_RECRUITING = 3001, E_UNKNOWN_OR_DUMMY_UNIT_TYPE = 3002, E_NO_GOLD = 3003, E_NO_LEADER = 3004, E_LEADER_NOT_ON_KEEP = 3005, E_BAD_RECRUIT_LOCATION = 3006 } |
Public Member Functions | |
| recruit_result (side_number side, const std::string &unit_name, const map_location &where, const map_location &from) | |
| virtual std::string | do_describe () const |
Protected Member Functions | |
| virtual void | do_check_before () |
| virtual void | do_check_after () |
| virtual void | do_execute () |
| virtual void | do_init_for_execution () |
Private Member Functions | |
| const std::string & | get_available_for_recruiting (const team &my_team) |
| const unit_type * | get_unit_type_known (const std::string &recruit) |
| bool | test_enough_gold (const team &my_team, const unit_type &type) |
| const unit * | get_leader () |
| bool | test_leader_on_keep (const unit &my_leader) |
| bool | test_suitable_recruit_location (const unit &my_leader) |
Private Attributes | |
| const std::string & | unit_name_ |
| const map_location & | where_ |
| map_location | recruit_location_ |
| map_location | recruit_from_ |
| int | num_ |
Definition at line 234 of file actions.hpp.
| E_NOT_AVAILABLE_FOR_RECRUITING | |
| E_UNKNOWN_OR_DUMMY_UNIT_TYPE | |
| E_NO_GOLD | |
| E_NO_LEADER | |
| E_LEADER_NOT_ON_KEEP | |
| E_BAD_RECRUIT_LOCATION |
Reimplemented from ai::action_result.
Definition at line 238 of file actions.hpp.
| ai::recruit_result::recruit_result | ( | side_number | side, | |
| const std::string & | unit_name, | |||
| const map_location & | where, | |||
| const map_location & | from | |||
| ) |
Definition at line 707 of file actions.cpp.
| void ai::recruit_result::do_check_after | ( | ) | [protected, virtual] |
Implements ai::action_result.
Definition at line 831 of file actions.cpp.
| void ai::recruit_result::do_check_before | ( | ) | [protected, virtual] |
Implements ai::action_result.
Definition at line 786 of file actions.cpp.
| std::string ai::recruit_result::do_describe | ( | ) | const [virtual] |
Implements ai::action_result.
Definition at line 850 of file actions.cpp.
Referenced by operator<<().

| void ai::recruit_result::do_execute | ( | ) | [protected, virtual] |
Implements ai::action_result.
Definition at line 866 of file actions.cpp.
| void ai::recruit_result::do_init_for_execution | ( | ) | [protected, virtual] |
Implements ai::action_result.
Definition at line 903 of file actions.cpp.
| const std::string & ai::recruit_result::get_available_for_recruiting | ( | const team & | my_team | ) | [private] |
Definition at line 718 of file actions.cpp.
| const unit * ai::recruit_result::get_leader | ( | ) | [private] |
Definition at line 750 of file actions.cpp.
| const unit_type * ai::recruit_result::get_unit_type_known | ( | const std::string & | recruit | ) | [private] |
Definition at line 731 of file actions.cpp.
| bool ai::recruit_result::test_enough_gold | ( | const team & | my_team, | |
| const unit_type & | type | |||
| ) | [private] |
Definition at line 741 of file actions.cpp.
| bool ai::recruit_result::test_leader_on_keep | ( | const unit & | my_leader | ) | [private] |
Definition at line 761 of file actions.cpp.
| bool ai::recruit_result::test_suitable_recruit_location | ( | const unit & | my_leader | ) | [private] |
Definition at line 770 of file actions.cpp.
int ai::recruit_result::num_ [private] |
Definition at line 270 of file actions.hpp.
Definition at line 269 of file actions.hpp.
Definition at line 268 of file actions.hpp.
const std::string& ai::recruit_result::unit_name_ [private] |
Definition at line 266 of file actions.hpp.
const map_location& ai::recruit_result::where_ [private] |
Definition at line 267 of file actions.hpp.
| Generated by doxygen 1.7.1 on Thu May 24 2012 01:18:20 for The Battle for Wesnoth | Gna! | Forum | Wiki | CIA | devdocs |