#include <ca.hpp>


Public Member Functions | |
| simple_move_and_targeting_phase (rca_context &context, const config &cfg) | |
| virtual | ~simple_move_and_targeting_phase () |
| virtual double | evaluate () |
| Evaluate the candidate action, resetting the internal state of the action. | |
| virtual void | execute () |
| Execute the candidate action. | |
Private Attributes | |
| move_result_ptr | move_ |
Definition at line 304 of file ca.hpp.
| ai::testing_ai_default::simple_move_and_targeting_phase::simple_move_and_targeting_phase | ( | rca_context & | context, | |
| const config & | cfg | |||
| ) |
| ai::testing_ai_default::simple_move_and_targeting_phase::~simple_move_and_targeting_phase | ( | ) | [virtual] |
| double ai::testing_ai_default::simple_move_and_targeting_phase::evaluate | ( | ) | [virtual] |
Evaluate the candidate action, resetting the internal state of the action.
| >0 | if the action is good | |
| <=0 | if the action is not good |
Implements ai::candidate_action.
Definition at line 1878 of file ca.cpp.
References ai::candidate_action::BAD_SCORE, unit_map::begin(), ai::readonly_context_proxy::check_move_action(), ai::readonly_context_proxy::current_team(), gui2::distance(), distance_between(), unit_map::end(), unit_map::find_leader(), ai::readonly_context_proxy::get_dstsrc(), ai::readonly_context_proxy::get_passive_leader(), ai::candidate_action::get_score(), ai::side_context_proxy::get_side(), team::is_enemy(), move_, map_location::null_location, resources::units, and unit_map::iterator_base< iter_types >::valid().

| void ai::testing_ai_default::simple_move_and_targeting_phase::execute | ( | ) | [virtual] |
Execute the candidate action.
Implements ai::candidate_action.
Definition at line 1924 of file ca.cpp.
References ai::candidate_action::get_name(), LOG_AI_TESTING_AI_DEFAULT, and move_.

Definition at line 317 of file ca.hpp.
Referenced by evaluate(), and execute().
| Generated by doxygen 1.7.1 on Thu May 24 2012 01:19:09 for The Battle for Wesnoth | Gna! | Forum | Wiki | CIA | devdocs |