The Battle for Wesnoth  1.19.5+dev
Namespaces | Macros | Functions | Variables
move.cpp File Reference

Movement. More...

#include "actions/move.hpp"
#include "actions/undo.hpp"
#include "actions/vision.hpp"
#include "game_events/pump.hpp"
#include "preferences/preferences.hpp"
#include "gettext.hpp"
#include "hotkey/hotkey_item.hpp"
#include "hotkey/hotkey_command.hpp"
#include "log.hpp"
#include "map/map.hpp"
#include "mouse_handler_base.hpp"
#include "pathfind/pathfind.hpp"
#include "pathfind/teleport.hpp"
#include "replay.hpp"
#include "replay_helper.hpp"
#include "synced_context.hpp"
#include "play_controller.hpp"
#include "resources.hpp"
#include "units/udisplay.hpp"
#include "font/standard_colors.hpp"
#include "formula/string_utils.hpp"
#include "team.hpp"
#include "units/unit.hpp"
#include "units/animation_component.hpp"
#include "whiteboard/manager.hpp"
#include <deque>
#include <set>
Include dependency graph for move.cpp:

Go to the source code of this file.

Namespaces

 actions
 

Macros

#define ERR_NG   LOG_STREAM(err, log_engine)
 
#define DBG_NG   LOG_STREAM(debug, log_engine)
 

Functions

game_events::pump_result_t actions::get_village (const map_location &loc, int side, bool *time_bonus=nullptr, bool fire_event=true)
 Makes it so the village at the given location is owned by the given side. More...
 
static void actions::move_unit_internal (unit_mover &mover)
 
void actions::execute_move_unit (const std::vector< map_location > &steps, bool continued_move, bool skip_ally_sighted, move_unit_spectator *move_spectator)
 Moves a unit across the board. More...
 
void actions::teleport_unit_and_record (const map_location &teleport_from, const map_location &teleport_to, move_unit_spectator *move_spectator=nullptr)
 Teleports a unit across the board and enters the synced context. More...
 
void actions::teleport_unit_from_replay (const std::vector< map_location > &steps, bool continued_move, bool skip_ally_sighted, bool show_move)
 Teleports a unit across the board. More...
 
std::size_t actions::move_unit_and_record (const std::vector< map_location > &steps, bool continued_move, bool *interrupted)
 Wrapper around the other overload. More...
 
void actions::move_unit_and_record (const std::vector< map_location > &steps, bool continued_move, move_unit_spectator &move_spectator)
 Moves a unit across the board. More...
 

Variables

static lg::log_domain log_engine ("engine")
 

Detailed Description

Movement.

Definition in file move.cpp.

Macro Definition Documentation

◆ DBG_NG

#define DBG_NG   LOG_STREAM(debug, log_engine)

Definition at line 54 of file move.cpp.

◆ ERR_NG

#define ERR_NG   LOG_STREAM(err, log_engine)

Definition at line 53 of file move.cpp.

Variable Documentation

◆ ambush_limit_

route_iterator ambush_limit_
private

Definition at line 333 of file move.cpp.

◆ ambush_stop_

map_location ambush_stop_
private

Definition at line 353 of file move.cpp.

◆ ambush_string_

std::string ambush_string_
private

Definition at line 367 of file move.cpp.

◆ ambushed_

bool ambushed_
private

Definition at line 355 of file move.cpp.

◆ ambushers_

std::vector<map_location> ambushers_
private

Definition at line 368 of file move.cpp.

◆ begin_

const route_iterator begin_
private

Definition at line 330 of file move.cpp.

Referenced by t_string_base::walker::update().

◆ blocked_loc_

map_location blocked_loc_
private

Definition at line 354 of file move.cpp.

◆ clearer_

shroud_clearer clearer_
private

Definition at line 371 of file move.cpp.

◆ current_side_

int current_side_
private

Definition at line 347 of file move.cpp.

◆ current_team_

team* current_team_
private

Definition at line 348 of file move.cpp.

◆ current_uses_fog_

bool current_uses_fog_
private

Definition at line 349 of file move.cpp.

◆ enemy_count_

std::size_t enemy_count_
private

Definition at line 365 of file move.cpp.

◆ event_mutated_mid_move_

bool event_mutated_mid_move_
private

Definition at line 360 of file move.cpp.

◆ expected_end_

route_iterator expected_end_
private

Definition at line 332 of file move.cpp.

◆ fog_changed_

bool fog_changed_
private

Definition at line 361 of file move.cpp.

◆ friend_count_

std::size_t friend_count_
private

Definition at line 366 of file move.cpp.

◆ full_end_

const route_iterator full_end_
private

Definition at line 331 of file move.cpp.

◆ goto_

const map_location goto_
private

Definition at line 344 of file move.cpp.

◆ log_engine

lg::log_domain log_engine("engine") ( "engine"  )
static

◆ move_it_

unit_map::iterator move_it_
private

Definition at line 338 of file move.cpp.

◆ move_loc_

route_iterator move_loc_
private

Definition at line 350 of file move.cpp.

◆ moves_left_

std::deque<int> moves_left_
private

Definition at line 369 of file move.cpp.

◆ obstructed_

route_iterator obstructed_
private

Definition at line 334 of file move.cpp.

◆ orig_dir_

const map_location::direction orig_dir_
private

Definition at line 343 of file move.cpp.

◆ orig_moves_

const int orig_moves_
private

Definition at line 342 of file move.cpp.

◆ orig_side_

const int orig_side_
private

Definition at line 341 of file move.cpp.

◆ playing_team_is_viewing_

const bool playing_team_is_viewing_
private

Definition at line 325 of file move.cpp.

◆ real_end_

route_iterator real_end_
private

Definition at line 335 of file move.cpp.

◆ route_

const std::vector<map_location>& route_
private

Definition at line 327 of file move.cpp.

Referenced by footsteps_images().

◆ show_ambush_alert_

bool show_ambush_alert_
private

Definition at line 356 of file move.cpp.

◆ sighted_

bool sighted_
private

Definition at line 362 of file move.cpp.

◆ sighted_stop_

bool sighted_stop_
private

Definition at line 363 of file move.cpp.

◆ skip_ally_sighting_

const bool skip_ally_sighting_
private

Definition at line 324 of file move.cpp.

◆ skip_sighting_

const bool skip_sighting_
private

Definition at line 323 of file move.cpp.

◆ spectator_

move_unit_spectator* const spectator_
private

Definition at line 322 of file move.cpp.

◆ teleport_failed_

bool teleport_failed_
private

Definition at line 364 of file move.cpp.

◆ wml_move_aborted_

bool wml_move_aborted_
private

Definition at line 359 of file move.cpp.

◆ wml_removed_unit_

bool wml_removed_unit_
private

Definition at line 357 of file move.cpp.

◆ wml_undo_disabled_

bool wml_undo_disabled_
private

Definition at line 358 of file move.cpp.

◆ zoc_stop_

map_location zoc_stop_
private

Definition at line 352 of file move.cpp.