pub struct BasicUnitInfo {Show 24 fields
pub unit_id: i32,
pub pos_x: i32,
pub pos_y: i32,
pub pos_z: i32,
pub name: Option<NameInfo>,
pub flags1: u32,
pub flags2: u32,
pub flags3: u32,
pub race: i32,
pub caste: i32,
pub gender: Option<i32>,
pub civ_id: Option<i32>,
pub histfig_id: Option<i32>,
pub death_id: Option<i32>,
pub death_flags: Option<u32>,
pub squad_id: Option<i32>,
pub squad_position: Option<i32>,
pub profession: Option<i32>,
pub custom_profession: Option<String>,
pub labors: Vec<i32>,
pub skills: Vec<SkillInfo>,
pub misc_traits: Vec<UnitMiscTrait>,
pub curse: Option<UnitCurseInfo>,
pub burrows: Vec<i32>,
}Fields§
§unit_id: i32§pos_x: i32§pos_y: i32§pos_z: i32§name: Option<NameInfo>§flags1: u32§flags2: u32§flags3: u32§race: i32§caste: i32§gender: Option<i32>§civ_id: Option<i32>§histfig_id: Option<i32>§death_id: Option<i32>§death_flags: Option<u32>§squad_id: Option<i32>IF mask.profession:
squad_position: Option<i32>§profession: Option<i32>§custom_profession: Option<String>§labors: Vec<i32>IF mask.labors:
skills: Vec<SkillInfo>IF mask.skills:
misc_traits: Vec<UnitMiscTrait>IF mask.misc_traits:
curse: Option<UnitCurseInfo>§burrows: Vec<i32>Implementations§
Source§impl BasicUnitInfo
impl BasicUnitInfo
Sourcepub fn gender(&self) -> i32
pub fn gender(&self) -> i32
Returns the value of gender, or the default value if gender is unset.
Sourcepub fn civ_id(&self) -> i32
pub fn civ_id(&self) -> i32
Returns the value of civ_id, or the default value if civ_id is unset.
Sourcepub fn histfig_id(&self) -> i32
pub fn histfig_id(&self) -> i32
Returns the value of histfig_id, or the default value if histfig_id is unset.
Sourcepub fn death_id(&self) -> i32
pub fn death_id(&self) -> i32
Returns the value of death_id, or the default value if death_id is unset.
Sourcepub fn death_flags(&self) -> u32
pub fn death_flags(&self) -> u32
Returns the value of death_flags, or the default value if death_flags is unset.
Sourcepub fn squad_id(&self) -> i32
pub fn squad_id(&self) -> i32
Returns the value of squad_id, or the default value if squad_id is unset.
Sourcepub fn squad_position(&self) -> i32
pub fn squad_position(&self) -> i32
Returns the value of squad_position, or the default value if squad_position is unset.
Sourcepub fn profession(&self) -> i32
pub fn profession(&self) -> i32
Returns the value of profession, or the default value if profession is unset.
Sourcepub fn custom_profession(&self) -> &str
pub fn custom_profession(&self) -> &str
Returns the value of custom_profession, or the default value if custom_profession is unset.
Trait Implementations§
Source§impl Clone for BasicUnitInfo
impl Clone for BasicUnitInfo
Source§fn clone(&self) -> BasicUnitInfo
fn clone(&self) -> BasicUnitInfo
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for BasicUnitInfo
impl Debug for BasicUnitInfo
Source§impl Default for BasicUnitInfo
impl Default for BasicUnitInfo
Source§impl Message for BasicUnitInfo
impl Message for BasicUnitInfo
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
self.Source§impl Name for BasicUnitInfo
impl Name for BasicUnitInfo
Source§const NAME: &'static str = "BasicUnitInfo"
const NAME: &'static str = "BasicUnitInfo"
Message.
This name is the same as it appears in the source .proto file, e.g. FooBar.Source§const PACKAGE: &'static str = "dfproto"
const PACKAGE: &'static str = "dfproto"
., e.g. google.protobuf.Source§fn full_name() -> String
fn full_name() -> String
Message.
It’s prefixed with the package name and names of any parent messages,
e.g. google.rpc.BadRequest.FieldViolation.
By default, this is the package name followed by the message name.
Fully-qualified names must be unique within a domain of Type URLs.