Freeciv-3.2
|
Go to the source code of this file.
Data Structures | |
struct | base_type |
Macros | |
#define | SPECENUM_NAME base_gui_type |
#define | SPECENUM_VALUE0 BASE_GUI_FORTRESS |
#define | SPECENUM_VALUE0NAME "Fortress" |
#define | SPECENUM_VALUE1 BASE_GUI_AIRBASE |
#define | SPECENUM_VALUE1NAME "Airbase" |
#define | SPECENUM_VALUE2 BASE_GUI_OTHER |
#define | SPECENUM_VALUE2NAME "Other" |
#define | BASE_NONE -1 |
Functions | |
Base_type_id | base_count (void) |
Base_type_id | base_number (const struct base_type *pbase) |
struct base_type * | base_by_number (const Base_type_id id) |
struct extra_type * | base_extra_get (const struct base_type *pbase) |
bool | can_build_base (const struct unit *punit, const struct base_type *pbase, const struct tile *ptile) |
bool | player_can_build_base (const struct base_type *pbase, const struct player *pplayer, const struct tile *ptile) |
struct base_type * | get_base_by_gui_type (enum base_gui_type type, const struct unit *punit, const struct tile *ptile) |
bool | territory_claiming_base (const struct base_type *pbase) |
void | base_type_init (struct extra_type *pextra, int idx) |
void | base_types_free (void) |
#define SPECENUM_VALUE0 BASE_GUI_FORTRESS |
#define SPECENUM_VALUE1 BASE_GUI_AIRBASE |
#define SPECENUM_VALUE2 BASE_GUI_OTHER |
struct base_type * base_by_number | ( | const Base_type_id | id | ) |
Returns base_type entry for an ID value.
Definition at line 76 of file base.c.
Referenced by handle_ruleset_base(), set_unit_activity_base(), and sg_load_player_unit().
Base_type_id base_count | ( | void | ) |
Return the number of base_types.
Definition at line 109 of file base.c.
Referenced by editor_tool_is_usable(), extviewer_view_cell_toggled(), and tab_misc::refresh_stats().
struct extra_type * base_extra_get | ( | const struct base_type * | pbase | ) |
Return extra that base is.
Definition at line 101 of file base.c.
Referenced by can_build_base(), handle_ruleset_base(), handle_unit_change_activity(), key_unit_airbase(), key_unit_fortress(), player_can_build_base(), real_menus_update(), set_unit_activity_base(), sg_bases_set_bv(), sg_bases_set_dbv(), sg_load_player_unit(), and tile_has_base().
Base_type_id base_number | ( | const struct base_type * | pbase | ) |
Return the base index.
Definition at line 92 of file base.c.
Referenced by extviewer_refresh_widgets(), load_ruleset_terrain(), objbind_get_value_from_object(), objbind_pack_modified_value(), propval_as_string(), send_ruleset_bases(), and sg_load_player_unit().
void base_type_init | ( | struct extra_type * | pextra, |
int | idx | ||
) |
Initialize base_type structures.
Definition at line 117 of file base.c.
Referenced by handle_ruleset_extra(), and load_terrain_names().
Free the memory associated with base types
Definition at line 132 of file base.c.
Referenced by extras_free().
bool can_build_base | ( | const struct unit * | punit, |
const struct base_type * | pbase, | ||
const struct tile * | ptile | ||
) |
Can unit build base to given tile?
Definition at line 53 of file base.c.
Referenced by actres_possible(), and get_base_by_gui_type().
struct base_type * get_base_by_gui_type | ( | enum base_gui_type | type, |
const struct unit * | punit, | ||
const struct tile * | ptile | ||
) |
Get best gui_type base for given parameters
Definition at line 139 of file base.c.
Referenced by can_units_do_base_gui(), handle_unit_change_activity(), key_unit_airbase(), key_unit_fortress(), real_menus_update(), and sg_load_player_unit().
Does this base type claim territory?
Definition at line 158 of file base.c.
Referenced by action_actor_utype_hard_reqs_ok_full(), destroy_extra(), handle_ruleset_base(), helptext_extra(), helptext_unit(), load_ruleset_terrain(), map_claim_base(), and tile_has_claimable_base().