Freeciv-3.1: unit_class Struct Reference

Freeciv-3.1

Loading...
Searching...
No Matches
Data Fields
unit_class Struct Reference

`#include <unittype.h>`

## Data Fields

Unit_Class_id | item_number
struct name_translation | name
bool | ruledit_disabled
enum unit_move_type | move_type
int | min_speed
int | hp_loss_pct
int | non_native_def_pct
bv_unit_class_flags | flags
struct strvec * | helptext
struct { |
enum move_level land_move |
enum move_level sea_move |
int ferry_types |
} | adv |
struct { |
struct extra_type_list * refuel_extras |
struct extra_type_list * native_tile_extras |
struct extra_type_list * native_bases |
struct extra_type_list * bonus_roads |
struct extra_type_list * hiding_extras |
struct unit_class_list * subset_movers |
} | cache |
struct { |
enum hut_behavior hut_behavior |
} | rscompat_cache_from_3_0 |

## Detailed Description

Definition at line 136 of file unittype.h.

## Field Documentation

## ◆ [struct]

struct { ... } unit_class::adv

Referenced by adv_data_phase_init(), count_my_units(), dai_choose_attacker_air(), dai_choose_trade_route(), dai_manage_caravan(), dai_units_ruleset_init(), find_something_to_kill(), role_unit_cb(), settler_map_iterate(), uclass_need_trans_between(), and update_simple_ai_types().

## ◆ bonus_roads

struct extra_type_list* unit_class::bonus_roads

Definition at line 158 of file unittype.h.

Referenced by set_unit_class_caches(), tile_move_cost_ptrs(), unit_classes_free(), and unit_classes_init().

## ◆ [struct]

struct { ... } unit_class::cache

Referenced by action_actor_utype_hard_reqs_ok_full(), can_player_see_unit_at(), dai_units_ruleset_init(), is_native_move(), is_native_to_class(), is_possible_base_fuel(), is_refuel_tile(), set_unit_class_caches(), tile_has_refuel_extra(), tile_move_cost_ptrs(), unit_classes_free(), and unit_classes_init().

## ◆ ferry_types

int unit_class::ferry_types

Definition at line 151 of file unittype.h.

Referenced by dai_choose_trade_route(), and dai_manage_caravan().

## ◆ flags

bv_unit_class_flags unit_class::flags

Definition at line 144 of file unittype.h.

Referenced by handle_ruleset_unit_class(), rscompat_uclass_flags_3_1(), and uclass_has_flag().

## ◆ helptext

struct strvec* unit_class::helptext

Definition at line 146 of file unittype.h.

Referenced by handle_ruleset_unit_class(), helptext_unit(), unit_classes_free(), and unit_classes_init().

## ◆ hiding_extras

struct extra_type_list* unit_class::hiding_extras

Definition at line 159 of file unittype.h.

Referenced by can_player_see_unit_at(), is_plr_zoc_srv(), set_unit_class_caches(), unit_classes_free(), and unit_classes_init().

## ◆ hp_loss_pct

int unit_class::hp_loss_pct

Definition at line 142 of file unittype.h.

Referenced by handle_ruleset_unit_class(), unit_color_type(), and unit_gain_hitpoints().

## ◆ hut_behavior

enum hut_behavior unit_class::hut_behavior

Definition at line 165 of file unittype.h.

## ◆ item_number

Unit_Class_id unit_class::item_number

Definition at line 137 of file unittype.h.

Referenced by uclass_number(), and unit_classes_init().

## ◆ land_move

enum move_level unit_class::land_move

Definition at line 149 of file unittype.h.

Referenced by dai_choose_attacker_air(), dai_units_ruleset_init(), role_unit_cb(), uclass_need_trans_between(), and update_simple_ai_types().

## ◆ min_speed

int unit_class::min_speed

Definition at line 141 of file unittype.h.

Referenced by handle_ruleset_unit_class(), and utype_move_rate().

## ◆ move_type

enum unit_move_type unit_class::move_type

Definition at line 140 of file unittype.h.

Referenced by set_unit_move_type(), and unit_color_type().

## ◆ name

struct name_translation unit_class::name

Definition at line 138 of file unittype.h.

Referenced by handle_ruleset_unit_class(), uclass_name_translation(), and uclass_rule_name().

## ◆ native_bases

struct extra_type_list* unit_class::native_bases

Definition at line 157 of file unittype.h.

Referenced by action_actor_utype_hard_reqs_ok_full(), set_unit_class_caches(), unit_classes_free(), and unit_classes_init().

## ◆ native_tile_extras

struct extra_type_list* unit_class::native_tile_extras

Definition at line 156 of file unittype.h.

Referenced by is_native_move(), is_native_to_class(), set_unit_class_caches(), unit_classes_free(), and unit_classes_init().

## ◆ non_native_def_pct

int unit_class::non_native_def_pct

Definition at line 143 of file unittype.h.

Referenced by get_defense_power(), get_virtual_defense_power(), handle_ruleset_unit_class(), and has_defense().

## ◆ refuel_extras

struct extra_type_list* unit_class::refuel_extras

Definition at line 155 of file unittype.h.

Referenced by is_possible_base_fuel(), is_refuel_tile(), set_unit_class_caches(), tile_has_refuel_extra(), unit_classes_free(), and unit_classes_init().

## ◆ [struct]

struct { ... } unit_class::rscompat_cache_from_3_0

## ◆ ruledit_disabled

bool unit_class::ruledit_disabled

Definition at line 139 of file unittype.h.

Referenced by unit_classes_init().

## ◆ sea_move

enum move_level unit_class::sea_move

Definition at line 150 of file unittype.h.

Referenced by adv_data_phase_init(), dai_choose_attacker_air(), dai_choose_trade_route(), dai_units_ruleset_init(), find_something_to_kill(), kill_something_with(), role_unit_cb(), settler_map_iterate(), and uclass_need_trans_between().

## ◆ subset_movers

struct unit_class_list* unit_class::subset_movers

Definition at line 160 of file unittype.h.

Referenced by dai_units_ruleset_init(), set_unit_class_caches(), unit_classes_free(), and unit_classes_init().