20 #ifndef ACTIONS_MOVE_H_INCLUDED
21 #define ACTIONS_MOVE_H_INCLUDED
106 bool continued_move =
false,
107 bool show_move =
true,
108 bool* interrupted =
nullptr,
115 bool continued_move,
bool skip_ally_sighted,
116 bool show_move =
true);
size_t move_unit_and_record(const std::vector< map_location > &steps, undo_list *undo_stack, bool continued_move, bool show_move, bool *interrupted, move_unit_spectator *move_spectator)
Moves a unit across the board.
void reset(const unit_map &units)
reset all locations to empty values
bool get_village(const map_location &loc, int side, bool *action_timebonus, bool fire_event)
Makes it so the village at the given location is owned by the given side.
const std::vector< unit_map::const_iterator > & get_seen_friends() const
get the locations of seen friends
unit_map::const_iterator failed_teleport_
const std::vector< unit_map::const_iterator > & get_seen_enemies() const
get the locations of seen enemies
std::vector< unit_map::const_iterator > seen_friends_
const unit_map::const_iterator & get_failed_teleport() const
get the location of a failed teleport
void add_seen_enemy(const unit_map::const_iterator &u)
add the location of new seen enemy
void set_failed_teleport(const unit_map::const_iterator &u)
set the location of a failed teleport
void set_ambusher(const unit_map::const_iterator &u)
set the location of an ambusher
unit_map::const_iterator ambusher_
move_unit_spectator(const unit_map &units)
constructor
Encapsulates the map of the game.
std::vector< unit_map::const_iterator > seen_enemies_
const unit_map::const_iterator & get_ambusher() const
get the location of an ambusher
size_t move_unit_from_replay(const std::vector< map_location > &steps, undo_list *undo_stack, bool continued_move, bool skip_ally_sighted, bool show_move)
Moves a unit across the board.
const unit_map::const_iterator & get_unit() const
get new location of moved unit
bool fire_event(const tevent event, std::vector< std::pair< twidget *, tevent > > &event_chain, twidget *dispatcher, twidget *widget, F functor)
Helper function for fire_event.
unit_map::const_iterator unit_
void set_unit(const unit_map::const_iterator &u)
set the iterator to moved unit
Class to store the actions that a player can undo and redo.
void add_seen_friend(const unit_map::const_iterator &u)
add a location of a seen friend
Container associating units to locations.
actions::undo_list * undo_stack
virtual ~move_unit_spectator()
destructor