pub enum CharacterAction {
CastSpell {
spell: String,
at_level: Option<u8>,
pact: bool,
ritual: bool,
},
ExpendSpellSlot {
level: u8,
},
RestoreSpellSlot {
level: u8,
},
ExpendPactSlot,
RestorePactSlot,
UseResource {
name: String,
amount: u16,
},
RestoreResource {
name: String,
amount: u16,
},
Rest {
kind: RestKind,
},
}Expand description
A change made in play, applied atomically by the character service:
POST /characters/{id}/actions.
Variants§
CastSpell
Cast a known spell, expending the appropriate slot. Cantrips and ritual casts don’t use a slot.
Fields
ExpendSpellSlot
RestoreSpellSlot
ExpendPactSlot
RestorePactSlot
UseResource
RestoreResource
Rest
Trait Implementations§
Source§impl Clone for CharacterAction
impl Clone for CharacterAction
Source§fn clone(&self) -> CharacterAction
fn clone(&self) -> CharacterAction
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl ComposeSchema for CharacterAction
impl ComposeSchema for CharacterAction
Source§impl Debug for CharacterAction
impl Debug for CharacterAction
Source§impl<'de> Deserialize<'de> for CharacterAction
impl<'de> Deserialize<'de> for CharacterAction
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for CharacterAction
impl PartialEq for CharacterAction
Source§fn eq(&self, other: &CharacterAction) -> bool
fn eq(&self, other: &CharacterAction) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for CharacterAction
impl Serialize for CharacterAction
Source§impl ToSchema for CharacterAction
impl ToSchema for CharacterAction
impl Eq for CharacterAction
impl StructuralPartialEq for CharacterAction
Auto Trait Implementations§
impl Freeze for CharacterAction
impl RefUnwindSafe for CharacterAction
impl Send for CharacterAction
impl Sync for CharacterAction
impl Unpin for CharacterAction
impl UnsafeUnpin for CharacterAction
impl UnwindSafe for CharacterAction
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.