43#define TILE_XY(ptile) ((ptile) ? index_to_map_pos_x(tile_index(ptile)) \
45 ((ptile) ? index_to_map_pos_y(tile_index(ptile)) \
48#define TILE_INDEX_NONE (-1)
70#define SPECLIST_TAG tile
71#define SPECLIST_TYPE struct tile
73#define tile_list_iterate(tile_list, ptile) \
74 TYPED_LIST_ITERATE(struct tile, tile_list, ptile)
75#define tile_list_iterate_end LIST_ITERATE_END
78#define SPECHASH_TAG tile
79#define SPECHASH_IKEY_TYPE struct tile *
80#define SPECHASH_IDATA_TYPE void *
82#define tile_hash_iterate(hash, ptile) \
83 TYPED_HASH_KEYS_ITERATE(struct tile *, hash, ptile)
84#define tile_hash_iterate_end HASH_KEYS_ITERATE_END
88#define tile_index(_pt_) (_pt_)->index
92#define tile_continent(_tile) ((_tile)->continent)
96#define tile_owner(_tile) ((_tile)->owner)
99 struct tile *claimer);
100#define tile_claimer(_tile) ((_tile)->claimer)
102#define tile_resource(_tile) ((_tile)->resource)
110#define tile_terrain(_tile) ((_tile)->terrain)
114#define tile_worked(_tile) ((_tile)->worked)
147#define tile_has_extra(ptile, pextra) BV_ISSET(ptile->extras, extra_index(pextra))
157 const struct player *pplayer);
165#define ACTIVITY_FACTOR 10
167 const struct tile *ptile,
175#define TILE_LB_TERRAIN_RIVER (1 << 0)
176#define TILE_LB_RIVER_RESOURCE (1 << 1)
177#define TILE_LB_RESOURCE_POLL (1 << 2)
#define BV_ISSET(bv, bit)
struct unit struct city struct unit struct tile * target_tile
enum unit_activity Activity_type_id
signed short Continent_id
struct extra_type * resource
struct player * extras_owner
struct extra_type * placing
int tile_extras_class_defense_bonus(const struct tile *ptile, const struct unit_class *pclass)
void tile_add_extra(struct tile *ptile, const struct extra_type *pextra)
int tile_roads_output_bonus(const struct tile *ptile, enum output_type_id o)
bool tile_has_extra_flag(const struct tile *ptile, enum extra_flag_id flag)
bool tile_has_claimable_base(const struct tile *ptile, const struct unit_type *punittype)
void tile_set_terrain(struct tile *ptile, struct terrain *pterrain)
void tile_virtual_destroy(struct tile *vtile)
bool tile_extra_apply(struct tile *ptile, struct extra_type *tgt)
bool tile_is_placing(const struct tile *ptile)
const bv_extras * tile_extras_null(void)
bool tile_has_river(const struct tile *tile)
bool tile_apply_activity(struct tile *ptile, Activity_type_id act, struct extra_type *tgt)
bool tile_map_check(struct civ_map *nmap, struct tile *vtile)
bool tile_has_base(const struct tile *ptile, const struct base_type *pbase)
void tile_remove_extra(struct tile *ptile, const struct extra_type *pextra)
void tile_change_terrain(struct tile *ptile, struct terrain *pterrain)
bool tile_has_visible_extra(const struct tile *ptile, const struct extra_type *pextra)
bool tile_has_refuel_extra(const struct tile *ptile, const struct unit_class *uclass)
static bool tile_resource_is_valid(const struct tile *ptile)
int tile_extras_defense_bonus(const struct tile *ptile, const struct unit_type *punittype)
bool tile_has_road(const struct tile *ptile, const struct road_type *proad)
bool tile_has_conflicting_extra(const struct tile *ptile, const struct extra_type *pextra)
void tile_set_owner(struct tile *ptile, struct player *pplayer, struct tile *claimer)
bool tile_is_seen(const struct tile *target_tile, const struct player *pow_player)
int tile_activity_time(enum unit_activity activity, const struct tile *ptile, const struct extra_type *tgt)
struct tile * tile_virtual_new(const struct tile *ptile)
bool tile_has_native_base(const struct tile *ptile, const struct unit_type *punittype)
int tile_roads_output_incr(const struct tile *ptile, enum output_type_id o)
void * tile_hash_key(const struct tile *ptile)
bool tile_extra_rm_apply(struct tile *ptile, struct extra_type *tgt)
bool tile_set_label(struct tile *ptile, const char *label)
void tile_set_resource(struct tile *ptile, struct extra_type *presource)
int tile_has_not_aggressive_extra_for_unit(const struct tile *ptile, const struct unit_type *punittype)
enum known_type tile_get_known(const struct tile *ptile, const struct player *pplayer)
const bv_extras * tile_extras_safe(const struct tile *ptile)
const char * tile_get_info_text(const struct tile *ptile, bool include_nuisances, int linebreaks)
bool tile_has_road_flag(const struct tile *ptile, enum road_flag_id flag)
struct city * tile_city(const struct tile *ptile)
bool tile_has_cause_extra(const struct tile *ptile, enum extra_cause cause)
static const bv_extras * tile_extras(const struct tile *ptile)
void tile_set_worked(struct tile *ptile, struct city *pcity)
void tile_set_continent(struct tile *ptile, Continent_id val)