21 #ifndef ACTIONS_CREATE_H_INCLUDED
22 #define ACTIONS_CREATE_H_INCLUDED
34 #include <boost/tuple/tuple.hpp>
107 const unit &unit_recall);
153 int cost,
bool is_recall,
bool show =
false,
bool fire_event =
true,
bool full_movement =
false,
154 bool wml_triggered =
false);
178 bool show=
true,
bool use_undo=
true);
place_recruit_result place_recruit(unit_ptr u, const map_location &recruit_location, const map_location &recruited_from, int cost, bool is_recall, bool show, bool fire_event, bool full_movement, bool wml_triggered)
Recruitment OK, but not at the specified location.
RECRUIT_CHECK
The possible results of finding a location for recruiting (or recalling).
std::vector< unit_const_ptr > get_recalls(int side, const map_location &recall_loc)
Gets the recallable units for a side, restricted by that side's leaders' personal abilities to recall...
This class stores all the data for a single 'side' (in game nomenclature).
void recruit_unit(const unit_type &u_type, int side_num, const map_location &loc, const map_location &from, bool show, bool use_undo)
Recruits a unit of the given type for the given side.
const std::set< std::string > get_recruits(int side, const map_location &recruit_loc)
Gets the recruitable units from a side's leaders' personal recruit lists who can recruit on or from a...
boost::tuple< bool, int, bool > place_recruit_result
Place a unit into the game.
No vacant castle tiles around a leader on a keep.
void show(CVideo &video, const std::string &window_id, const t_string &message, const tpoint &mouse)
Shows a tip.
Encapsulates the map of the game.
RECRUIT_CHECK check_recall_location(const int side, map_location &recall_location, map_location &recall_from, const unit &unit_recall)
Checks if there is a location on which to recall unit_recall.
No able leaders are on a keep.
Various functions related to the creation of units (recruits, recalls, and placed units)...
std::string find_recall_location(const int side, map_location &recall_location, map_location &recall_from, const unit &unit_recall)
Finds a location on which to recall unit_recall.
RECRUIT_CHECK check_recruit_location(const int side, map_location &recruit_location, map_location &recruited_from, const std::string &unit_type)
Checks if there is a location on which to place a recruited 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.
A variable-expanding proxy for the config class.
std::string find_recruit_location(const int side, map_location &recruit_location, map_location &recruited_from, const std::string &unit_type)
Finds a location on which to place a unit.
bool recall_unit(const std::string &id, team ¤t_team, const map_location &loc, const map_location &from, bool show, bool use_undo)
Recalls the unit with the indicated ID for the provided team.
A config object defines a single node in a WML file, with access to child nodes.
GLsizei const GLcharARB ** string
No leaders able to recall/recruit the given unit/type.