281 .value.building = impr
567 }
else if (
peffect->value < 0) {
659 if (
peffect->type == effect_type) {
676 const struct player *other_player,
705 .value = {.building = pimprove}
724 .building = pimprove,
750 const struct player *other_player,
751 enum effect_type effect_type)
794 const struct player *other_player,
795 enum effect_type effect_type,
829 enum effect_type effect_type)
888 enum effect_type effect_type)
917 const struct tile *ptile,
919 enum effect_type effect_type)
941 const struct tile *ptile,
943 enum effect_type effect_type)
963 enum effect_type effect_type)
986 enum effect_type effect_type)
1010 enum effect_type effect_type)
1021 .building = building,
1036 const struct tile *ptile,
1039 enum effect_type effect_type)
1049 if (ptile !=
NULL) {
1096 enum effect_type
etype)
1131 const struct player *pplayer,
1132 enum effect_type effect_type)
1154 const struct city *pcity,
1156 enum effect_type effect_type)
1183 enum effect_type effect_type,
1205 const struct city *pcity,
1206 enum effect_type effect_type,
1211 .value = {.building = pimprove}};
1215 if (pcity !=
NULL) {
1224 .building = pimprove,
1228 bool present =
TRUE;
1231 if (
peffect->type != effect_type) {
1237 &&
preq->source.value.building == pimprove) {
1238 present =
preq->present;
1287 if (!
preq->present) {
1290 if (
buf[0] !=
'\0') {
#define city_tile(_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 effect_remove(struct effect *peffect)
void recv_ruleset_effect(const struct packet_ruleset_effect *packet)
struct effect_list * effects[EFT_COUNT]
struct effect_list * govs[G_LAST]
struct effect_list * tracker
struct user_effect ueffects[EFT_USER_EFFECT_LAST+1 - EFT_USER_EFFECT_1]
bool effect_universals_value_never_below(enum effect_type type, struct universal *unis, size_t n_unis, int min_value)
int get_tile_output_bonus(const struct city *pcity, const struct tile *ptile, const struct output_type *poutput, enum effect_type effect_type)
int get_player_output_bonus(const struct player *pplayer, const struct output_type *poutput, enum effect_type effect_type)
int get_city_specialist_output_bonus(const struct city *pcity, const struct specialist *pspecialist, const struct output_type *poutput, enum effect_type effect_type)
bool is_building_replaced(const struct city *pcity, const struct impr_type *pimprove, const enum req_problem_type prob_type)
int get_target_bonus_effects(struct effect_list *plist, const struct req_context *context, const struct player *other_player, enum effect_type effect_type)
int get_player_bonus_effects(struct effect_list *plist, const struct player *pplayer, enum effect_type effect_type)
bool iterate_effect_cache(iec_cb cb, void *data)
int get_city_bonus(const struct city *pcity, enum effect_type effect_type)
int get_current_construction_bonus(const struct city *pcity, enum effect_type effect_type, const enum req_problem_type prob_type)
int get_city_bonus_effects(struct effect_list *plist, const struct city *pcity, const struct output_type *poutput, enum effect_type effect_type)
static bool is_effect_prevented(const struct req_context *context, const struct player *other_player, const struct effect *peffect, const enum req_problem_type prob_type)
int get_unit_vs_tile_bonus(const struct tile *ptile, const struct unit *punit, enum effect_type etype)
int get_unit_bonus(const struct unit *punit, enum effect_type effect_type)
int get_city_output_bonus(const struct city *pcity, const struct output_type *poutput, enum effect_type effect_type)
int get_potential_improvement_bonus(const struct impr_type *pimprove, const struct city *pcity, enum effect_type effect_type, const enum req_problem_type prob_type, bool consider_multipliers)
void send_ruleset_cache(struct conn_list *dest)
void get_effect_req_text(const struct effect *peffect, char *buf, size_t buf_len)
static struct @21 ruleset_cache
struct effect_list * buildings[B_LAST]
void ruleset_cache_free(void)
struct effect * effect_new(enum effect_type type, int value, struct multiplier *pmul)
int get_building_bonus(const struct city *pcity, const struct impr_type *building, enum effect_type effect_type)
int effect_value_from_universals(enum effect_type type, struct universal *unis, size_t n_unis)
int get_city_tile_output_bonus(const struct city *pcity, const struct tile *ptile, const struct output_type *poutput, enum effect_type effect_type)
void user_effect_ai_valued_set(enum effect_type tgt, enum effect_type valued_as)
struct effect * effect_copy(struct effect *old, enum effect_type override_type)
int effect_cumulative_max(enum effect_type type, struct universal *unis, size_t n_unis)
void effect_free(struct effect *peffect)
void ruleset_cache_init(void)
struct effect_list * advances[A_LAST]
int get_world_bonus(enum effect_type effect_type)
int effect_cumulative_min(enum effect_type type, struct universal *for_uni)
struct effect_list * get_effects(enum effect_type effect_type)
struct effect_list * get_req_source_effects(const struct universal *psource)
enum effect_type user_effect_ai_valued_as(enum effect_type real)
bool building_has_effect(const struct impr_type *pimprove, enum effect_type effect_type)
double get_effect_expected_value(const struct req_context *context, const struct player *other_player, enum effect_type effect_type, eft_value_filter_cb weighter, void *data, int n_data)
void effect_req_append(struct effect *peffect, struct requirement req)
int get_tile_bonus(const struct tile *ptile, enum effect_type effect_type)
int get_unittype_bonus(const struct player *pplayer, const struct tile *ptile, const struct unit_type *punittype, const struct action *paction, enum effect_type effect_type)
int get_player_bonus(const struct player *pplayer, enum effect_type effect_type)
void get_effect_list_req_text(const struct effect_list *plist, struct astring *astr)
bool is_user_effect(enum effect_type eff)
int effect_value_will_make_positive(enum effect_type type)
#define effect_list_iterate_end
#define USER_EFFECT_NUMBER(eff)
double(* eft_value_filter_cb)(const struct effect *eft, const struct req_context *context, const struct player *other_player, void *data, int n_data)
bool(* iec_cb)(struct effect *, void *data)
#define EFT_USER_EFFECT_LAST
#define effect_list_iterate(effect_list, peffect)
static bool is_server(void)
Government_type_id government_count(void)
static GtkWidget * source
struct impr_type * improvement_by_number(const Impr_type_id id)
Impr_type_id improvement_number(const struct impr_type *pimprove)
bool improvement_has_flag(const struct impr_type *pimprove, enum impr_flag_id flag)
Impr_type_id improvement_count(void)
#define improvement_iterate_end
#define improvement_iterate(_p)
#define fc_assert(condition)
#define fc_assert_ret_val(condition, val)
const char * multiplier_name_translation(const struct multiplier *pmul)
Multiplier_type_id multiplier_number(const struct multiplier *pmul)
struct multiplier * multiplier_by_number(Multiplier_type_id id)
void lsend_packet_ruleset_effect(struct conn_list *dest, const struct packet_ruleset_effect *packet)
int player_multiplier_effect_value(const struct player *pplayer, const struct multiplier *pmul)
const struct req_context * req_context_empty(void)
void universal_extraction(const struct universal *source, int *kind, int *value)
bool universal_fulfills_requirements(bool check_necessary, const struct requirement_vector *reqs, const struct universal *source)
bool is_req_active(const struct req_context *context, const struct player *other_player, const struct requirement *req, const enum req_problem_type prob_type)
bool are_reqs_active(const struct req_context *context, const struct player *other_player, const struct requirement_vector *reqs, const enum req_problem_type prob_type)
enum req_item_found universal_fulfills_requirement(const struct requirement *preq, const struct universal *source)
bool universals_say_everything(struct requirement_vector *reqs, struct universal *unis, size_t n_unis)
const char * universal_name_translation(const struct universal *psource, char *buf, size_t bufsz)
bool universals_mean_unfulfilled(struct requirement_vector *reqs, struct universal *unis, size_t n_unis)
#define requirement_vector_iterate_end
#define requirement_vector_iterate(req_vec, preq)
void strvec_destroy(struct strvec *psv)
void strvec_append(struct strvec *psv, const char *string)
struct strvec * strvec_new(void)
const char * strvec_to_and_list(const struct strvec *psv, struct astring *astr)
struct universal production
enum counter_behaviour type
struct multiplier * multiplier
struct requirement_vector reqs
struct requirement reqs[MAX_NUM_REQS]
Multiplier_type_id multiplier
enum effect_type effect_type
const struct player * player
enum effect_type ai_value_as
size_t fc_strlcat(char *dest, const char *src, size_t n)
static Tech_type_id advance_count(void)
struct city * tile_city(const struct tile *ptile)
#define tile_owner(_tile)
enum impr_flag_id impr_flag
const struct impr_type * building
const struct unit_type * unit_type_get(const struct unit *punit)