pub struct CombatUnitType {Show 16 fields
pub costs: ArrayVec<[AttributeCost; 3]>,
pub create_time: u16,
pub create_at_building: Option<UnitTypeID>,
pub create_button: i8,
pub rear_attack_modifier: f32,
pub flank_attack_modifier: f32,
pub hero_flag: u8,
pub garrison_sprite: Option<SpriteID>,
pub volley_fire_amount: f32,
pub max_attacks_in_volley: i8,
pub volley_spread: (f32, f32),
pub volley_start_spread_adjustment: f32,
pub volley_missile: Option<UnitTypeID>,
pub special_attack_sprite: Option<SpriteID>,
pub special_attack_flag: i8,
pub displayed_pierce_armor: i16,
/* private fields */
}
Fields§
§costs: ArrayVec<[AttributeCost; 3]>
The costs of creating a unit of this type.
create_time: u16
§create_at_building: Option<UnitTypeID>
Unit type ID of the building or unit where this unit can be created.
Button location index where the button to create this unit should be shown when a
create_at_building
unit is selected.
rear_attack_modifier: f32
§flank_attack_modifier: f32
§hero_flag: u8
Is this unit a hero unit?
TODO what is special about hero units? Does it just opt into the healing behaviour?
garrison_sprite: Option<SpriteID>
§volley_fire_amount: f32
§max_attacks_in_volley: i8
§volley_spread: (f32, f32)
§volley_start_spread_adjustment: f32
§volley_missile: Option<UnitTypeID>
§special_attack_sprite: Option<SpriteID>
§special_attack_flag: i8
§displayed_pierce_armor: i16
Implementations§
Methods from Deref<Target = BaseCombatUnitType>§
Methods from Deref<Target = ActionUnitType>§
Methods from Deref<Target = MovingUnitType>§
Methods from Deref<Target = AnimatedUnitType>§
Methods from Deref<Target = BaseUnitType>§
Trait Implementations§
Source§impl Clone for CombatUnitType
impl Clone for CombatUnitType
Source§fn clone(&self) -> CombatUnitType
fn clone(&self) -> CombatUnitType
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for CombatUnitType
impl Debug for CombatUnitType
Source§impl Default for CombatUnitType
impl Default for CombatUnitType
Source§fn default() -> CombatUnitType
fn default() -> CombatUnitType
Returns the “default value” for a type. Read more
Source§impl Deref for CombatUnitType
impl Deref for CombatUnitType
Source§impl From<CombatUnitType> for UnitType
impl From<CombatUnitType> for UnitType
Source§fn from(v: CombatUnitType) -> Self
fn from(v: CombatUnitType) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for CombatUnitType
impl RefUnwindSafe for CombatUnitType
impl Send for CombatUnitType
impl Sync for CombatUnitType
impl Unpin for CombatUnitType
impl UnwindSafe for CombatUnitType
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more