69#define BARBARIAN_INITIAL_VISION_RADIUS 3
70#define BARBARIAN_INITIAL_VISION_RADIUS_SQ 9
144 if (nation !=
NULL) {
149 if (nation ==
NULL) {
191 _(
"%s gain a leader by the name %s. Dangerous "
192 "times may lie ahead."),
213 for (dir = 0; dir < 8; dir++) {
231 for (
i = 0;
i <= num;
i++) {
329 for (dir = 0; dir < 8; dir++) {
364 log_debug(
"Moved barbarian unit from (%d, %d) to (%d, %d)",
535 struct tile *ptile, *utile;
567 log_debug(
"Closest city (to %d,%d) is %s (at %d,%d) distance %d.",
589 log_debug(
"Barbarians are willing to fight");
724 _(
"Native unrest near %s led by %s."),
729 _(
"Sea raiders seen near %s!"),
bool is_action_enabled_unit_on_unit(const struct civ_map *nmap, const action_id wanted_action, const struct unit *actor_unit, const struct unit *target_unit)
bool adv_data_phase_init(struct player *pplayer, bool is_new_phase)
void adv_data_phase_done(struct player *pplayer)
#define CALL_PLR_AI_FUNC(_func, _player,...)
const char * default_ai_type_name(void)
static struct tile * find_empty_tile_nearby(struct tile *ptile)
static void try_summon_barbarians(void)
void barbarian_initial_wars(struct player *barbarians)
bool unleash_barbarians(struct tile *ptile)
void summon_barbarians(void)
#define BARBARIAN_INITIAL_VISION_RADIUS_SQ
static void init_dir_checked_status(bool *checked, enum terrain_class *terrainc, enum terrain_class tclass)
bool is_sea_barbarian(struct player *pplayer)
static bool is_near_land(struct tile *tile0)
static void unit_move_pay(struct unit *punit, struct tile *pdesttile)
bool is_land_barbarian(struct player *pplayer)
static int random_unchecked_direction(int possibilities, const bool *checked)
struct player * create_barbarian_player(enum barbarian_type type)
const char * city_name_get(const struct city *pcity)
#define city_owner(_pcity_)
struct unit struct city struct unit struct tile struct extra_type const struct act_prob *act_probs int actor_unit_id struct unit struct unit * punit
void set_ai_level_directer(struct player *pplayer, enum ai_level level)
void set_diplstate_type(struct player_diplstate *state1, struct player_diplstate *state2, enum diplstate_type type)
int get_player_bonus(const struct player *pplayer, enum effect_type effect_type)
const struct ft_color ftc_server
const char * city_link(const struct city *pcity)
#define log_verbose(message,...)
#define fc_assert(condition)
#define log_debug(message,...)
struct tile * rand_map_pos(const struct civ_map *nmap)
bool is_safe_ocean(const struct civ_map *nmap, const struct tile *ptile)
int real_map_distance(const struct tile *tile0, const struct tile *tile1)
struct tile * mapstep(const struct civ_map *nmap, const struct tile *ptile, enum direction8 dir)
#define square_iterate(nmap, center_tile, radius, tile_itr)
#define square_iterate_end
static int map_move_cost_unit(const struct civ_map *nmap, struct unit *punit, const struct tile *ptile)
#define whole_map_iterate(_map, _tile)
#define whole_map_iterate_end
bool map_is_known(const struct tile *ptile, const struct player *pplayer)
bool map_is_known_and_seen(const struct tile *ptile, const struct player *pplayer, enum vision_layer vlayer)
void map_show_circle(struct player *pplayer, struct tile *ptile, int radius_sq)
void update_tile_knowledge(struct tile *ptile)
void map_clear_known(struct tile *ptile, struct player *pplayer)
bool is_native_tile(const struct unit_type *punittype, const struct tile *ptile)
bool unit_can_move_to_tile(const struct civ_map *nmap, const struct unit *punit, const struct tile *dst_tile, bool igzoc, bool enter_transport, bool enter_enemy_city)
bool can_unit_type_transport(const struct unit_type *transporter, const struct unit_class *transported)
struct nation_type * nation_of_player(const struct player *pplayer)
const char * nation_plural_for_player(const struct player *pplayer)
struct government * init_government_of_nation(const struct nation_type *pnation)
void notify_player(const struct player *pplayer, const struct tile *ptile, enum event_type event, const struct ft_color color, const char *format,...)
int player_number(const struct player *pplayer)
const char * player_name(const struct player *pplayer)
struct player_diplstate * player_diplstate_get(const struct player *plr1, const struct player *plr2)
#define players_iterate_end
#define players_iterate(_pplayer)
void server_player_set_name(struct player *pplayer, const char *name)
void send_player_all_c(struct player *src, struct conn_list *dest)
struct player * server_create_player(int player_id, const char *ai_tname, struct rgbcolor *prgbcolor, bool allow_ai_type_fallbacking)
struct nation_type * pick_a_nation(const struct nation_list *choices, bool ignore_conflicts, bool needs_startpos, enum barbarian_type barb_type)
void player_status_reset(struct player *plr)
void server_player_init(struct player *pplayer, bool initmap, bool needs_team)
void assign_player_colors(void)
struct research * research_get(const struct player *pplayer)
const char * pick_random_player_name(const struct nation_type *pnation)
void player_nation_defaults(struct player *pplayer, struct nation_type *pnation, bool set_name)
bool game_was_started(void)
enum barbarians_rate barbarianrate
struct packet_game_info info
struct civ_game::@31::@35 server
enum ai_level skill_level
enum barbarian_type barbarian_type
struct player_ai ai_common
#define sz_strlcpy(dest, src)
#define is_ocean_tile(ptile)
#define terrain_has_flag(terr, flag)
bool tile_extra_rm_apply(struct tile *ptile, struct extra_type *tgt)
#define tile_terrain(_tile)
#define tile_has_extra(ptile, pextra)
int get_transporter_capacity(const struct unit *punit)
static bool is_non_allied_unit_tile(const struct tile *ptile, const struct player *pplayer)
void unit_do_action(struct player *pplayer, const int actor_id, const int target_id, const int sub_tgt_id, const char *name, const action_id action_type)
#define unit_list_iterate(unitlist, punit)
#define unit_list_iterate_safe(unitlist, _unit)
#define unit_list_iterate_end
#define unit_list_iterate_safe_end
struct unit_type * get_role_unit(int role, int role_index)
int num_role_units(int role)
bool utype_player_already_has_this_unique(const struct player *pplayer, const struct unit_type *putype)
const char * utype_rule_name(const struct unit_type *punittype)
static bool utype_has_flag(const struct unit_type *punittype, int flag)