26 #ifndef EDITOR_ACTION_UNIT_HPP
27 #define EDITOR_ACTION_UNIT_HPP
50 const char*
get_name()
const {
return "unit"; }
68 const char*
get_name()
const {
return "unit_delete"; }
81 const char*
get_name()
const {
return "unit_replace"; }
96 const char*
get_name()
const {
return "unit_facing"; }
editor_action * perform(map_context &mc) const
Perform the action, returning an undo action that, when performed, shall reverse any effects of this ...
editor_action_unit_facing * clone() const
Action cloning.
editor_action_unit_delete(map_location loc)
editor_action_unit_replace * clone() const
Action cloning.
void perform_without_undo(map_context &mc) const
Perform the action without creating an undo action.
editor_action * perform(map_context &mc) const
Perform the action, returning an undo action that, when performed, shall reverse any effects of this ...
editor_action * perform(map_context &mc) const
Perform the action, returning an undo action that, when performed, shall reverse any effects of this ...
Base class for actions which act on a specified location (and possibly on other locations that can be...
void perform_without_undo(map_context &mc) const
Perform the action without creating an undo action.
editor_action_unit * clone() const
Action cloning.
void perform_without_undo(map_context &mc) const
Perform the action without creating an undo action.
editor_action_unit_replace(map_location loc, map_location new_loc)
const char * get_name() const
const char * get_name() const
editor_action_unit_delete * clone() const
Action cloning.
editor_action * perform(map_context &mc) const
Perform the action, returning an undo action that, when performed, shall reverse any effects of this ...
Manage the empty-palette in the editor.
Encapsulates the map of the game.
place a new unit on the map
editor_action_unit(map_location loc, const unit &u)
Base class for all editor actions.
editor_action_unit_facing(map_location loc, map_location::DIRECTION new_direction, map_location::DIRECTION old_direction)
DIRECTION
Valid directions which can be moved in our hexagonal world.
void perform_without_undo(map_context &mc) const
Perform the action without creating an undo action.
This class wraps around a map to provide a concise interface for the editor to work with...
Remove a unit from the map.
map_location::DIRECTION old_direction_
map_location::DIRECTION new_direction_
const char * get_name() const
const char * get_name() const