81 log_debug(
"removing unit %d, %s %s (%d %d) hcity %d",
172 _(
"Changing production of every %s into %s."),
205 return Q_(
"?embassy:Both");
207 return Q_(
"?embassy:Yes");
210 return Q_(
"?embassy:With Us");
213 return Q_(
"?embassy:Contact");
215 return Q_(
"?embassy:No Contact");
227 return Q_(
"?vision:Both");
229 return Q_(
"?vision:To Them");
232 return Q_(
"?vision:To Us");
265 "The %s give %d gold",
pclause->value),
318 int numer = 20 * max;
362 / (
presearch->client.researching_cost + 1));
509 .value = {.building = pimprove}
701 struct city **selected_cities,
713 for (
id = first;
id < last;
id++) {
735 append |=
test_func(selected_cities[
i], &target);
836 }
else if (
NULL != pplayer) {
876 }
else if (
NULL != pplayer) {
935 struct unit_list *
plist;
953 struct unit_list *
plist;
1014 if (username && username[0] ==
'\0') {
1019 if (
NULL != username
1161 _(
"You can't buy %s in %s!"),
1178 "%s costs %d gold", value),
1184 PL_(
"%s and you only have %d gold.",
1185 "%s and you only have %d gold.",
1279 if (
pclass->hp_loss_pct > 0) {
1305 const struct city *
ca, *cb;
1307 ca = *((
const struct city **) a);
1308 cb = *((
const struct city **) b);
1322 if (!pplayer || !pplayer->
cities
1353 gold -=
cities[
i]->client.buy_cost;
1413 enum mapimg_layer layer;
1471 if (
NULL == filename ||
'\0' == filename[0]) {
1524 if (
is_ai(pplayer) && pplayer->ai_common.skill_level !=
lvl) {
void dbv_resize(struct dbv *pdbv, int bits)
void output_window_event(const char *plain_text, const struct text_tag_list *tags, int conn_id)
const char * city_improvement_name_translation(const struct city *pcity, const struct impr_type *pimprove)
bool city_has_building(const struct city *pcity, const struct impr_type *pimprove)
const char * city_name_get(const struct city *pcity)
void city_remove_improvement(struct city *pcity, const struct impr_type *pimprove)
bool can_city_build_improvement_now(const struct city *pcity, const struct impr_type *pimprove)
bool can_city_build_now(const struct civ_map *nmap, const struct city *pcity, const struct universal *target)
bool can_city_build_unit_now(const struct civ_map *nmap, const struct city *pcity, const struct unit_type *punittype)
bool city_production_is_genus(const struct city *pcity, enum impr_genus_id genus)
bool can_city_build_improvement_later(const struct city *pcity, const struct impr_type *pimprove)
bool can_city_build_unit_later(const struct civ_map *nmap, const struct city *pcity, const struct unit_type *punittype)
const char * city_production_name_translation(const struct city *pcity)
#define cities_iterate_end
#define city_list_iterate(citylist, pcity)
#define city_tile(_pcity_)
#define cities_iterate(pcity)
#define city_owner(_pcity_)
#define city_list_iterate_end
#define city_built_iterate(_pcity, _p)
#define city_built_iterate_end
int city_buy_production(struct city *pcity)
int city_change_production(struct city *pcity, struct universal *target)
bool city_can_buy(const struct city *pcity)
void refresh_city_dialog(struct city *pcity)
void city_report_dialog_update(void)
bool client_is_global_observer(void)
bool client_is_observer(void)
enum client_states client_state(void)
bool can_client_issue_orders(void)
bool client_has_player(void)
bool can_client_change_view(void)
enum known_type client_tile_get_known(const struct tile *ptile)
static int target_get_section(struct universal target)
int collect_eventually_buildable_targets(struct universal *targets, struct city *pcity, bool advanced_tech)
bool city_unit_supported(const struct city *pcity, const struct universal *target)
enum ai_level server_ai_level(void)
void client_change_all(struct universal *from, struct universal *to)
cid cid_encode_building(const struct impr_type *pimprove)
void create_event(struct tile *ptile, enum event_type event, const struct ft_color color, const char *format,...)
int collect_buildable_targets(struct universal *targets)
void client_player_init(struct player *pplayer)
bool mapimg_client_createmap(const char *filename)
void client_remove_city(struct city *pcity)
void client_unit_init_act_prob_cache(struct unit *punit)
void nuclear_winter_scaled(int *chance, int *rate, int max)
const char * get_embassy_status(const struct player *me, const struct player *them)
void buy_production_in_selected_cities(void)
void common_taxrates_callback(int idx, bool reverse)
static int city_buy_cost_compare(const void *a, const void *b)
bool mapimg_client_define(void)
int collect_currently_building_targets(struct universal *targets)
enum unit_bg_color_type unit_color_type(const struct unit_type *punittype)
struct sprite * client_warming_sprite(void)
bool can_units_do_connect(struct unit_list *punits, enum unit_activity activity, struct extra_type *tgt)
void cityrep_buy(struct city *pcity)
void global_warming_scaled(int *chance, int *rate, int max)
void client_player_maps_reset(void)
bool client_nation_is_in_current_set(const struct nation_type *pnation)
cid cid_encode_from_city(const struct city *pcity)
void name_and_sort_items(struct universal *targets, int num_targets, struct item *items, bool show_cost, struct city *pcity)
static int fc_cmp(const void *p1, const void *p2)
struct sprite * client_cooling_sprite(void)
struct sprite * client_research_sprite(void)
int num_present_units_in_city(struct city *pcity)
cid cid_encode(struct universal target)
void client_remove_unit(struct unit *punit)
bool city_building_present(const struct city *pcity, const struct universal *target)
struct nation_set * client_current_nation_set(void)
int num_supported_units_in_city(struct city *pcity)
int collect_already_built_targets(struct universal *targets, struct city *pcity)
struct city * get_nearest_city(const struct unit *punit, int *sq_dist)
struct universal cid_decode(cid id)
void unit_focus_set_status(struct player *pplayer)
void handle_event(const char *featured_text, struct tile *ptile, enum event_type event, int turn, int phase, int conn_id)
void center_on_something(void)
cid cid_encode_unit(const struct unit_type *punittype)
void client_diplomacy_clause_string(char *buf, int bufsiz, struct Clause *pclause)
const char * get_vision_status(const struct player *me, const struct player *them)
bool can_city_build_now_client(const struct city *pcity, const struct universal *target)
struct sprite * client_government_sprite(void)
static void catastrophe_scaled(int *chance, int *rate, int max, int current, int accum, int level)
bool city_unit_present(const struct city *pcity, const struct universal *target)
int collect_production_targets(struct universal *targets, struct city **selected_cities, int num_selected_cities, bool append_units, bool append_wonders, bool change_prod, TestCityFunc test_func)
#define MAX_NUM_PRODUCTION_TARGETS
bool(* TestCityFunc)(const struct city *, const struct universal *)
void connection_do_buffer(struct connection *pc)
void connection_do_unbuffer(struct connection *pc)
struct unit * get_focus_unit_on_tile(const struct tile *ptile)
struct unit_list * get_units_in_focus(void)
bool can_unit_do_connect(struct unit *punit, enum unit_activity activity, struct extra_type *tgt)
void update_unit_pix_label(struct unit_list *punitlist)
struct unit * head_of_units_in_focus(void)
int get_num_units_in_focus(void)
void unit_focus_advance(bool accept_current)
void control_unit_killed(struct unit *punit)
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
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 int const struct action *paction struct unit struct city * 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 int cost
#define PL_(String1, String2, n)
size_t featured_text_apply_tag(const char *text_source, char *featured_text, size_t featured_text_len, enum text_tag_type tag_type, ft_offset_t start_offset, ft_offset_t stop_offset,...)
enum text_link_type text_tag_link_type(const struct text_tag *ptag)
size_t featured_text_to_plain_text(const char *featured_text, char *plain_text, size_t plain_text_len, struct text_tag_list **tags, bool replace_link_text)
const struct ft_color ftc_client
const char * city_link(const struct city *pcity)
int text_tag_link_id(const struct text_tag *ptag)
struct text_tag * text_tag_new(enum text_tag_type tag_type, ft_offset_t start_offset, ft_offset_t stop_offset,...)
#define text_tag_list_iterate_end
#define text_tag_list_iterate(tags, ptag)
static bool ft_color_requested(const struct ft_color color)
void game_remove_unit(struct world *gworld, struct unit *punit)
void game_remove_city(struct world *gworld, struct city *pcity)
struct city * game_city_by_number(int id)
Government_type_id government_count(void)
struct government * government_of_player(const struct player *pplayer)
void popdown_city_dialog(struct city *pcity)
void popup_notify_goto_dialog(const char *headline, const char *lines, const struct text_tag_list *tags, struct tile *ptile)
void update_unit_info_label(struct unit_list *punits)
struct impr_type * improvement_by_number(const Impr_type_id id)
bool can_player_build_improvement_later(const struct player *p, const struct impr_type *pimprove)
bool can_player_build_improvement_now(const struct player *p, struct impr_type *pimprove)
Impr_type_id improvement_number(const struct impr_type *pimprove)
int impr_build_shield_cost(const struct city *pcity, const struct impr_type *pimprove)
bool is_wonder(const struct impr_type *pimprove)
bool is_great_wonder(const struct impr_type *pimprove)
bool is_convert_improvement(const struct impr_type *pimprove)
const char * improvement_name_translation(const struct impr_type *pimprove)
Impr_type_id improvement_count(void)
bool is_small_wonder(const struct impr_type *pimprove)
#define improvement_iterate_end
#define improvement_iterate(_p)
#define fc_assert_ret(condition)
#define log_verbose(message,...)
#define fc_assert(condition)
#define fc_assert_ret_val(condition, val)
#define log_debug(message,...)
int sq_map_distance(const struct tile *tile0, const struct tile *tile1)
struct tile * native_pos_to_tile(const struct civ_map *nmap, int nat_x, int nat_y)
#define iterate_outward(nmap, start_tile, max_dist, itr_tile)
#define iterate_outward_end
bool is_city_hilited(struct city *pcity)
struct mapdef * mapimg_isvalid(int id)
bool mapimg_define(const char *maparg, bool check)
bool mapimg_delete(int id)
bool mapimg_create(struct mapdef *pmapdef, bool force, const char *savename, const char *path)
void refresh_city_mapcanvas(struct city *pcity, struct tile *ptile, bool full_refresh, bool write_to_screen)
void center_tile_mapcanvas(const struct tile *ptile)
void link_mark_add_new(enum text_link_type type, int id)
void refresh_unit_mapcanvas(struct unit *punit, struct tile *ptile, bool full_refresh, bool write_to_screen)
void meswin_add(const char *message, const struct text_tag_list *tags, struct tile *ptile, enum event_type event, int turn, int phase)
const char * nation_rule_name(const struct nation_type *pnation)
struct nation_type * nation_of_unit(const struct unit *punit)
struct nation_type * nation_of_city(const struct city *pcity)
bool nation_is_in_set(const struct nation_type *pnation, const struct nation_set *pset)
struct nation_set * nation_set_by_setting_value(const char *setting)
const char * nation_plural_for_player(const struct player *pplayer)
const struct option_set * server_optset
const char * option_str_get(const struct option *poption)
enum option_type option_type(const struct option *poption)
int messages_where[E_COUNT]
struct client_options gui_options
struct option * optset_option_by_name(const struct option_set *poptset, const char *name)
int dsend_packet_player_rates(struct connection *pc, int tax, int luxury, int science)
void play_sound_for_event(enum event_type type)
struct city_list * cities
bool is_settable_ai_level(enum ai_level level)
const char * player_name(const struct player *pplayer)
struct city * player_primary_capital(const struct player *pplayer)
int player_index(const struct player *pplayer)
struct player_diplstate * player_diplstate_get(const struct player *plr1, const struct player *plr2)
bool can_player_see_units_in_city(const struct player *pplayer, const struct city *pcity)
bool can_player_see_city_internals(const struct player *pplayer, const struct city *pcity)
bool player_has_embassy(const struct player *pplayer, const struct player *pplayer2)
bool gives_shared_vision(const struct player *me, const struct player *them)
#define players_iterate_end
#define players_iterate(_pplayer)
bool are_universals_equal(const struct universal *psource1, const struct universal *psource2)
struct research * research_get(const struct player *pplayer)
struct setting_list * level[OLEVELS_NUM]
#define CLIP(lower, current, upper)
struct city::@18::@21 client
struct packet_game_info info
bool mapimg_layer[MAPIMG_LAYER_COUNT]
struct ft_color highlight_our_names
char mapimg_filename[512]
char username[MAX_LEN_NAME]
enum ai_level skill_level
struct city_list * cities
struct dbv tile_vision[V_COUNT]
struct player_economic economic
struct player::@73::@76 client
struct unit::@84::@86 client
struct act_prob * act_prob_cache
enum unit_focus_status focus_status
int fc_snprintf(char *str, size_t n, const char *format,...)
size_t fc_strlcpy(char *dest, const char *src, size_t n)
int fc_strcasecmp(const char *str0, const char *str1)
int cat_snprintf(char *str, size_t n, const char *format,...)
int fc_vsnprintf(char *str, size_t n, const char *format, va_list ap)
int fc_strncasecmp(const char *str0, const char *str1, size_t n)
#define sz_strlcpy(dest, src)
struct advance * advance_by_number(const Tech_type_id atype)
const char * advance_name_translation(const struct advance *padvance)
struct city * tile_city(const struct tile *ptile)
struct sprite * get_government_sprite(const struct tileset *t, const struct government *gov)
struct sprite * get_indicator_sprite(const struct tileset *t, enum indicator_type indicator, int idx)
struct sprite * get_citizen_sprite(const struct tileset *t, enum citizen_category type, int citizen_index, const struct city *pcity)
#define NUM_TILES_PROGRESS
const struct unit_type * utype
const struct impr_type * building
int get_transporter_occupancy(const struct unit *ptrans)
bool unit_transport_unload(struct unit *pcargo)
struct unit_list * unit_transport_cargo(const struct unit *ptrans)
#define unit_list_iterate(unitlist, punit)
#define unit_list_iterate_end
const struct unit_type * unit_type_get(const struct unit *punit)
const char * unit_rule_name(const struct unit *punit)
Unit_type_id utype_count(void)
struct unit_type * utype_by_number(const Unit_type_id id)
Unit_type_id utype_number(const struct unit_type *punittype)
bool can_player_build_unit_later(const struct player *p, const struct unit_type *punittype)
int utype_build_shield_cost(const struct city *pcity, const struct player *pplayer, const struct unit_type *punittype)
bool can_player_build_unit_now(const struct player *p, const struct unit_type *punittype)
const char * utype_name_translation(const struct unit_type *punittype)
const char * utype_values_translation(const struct unit_type *punittype)
static bool uclass_has_flag(const struct unit_class *punitclass, enum unit_class_flag_id flag)
static bool utype_has_flag(const struct unit_type *punittype, int flag)
#define unit_type_iterate(_p)
#define unit_type_iterate_end
#define vision_layer_iterate(v)
#define vision_layer_iterate_end
#define MAP_NATIVE_HEIGHT