![]() |
Freeciv21
Develop your civilization from humble roots to a global empire
|
#include "bitvector.h"#include "base.h"#include "extras.h"#include "fc_types.h"#include "player.h"#include "road.h"#include "terrain.h"#include "unitlist.h"#include "speclist.h"
Include dependency graph for tile.h:
This graph shows which files directly or indirectly include this file:Go to the source code of this file.
Classes | |
| struct | tile |
Macros | |
| #define | TILE_XY(ptile) |
| #define | TILE_INDEX_NONE (-1) |
| #define | SPECLIST_TAG tile |
| #define | SPECLIST_TYPE struct tile |
| #define | tile_list_iterate(tile_list, ptile) TYPED_LIST_ITERATE(struct tile, tile_list, ptile) |
| #define | tile_list_iterate_end LIST_ITERATE_END |
| #define | tile_index(_pt_) (_pt_)->index |
| #define | tile_continent(_tile) ((_tile)->continent) |
| #define | tile_owner(_tile) ((_tile)->owner) |
| #define | tile_claimer(_tile) ((_tile)->claimer) |
| #define | tile_resource(_tile) ((_tile)->resource) |
| #define | tile_terrain(_tile) ((_tile)->terrain) |
| #define | tile_worked(_tile) ((_tile)->worked) |
| #define | tile_has_extra(ptile, pextra) BV_ISSET(ptile->extras, extra_index(pextra)) |
| #define | ACTIVITY_FACTOR 10 |
| #define | TILE_LB_TERRAIN_RIVER (1 << 0) |
| #define | TILE_LB_RIVER_RESOURCE (1 << 1) |
| #define | TILE_LB_RESOURCE_POLL (1 << 2) |
Enumerations | |
| enum | known_type { TILE_UNKNOWN = 0 , TILE_KNOWN_UNSEEN = 1 , TILE_KNOWN_SEEN = 2 } |
Functions | |
| struct city * | tile_city (const struct tile *ptile) |
| Return the city on this tile (or nullptr), checking for city center. More... | |
| void | tile_set_continent (struct tile *ptile, Continent_id val) |
| Set the continent ID of the tile. More... | |
| void | tile_set_owner (struct tile *ptile, struct player *pplayer, struct tile *claimer) |
| Set the owner of a tile (may be nullptr). More... | |
| static bool | tile_resource_is_valid (const struct tile *ptile) |
| void | tile_set_resource (struct tile *ptile, struct extra_type *presource) |
| Set the given resource at the specified tile. More... | |
| void | tile_set_terrain (struct tile *ptile, struct terrain *pterrain) |
| Set the given terrain at the specified tile. More... | |
| void | tile_set_worked (struct tile *ptile, struct city *pcity) |
| Set the city/worker on the tile (may be nullptr). More... | |
| const bv_extras * | tile_extras_null () |
| Returns a bit vector of the extras present at nullptr tile. More... | |
| static const bv_extras * | tile_extras (const struct tile *ptile) |
| bool | tile_has_base_flag (const struct tile *ptile, enum base_flag_id flag) |
| Check if tile contains base providing effect. More... | |
| bool | tile_has_base_flag_for_unit (const struct tile *ptile, const struct unit_type *punittype, enum base_flag_id flag) |
| Check if tile contains base providing effect for unit. More... | |
| bool | tile_has_refuel_extra (const struct tile *ptile, const struct unit_type *punittype) |
| Check if tile contains refuel extra native for unit. More... | |
| bool | tile_has_native_base (const struct tile *ptile, const struct unit_type *punittype) |
| Check if tile contains base native for unit. More... | |
| bool | tile_has_claimable_base (const struct tile *ptile, const struct unit_type *punittype) |
| Check if tile contains base providing effect for unit. More... | |
| int | tile_extras_defense_bonus (const struct tile *ptile, const struct unit_type *punittype) |
| Calculate defense bonus given for unit type by bases and roads. More... | |
| int | tile_extras_class_defense_bonus (const struct tile *ptile, const struct unit_class *pclass) |
| Calculate defense bonus given for unit class by extras. More... | |
| bool | tile_has_road (const struct tile *ptile, const struct road_type *proad) |
| Returns TRUE if the given tile has a road of given type on it. More... | |
| bool | tile_has_road_flag (const struct tile *ptile, enum road_flag_id flag) |
| Check if tile contains road providing effect. More... | |
| int | tile_roads_output_incr (const struct tile *ptile, enum output_type_id o) |
| Calculate output increment given by roads. More... | |
| int | tile_roads_output_bonus (const struct tile *ptile, enum output_type_id o) |
| Calculate output bonus given by roads. More... | |
| bool | tile_has_river (const struct tile *tile) |
| Tile has any river type. More... | |
| bool | tile_extra_apply (struct tile *ptile, const extra_type *tgt) |
| Add extra and adjust other extras accordingly. More... | |
| bool | tile_extra_rm_apply (struct tile *ptile, struct extra_type *tgt) |
| Remove extra and adjust other extras accordingly. More... | |
| bool | tile_has_conflicting_extra (const struct tile *ptile, const struct extra_type *pextra) |
| Returns TRUE if the given tile has a extra conflicting with the given one. More... | |
| bool | tile_has_visible_extra (const struct tile *ptile, const struct extra_type *pextra) |
| Returns TRUE if the given tile has a road of given type on it. More... | |
| void | tile_add_extra (struct tile *ptile, const struct extra_type *pextra) |
| Adds extra to tile. More... | |
| void | tile_remove_extra (struct tile *ptile, const struct extra_type *pextra) |
| Removes extra from tile if such exist. More... | |
| bool | tile_has_extra_flag (const struct tile *ptile, enum extra_flag_id flag) |
| Check if tile contains extra providing effect. More... | |
| enum known_type | tile_get_known (const struct tile *ptile, const struct player *pplayer) |
| Return a known_type enumeration value for the tile. More... | |
| bool | tile_is_seen (const struct tile *target_tile, const struct player *pow_player) |
| Returns TRUE iff the target_tile is seen by pow_player. More... | |
| int | tile_activity_time (enum unit_activity activity, const struct tile *ptile, const struct extra_type *tgt) |
| Time to complete the given activity on the given tile. More... | |
| void | tile_change_terrain (struct tile *ptile, struct terrain *pterrain) |
| Change the terrain to the given type. More... | |
| bool | tile_apply_activity (struct tile *ptile, Activity_type_id act, struct extra_type *tgt) |
| Apply an activity (Activity_type_id, e.g., ACTIVITY_TRANSFORM) to a tile. More... | |
| const char * | tile_get_info_text (const struct tile *ptile, bool include_nuisances, int linebreaks) |
| Return a (static) string with tile name describing terrain and extras of some categories. More... | |
| struct tile * | tile_virtual_new (const struct tile *ptile) |
| Returns a virtual tile. More... | |
| void | tile_virtual_destroy (struct tile *vtile) |
| Frees all memory used by the virtual tile, including freeing virtual units in the tile's unit list and the virtual city on this tile if one exists. More... | |
| bool | tile_virtual_check (const tile *vtile) |
| Check if the given tile is a virtual one or not. More... | |
| bool | tile_set_label (struct tile *ptile, const char *label) |
| Sets label for tile. More... | |
| bool | tile_is_placing (const struct tile *ptile) |
| Is there a placing ongoing? More... | |
| #define tile_has_extra | ( | ptile, | |
| pextra | |||
| ) | BV_ISSET(ptile->extras, extra_index(pextra)) |
| #define tile_list_iterate | ( | tile_list, | |
| ptile | |||
| ) | TYPED_LIST_ITERATE(struct tile, tile_list, ptile) |
| #define tile_list_iterate_end LIST_ITERATE_END |
| #define TILE_XY | ( | ptile | ) |
| enum known_type |
| int tile_activity_time | ( | enum unit_activity | activity, |
| const struct tile * | ptile, | ||
| const struct extra_type * | tgt | ||
| ) |
Time to complete the given activity on the given tile.
See also action_get_act_time()
Definition at line 427 of file tile.cpp.
Referenced by action_get_act_time(), calc_activity(), get_turns_for_activity_at(), total_activity_done(), and unit_activity_complete().
| void tile_add_extra | ( | struct tile * | ptile, |
| const struct extra_type * | pextra | ||
| ) |
Adds extra to tile.
Definition at line 974 of file tile.cpp.
Referenced by adv_calc_extra(), check_recursive_road_connect(), create_extra(), do_nuke_tile(), edit_buffer_copy(), fair_map_make_huts(), fill_island_rivers(), get_tile_value(), make_huts(), make_rivers(), ocean_to_land_fix_rivers(), place_pollution(), tile_create_extra(), tile_set_resource(), and upgrade_city_extras().
| bool tile_apply_activity | ( | struct tile * | ptile, |
| Activity_type_id | act, | ||
| struct extra_type * | tgt | ||
| ) |
Apply an activity (Activity_type_id, e.g., ACTIVITY_TRANSFORM) to a tile.
Return false if there was a error or if the activity is not implemented by this function.
Definition at line 701 of file tile.cpp.
Referenced by get_tile_change_menu_text(), get_tile_value(), and unit_activity_complete().
Change the terrain to the given type.
This does secondary tile updates to the tile (as will happen when mining/irrigation/transforming changes the tile's terrain).
Definition at line 491 of file tile.cpp.
Referenced by adv_calc_irrigate_transform(), adv_calc_mine_transform(), adv_calc_transform(), api_edit_change_terrain(), check_terrain_change(), climate_change(), edit_tile_terrain_handling(), regenerate_lakes(), tile_cultivate(), tile_irrigate(), tile_mine(), tile_plant(), and tile_transform().
Return the city on this tile (or nullptr), checking for city center.
Definition at line 72 of file tile.cpp.
Referenced by action_maybe_possible_actor_unit(), action_not_enabled_reason(), action_success_target_pay_mp(), action_tgt_city(), trade_generator::add_tile(), adv_calc_irrigate_transform(), adv_calc_mine_transform(), adv_calc_transform(), adv_danger_at(), any_unit_in_city(), api_edit_change_terrain(), api_edit_create_unit_full(), api_edit_unit_move(), api_edit_unit_teleport(), api_methods_enemy_tile(), api_methods_tile_city(), freeciv::path_finder::path_finder_private::attempt_action_move(), freeciv::path_finder::path_finder_private::attempt_paradrop(), auto_settlers_speculate_can_act_at(), blocked_find_target_city(), build_landarea_map(), calculate_city_clusters(), calculate_want_for_paratrooper(), can_build_extra_base(), can_exist_at_tile(), can_extra_be_removed(), can_player_attack_tile(), can_player_see_hypotetic_units_at(), can_player_see_unit_at(), can_step_taken_wrt_to_zoc(), can_unit_change_homecity(), can_unit_survive_at_tile(), can_unit_unload(), caravan_search_from(), check_city_migrations_player(), city_build(), city_desirability(), city_exists_within_max_city_map(), city_landlocked_sell_coastal_improvements(), citymindist_prevents_city_on_tile(), cityresult_fill(), client_plr_tile_city_id_get(), client_remove_unit(), climate_change(), clipboard_copy_production(), control_mouse_cursor(), could_unit_load(), dai_airlift(), dai_auto_settler_run(), dai_consider_tile_dangerous(), dai_data_phase_begin(), dai_diplomat_bribe_nearby(), dai_diplomat_defend(), dai_do_build_city(), dai_effect_value(), dai_find_boat_for_unit(), dai_find_strategic_airbase(), dai_gothere_bodyguard(), dai_hunter_manage(), dai_hunter_try_launch(), dai_manage_airunit(), dai_manage_caravan(), dai_manage_diplomat(), dai_manage_hitpoint_recovery(), dai_manage_military(), dai_manage_paratrooper(), dai_military_defend(), dai_rampage_want(), dai_should_we_air_attack_tile(), dai_unit_attack(), dai_unit_new_task(), dai_wonder_city_distance(), debug_command(), defense_multiplication(), diplomat_bribe(), diplomat_infiltrate_tile(), diplomat_success_vs_defender(), disband_all_units(), do_airline(), do_attack(), do_capture_units(), do_disband_alternative(), do_map_click(), do_move_unit(), do_nuke_tile(), draw_calculated_trade_routes(), edit_buffer_copy(), edit_tile_terrain_handling(), editor_apply_tool(), editor_grab_applied_player(), editor_grab_tool(), execute_orders(), explorer_tb(), freeciv::layer_background::fill_sprite_array(), freeciv::layer_city::fill_sprite_array(), freeciv::layer_city_size::fill_sprite_array(), freeciv::layer_darkness::fill_sprite_array(), freeciv::layer_terrain::fill_sprite_array(), freeciv::layer_units::fill_sprite_array(), freeciv::layer_water::fill_sprite_array(), find_a_good_partisan_spot(), find_beachhead(), find_best_city_placement(), find_best_tile_to_paradrop_to(), find_city_or_settler_near_tile(), find_city_to_diplomat(), find_nearest_safe_city(), find_something_to_kill(), find_visible_unit(), get_airlift_text(), get_modified_firepower(), get_nearest_city(), get_unit_bonus(), get_unittype_bonus(), give_distorted_map(), handle_edit_city_create(), handle_edit_player_vision(), handle_edit_unit_create(), handle_unit_bombard_info(), handle_unit_packet_common(), handle_unit_type_upgrade(), notify_goto::inspect_city(), invasion_funct(), is_achievement_in_range(), is_action_enabled_unit_on_city_full(), is_action_enabled_unit_on_self_full(), is_action_enabled_unit_on_tile_full(), is_action_enabled_unit_on_unit_full(), is_action_enabled_unit_on_units_full(), is_allied_city_tile(), is_border_source(), is_city_channel_tile(), is_enemy_city_tile(), is_friendly_city_near(), is_native_tile_to_extra(), is_non_allied_city_tile(), is_non_attack_city_tile(), is_req_knowable(), is_stack_vulnerable(), is_unit_being_refueled(), is_unit_reachable_at(), kill_something_with(), kill_unit(), look_for_charge(), chat_widget::make_link(), map_change_seen(), map_claim_border(), map_show_tile(), mapimg_client_tile_city(), mapimg_server_tile_city(), maybe_make_contact(), meswin_add(), meswin_popup_city(), need_war_player_hlp(), notify_goto::notify_goto(), occupy_move(), overview_tile_color(), paste_tile(), pf_danger_map_iterate(), pf_danger_node_init(), pf_fuel_map_iterate(), pf_fuel_node_init(), pf_normal_map_new(), pf_normal_node_init(), place_animal(), player_in_city_map(), popup_info_text(), process_attacker_want(), reality_check_city(), refresh_unit_city_dialogs(), remove_city(), request_unit_build_city(), request_unit_caravan_action(), request_unit_change_homecity(), request_unit_upgrade(), sdi_try_defend(), send_city_info_at_tile(), server_remove_unit_full(), sg_load_player_city(), sg_load_player_vision(), sg_order_to_action(), sg_special_set(), map_view::shortcut_pressed(), show_city_descriptions(), terrain_changed(), throw_units_from_illegal_cities(), tile_border_source_radius_sq(), tile_border_source_strength(), tile_set_owner(), tile_set_terrain(), tile_virtual_destroy(), transfer_city_units(), transfer_unit(), unit_being_aggressive(), unit_bombard(), unit_can_add_or_build_city(), unit_can_est_trade_route_here(), unit_can_help_build_wonder_here(), unit_change_homecity_handling(), unit_do_disband_trad(), unit_foodbox_cost(), unit_move(), unit_move_consequences(), unit_pays_mp_for_action(), unit_restore_hitpoints(), unit_select_dialog_popup(), unit_survive_autoattack(), unit_actions::update_actions(), utype_pays_mp_for_action_estimate(), and wakeup_neighbor_sentries().
| bool tile_extra_apply | ( | struct tile * | ptile, |
| const extra_type * | tgt | ||
| ) |
Add extra and adjust other extras accordingly.
If not all necessary adjustments can be done, returns FALSE. When problem occurs, changes to tile extras are not reverted. Pass virtual tile to the function if you are not sure it will success and don't want extras adjusted at all in case of failure.
Definition at line 578 of file tile.cpp.
Referenced by edit_tile_extra_handling(), end_turn(), tile_irrigate(), and tile_mine().
| bool tile_extra_rm_apply | ( | struct tile * | ptile, |
| struct extra_type * | tgt | ||
| ) |
Remove extra and adjust other extras accordingly.
If not all necessary adjustments can be done, returns FALSE. When problem occurs, changes to tile extras are not reverted. Pass virtual tile to the function if you are not sure it will success and don't want extras adjusted at all in case of failure.
Definition at line 605 of file tile.cpp.
Referenced by api_edit_remove_extra(), edit_tile_extra_handling(), end_turn(), place_starting_unit(), remove_city(), remove_tiny_islands(), and try_summon_barbarians().
|
inlinestatic |
Definition at line 102 of file tile.h.
Referenced by build_tile_data(), freeciv::layer_roads::fill_corners(), freeciv::layer_water::fill_sprite_array(), fill_tile_edit_packet(), is_city_channel_tile(), is_native_tile(), is_native_tile_to_class(), and unit_assign_specific_activity_target().
| int tile_extras_class_defense_bonus | ( | const struct tile * | ptile, |
| const struct unit_class * | pclass | ||
| ) |
Calculate defense bonus given for unit class by extras.
Definition at line 232 of file tile.cpp.
Referenced by chance_killed_at(), and tile_extras_defense_bonus().
Calculate defense bonus given for unit type by bases and roads.
Definition at line 223 of file tile.cpp.
Referenced by adv_danger_at(), dai_consider_tile_dangerous(), defense_multiplication(), and kill_unit().
| const bv_extras* tile_extras_null | ( | ) |
| const char* tile_get_info_text | ( | const struct tile * | ptile, |
| bool | include_nuisances, | ||
| int | linebreaks | ||
| ) |
Return a (static) string with tile name describing terrain and extras of some categories.
If include_nuisances is set, pollution and nuclear fallout will be ignored.
Examples: "Hills" "Hills (Coals)" "Hills (Coals) [Pollution]"
Definition at line 799 of file tile.cpp.
Referenced by dai_auto_settler_run(), get_tile_change_menu_text(), popup_info_text(), and popup_terrain_info().
| enum known_type tile_get_known | ( | const struct tile * | ptile, |
| const struct player * | pplayer | ||
| ) |
Return a known_type enumeration value for the tile.
Note that the client only has known data about its own player.
Definition at line 388 of file tile.cpp.
Referenced by freeciv::path_finder::path_finder_private::attempt_move(), freeciv::path_finder::path_finder_private::attempt_paradrop(), base_city_can_work_tile(), can_player_see_unit_at(), client_tile_get_known(), editor_apply_tool(), editor_grab_applied_player(), editor_grab_tool(), get_closest_safe_tile_distance(), freeciv::tile_known_constraint::is_allowed(), is_my_zoc(), is_possible_base_fuel(), mapimg_server_tile_known(), mapimg_server_tile_owner(), mapimg_server_tile_unit(), pf_danger_node_init(), pf_fuel_node_init(), pf_normal_node_init(), plr_knows_tile(), plr_sees_tile(), and tile_is_seen().
| bool tile_has_base_flag | ( | const struct tile * | ptile, |
| enum base_flag_id | flag | ||
| ) |
| bool tile_has_base_flag_for_unit | ( | const struct tile * | ptile, |
| const struct unit_type * | punittype, | ||
| enum base_flag_id | flag | ||
| ) |
Check if tile contains base providing effect for unit.
Definition at line 182 of file tile.cpp.
Referenced by unit_being_aggressive(), and unit_move_consequences().
Check if tile contains base providing effect for unit.
Definition at line 203 of file tile.cpp.
Referenced by maybe_claim_base(), sg_load_player_units(), and unit_move().
| bool tile_has_conflicting_extra | ( | const struct tile * | ptile, |
| const struct extra_type * | pextra | ||
| ) |
Returns TRUE if the given tile has a extra conflicting with the given one.
Definition at line 930 of file tile.cpp.
Referenced by upgrade_city_extras().
| bool tile_has_extra_flag | ( | const struct tile * | ptile, |
| enum extra_flag_id | flag | ||
| ) |
Check if tile contains extra providing effect.
Definition at line 914 of file tile.cpp.
Referenced by is_stack_vulnerable().
Check if tile contains base native for unit.
Definition at line 327 of file tile.cpp.
Referenced by can_unit_unload(), could_unit_load(), is_possible_base_fuel(), is_unit_reachable_at(), pf_attack_possible(), pf_danger_map_iterate(), pf_fuel_map_iterate(), pf_normal_map_new(), and unit_restore_hitpoints().
Check if tile contains refuel extra native for unit.
Definition at line 309 of file tile.cpp.
Referenced by can_unit_survive_at_tile(), and is_unit_being_refueled().
| bool tile_has_river | ( | const struct tile * | tile | ) |
Tile has any river type.
Definition at line 876 of file tile.cpp.
Referenced by count_river_near_tile(), fill_island_rivers(), is_terrain_ecologically_wet(), and make_rivers().
Returns TRUE if the given tile has a road of given type on it.
Definition at line 868 of file tile.cpp.
Referenced by adv_settlers_road_bonus(), can_unit_do_connect(), popup_terrain_info(), and road_can_be_built().
| bool tile_has_road_flag | ( | const struct tile * | ptile, |
| enum road_flag_id | flag | ||
| ) |
| bool tile_has_visible_extra | ( | const struct tile * | ptile, |
| const struct extra_type * | pextra | ||
| ) |
Returns TRUE if the given tile has a road of given type on it.
Definition at line 948 of file tile.cpp.
Referenced by popup_info_text(), tile_get_info_text(), and tile_info_pollution().
| bool tile_is_placing | ( | const struct tile * | ptile | ) |
Is there a placing ongoing?
Definition at line 1138 of file tile.cpp.
Referenced by can_unit_do_activity_targeted_at().
Returns TRUE iff the target_tile is seen by pow_player.
Definition at line 416 of file tile.cpp.
Referenced by handle_unit_get_actions(), is_req_knowable(), is_tile_seen_adj(), is_tile_seen_cadj(), is_tile_seen_city(), and player_can_see_city_externals().
| void tile_remove_extra | ( | struct tile * | ptile, |
| const struct extra_type * | pextra | ||
| ) |
Removes extra from tile if such exist.
Definition at line 984 of file tile.cpp.
Referenced by adv_calc_extra(), adv_calc_rmextra(), can_extra_be_removed(), destroy_extra(), get_tile_infrastructure_set(), tile_destroy_extra(), and tile_set_resource().
|
inlinestatic |
Definition at line 85 of file tile.h.
Referenced by city_tile_output(), and tile_get_info_text().
| int tile_roads_output_bonus | ( | const struct tile * | ptile, |
| enum output_type_id | o | ||
| ) |
Calculate output bonus given by roads.
Definition at line 289 of file tile.cpp.
Referenced by city_tile_output().
| int tile_roads_output_incr | ( | const struct tile * | ptile, |
| enum output_type_id | o | ||
| ) |
Calculate output increment given by roads.
Definition at line 266 of file tile.cpp.
Referenced by city_tile_output().
| void tile_set_continent | ( | struct tile * | ptile, |
| Continent_id | val | ||
| ) |
Set the continent ID of the tile.
See tile_continent.
Definition at line 388 of file tile.cpp.
Referenced by assign_continent_flood(), assign_continent_numbers(), initworld(), make_polar_land(), place_island(), and remove_tiny_islands().
| bool tile_set_label | ( | struct tile * | ptile, |
| const char * | label | ||
| ) |
Sets label for tile.
Returns whether label changed.
Definition at line 1104 of file tile.cpp.
Referenced by api_edit_tile_set_label(), handle_edit_tile(), handle_tile_info(), and sg_load_map_tiles().
Set the owner of a tile (may be nullptr).
Definition at line 58 of file tile.cpp.
Referenced by cityresult_fill(), create_city(), handle_tile_info(), initworld(), map_claim_border_ownership(), and remove_player_from_maps().
| void tile_set_resource | ( | struct tile * | ptile, |
| struct extra_type * | presource | ||
| ) |
Set the given resource at the specified tile.
Definition at line 355 of file tile.cpp.
Referenced by add_resources(), edit_buffer_copy(), fair_map_make_huts(), handle_tile_info(), sg_load_map_tiles_extras(), and sg_load_map_tiles_resources().
Set the given terrain at the specified tile.
Definition at line 114 of file tile.cpp.
Referenced by edit_buffer_copy(), fair_map_make_huts(), fill_island(), handle_tile_info(), initworld(), make_fracture_relief(), make_land(), make_plain(), make_polar(), make_polar_land(), make_relief(), make_rivers(), place_island(), place_terrain(), remove_tiny_islands(), smooth_water_depth(), and tile_change_terrain().
Set the city/worker on the tile (may be nullptr).
Definition at line 96 of file tile.cpp.
Referenced by city_map_update_empty(), city_map_update_tile_direct(), city_map_update_worker(), city_packet_common(), create_city(), edit_buffer_copy(), game_remove_city(), handle_tile_info(), remove_city(), result_defense_bonus(), sg_load_player_city(), texai_city_destruction_recv(), texai_city_info_recv(), and tile_virtual_destroy().
| bool tile_virtual_check | ( | const tile * | vtile | ) |
Check if the given tile is a virtual one or not.
Definition at line 1085 of file tile.cpp.
Referenced by destroy_extra(), find_city_or_settler_near_tile(), mapstep(), and tile_set_terrain().
| void tile_virtual_destroy | ( | struct tile * | vtile | ) |
Frees all memory used by the virtual tile, including freeing virtual units in the tile's unit list and the virtual city on this tile if one exists.
NB: Do not call this on real tiles!
Definition at line 1051 of file tile.cpp.
Referenced by adv_calc_extra(), adv_calc_irrigate_transform(), adv_calc_mine_transform(), adv_calc_rmextra(), adv_calc_transform(), can_extra_be_removed(), can_unit_do_connect(), check_native_area(), edit_buffer_clear(), edit_buffer_copy(), edit_buffer_free(), fair_map_make_huts(), fill_basic_extra_sprite_array(), fill_basic_terrain_layer_sprite_array(), get_tile_change_menu_text(), get_tile_infrastructure_set(), get_tile_value(), goto_dialog::init(), result_defense_bonus(), sg_special_set(), and goto_dialog::~goto_dialog().
Returns a virtual tile.
If ptile is given, the properties of this tile are copied, else it is completely blank (except for the unit list vtile->units, which is created for you). Be sure to call tile_virtual_free on it when it is no longer needed.
Definition at line 997 of file tile.cpp.
Referenced by adv_calc_extra(), adv_calc_irrigate_transform(), adv_calc_mine_transform(), adv_calc_rmextra(), adv_calc_transform(), can_extra_be_removed(), can_unit_do_connect(), check_native_area(), edit_buffer_copy(), fair_map_make_huts(), fill_basic_extra_sprite_array(), fill_basic_terrain_layer_sprite_array(), get_tile_change_menu_text(), get_tile_infrastructure_set(), get_tile_value(), goto_dialog::init(), result_defense_bonus(), and sg_special_set().