pub struct Character {
pub stats: Stats,
pub species: Species,
pub life_modifier: Option<LifeModifier>,
pub inventory: Inventory,
pub current_effects: Effects,
pub spell_memory: SpellMemory,
}
Fields§
§stats: Stats
§species: Species
§life_modifier: Option<LifeModifier>
§inventory: Inventory
§current_effects: Effects
§spell_memory: SpellMemory
Implementations§
Source§impl Character
impl Character
pub fn is_dead(&self) -> bool
pub fn find_item(&self, item_id: &Uuid) -> Option<CharacterItem>
pub fn find_spell(&self, spell_id: &Uuid) -> Option<&LearnedSpell>
pub fn find_spell_mut(&mut self, spell_id: &Uuid) -> Option<&mut LearnedSpell>
pub fn remove_item(&mut self, item_id: &Uuid) -> Option<CharacterItem>
pub fn forget_spell(&mut self, spell_id: &Uuid)
pub fn add_item(&mut self, character_item: CharacterItem)
pub fn get_current_health(&self) -> i32
pub fn damage(&mut self, damage: i32)
pub fn heal(&mut self, damage_healed: i32)
pub fn heal_to_max(&mut self)
pub fn increase_max_health(&mut self, change: i32)
pub fn kill(&mut self)
pub fn has_weapons_readied(&self) -> bool
pub fn count_weapons_at_ready(&self) -> usize
pub fn count_wearables_at_ready(&self) -> usize
pub fn strongest_non_readied_weapon(&self) -> Option<&CharacterItem>
pub fn full_attack(&self) -> Attack
pub fn full_defense(&self) -> Defense
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Character
impl RefUnwindSafe for Character
impl Send for Character
impl Sync for Character
impl Unpin for Character
impl UnwindSafe for Character
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