pub struct Agent {
pub id: usize,
pub prof: u32,
pub elite: u32,
pub is_self: u32,
pub team: u16,
/* private fields */
}
Expand description
Represents an agent in a combat event.
Names are available for the duration of the fight.
Due to this, this struct is not usable for longer than the function call.
If you need it for longer than that, consider converting it to AgentOwned
.
let owned = agent.to_owned();
let owned: AgentOwned = agent.into();
Fields§
§id: usize
Unique id.
prof: u32
Profession of the agent.
elite: u32
Elite (specialization) of the agent.
is_self: u32
Whether the agent is self (the local player).
team: u16
Team the agent is in.
Implementations§
source§impl Agent
impl Agent
sourcepub fn to_owned(self) -> AgentOwned
pub fn to_owned(self) -> AgentOwned
Converts the Agent
to the owned version AgentOwned
.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Agent
impl RefUnwindSafe for Agent
impl !Send for Agent
impl !Sync for Agent
impl Unpin for Agent
impl UnwindSafe for Agent
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