#include <pathfind.hpp>


Public Member Functions | |
| shortest_path_calculator (const unit &u, const team &t, const unit_map &units, const std::vector< team > &teams, const gamemap &map, bool ignore_unit=false, bool ignore_defense_=false, bool see_all=false) | |
| virtual double | cost (const map_location &loc, const double so_far) const |
Private Attributes | |
| unit const & | unit_ |
| team const & | viewing_team_ |
| unit_map const & | units_ |
| std::vector< team > const & | teams_ |
| gamemap const & | map_ |
| int const | movement_left_ |
| int const | total_movement_ |
| bool const | ignore_unit_ |
| bool const | ignore_defense_ |
| bool | see_all_ |
Definition at line 209 of file pathfind.hpp.
| pathfind::shortest_path_calculator::shortest_path_calculator | ( | const unit & | u, | |
| const team & | t, | |||
| const unit_map & | units, | |||
| const std::vector< team > & | teams, | |||
| const gamemap & | map, | |||
| bool | ignore_unit = false, |
|||
| bool | ignore_defense_ = false, |
|||
| bool | see_all = false | |||
| ) |
Definition at line 572 of file pathfind.cpp.
| double pathfind::shortest_path_calculator::cost | ( | const map_location & | loc, | |
| const double | so_far | |||
| ) | const [virtual] |
Implements pathfind::cost_calculator.
Definition at line 582 of file pathfind.cpp.
References _, unit::defense_modifier(), pathfind::enemy_zoc(), unit::get_ability_bool(), get_visible_unit(), pathfind::cost_calculator::getNoPathValue(), ignore_defense_, ignore_unit_, map_, unit::movement_cost(), movement_left_, gamemap::on_board(), see_all_, team::shrouded(), unit::side(), teams_, gui2::terrain, total_movement_, unit_, VALIDATE, and viewing_team_.

bool const pathfind::shortest_path_calculator::ignore_defense_ [private] |
Definition at line 226 of file pathfind.hpp.
Referenced by cost().
bool const pathfind::shortest_path_calculator::ignore_unit_ [private] |
Definition at line 225 of file pathfind.hpp.
Referenced by cost().
gamemap const& pathfind::shortest_path_calculator::map_ [private] |
Definition at line 222 of file pathfind.hpp.
Referenced by cost().
int const pathfind::shortest_path_calculator::movement_left_ [private] |
Definition at line 223 of file pathfind.hpp.
Referenced by cost().
bool pathfind::shortest_path_calculator::see_all_ [private] |
Definition at line 227 of file pathfind.hpp.
Referenced by cost().
std::vector<team> const& pathfind::shortest_path_calculator::teams_ [private] |
Definition at line 221 of file pathfind.hpp.
Referenced by cost().
int const pathfind::shortest_path_calculator::total_movement_ [private] |
Definition at line 224 of file pathfind.hpp.
Referenced by cost().
unit const& pathfind::shortest_path_calculator::unit_ [private] |
Definition at line 218 of file pathfind.hpp.
Referenced by cost().
unit_map const& pathfind::shortest_path_calculator::units_ [private] |
Definition at line 220 of file pathfind.hpp.
team const& pathfind::shortest_path_calculator::viewing_team_ [private] |
Definition at line 219 of file pathfind.hpp.
Referenced by cost().
| Generated by doxygen 1.7.1 on Fri May 25 2012 01:24:42 for The Battle for Wesnoth | Gna! | Forum | Wiki | CIA | devdocs |