pub enum Uncertain {
Step {
at: Anchor,
delta: Level,
},
Claim {
start: Anchor,
end: Anchor,
amount: Level,
},
Rate {
start: Anchor,
end: Anchor,
per_tick: Level,
},
}Expand description
One effect of an activity whose duration is uncertain.
The variants mirror Impact, with ticks given as Anchors. A claim from
Anchor::Start(0) to Anchor::End(0) holds a resource for exactly as long as the activity
runs; a rate over the same interval drains energy for as long as it runs. The interval may
be empty for the shortest duration (a zero-length run), but never inverted.
Variants§
Step
A permanent change of the level at at.
Claim
A hold of amount units during [start, end).
Fields
Rate
A change of per_tick for every tick elapsed in [start, end).
Implementations§
Trait Implementations§
impl Copy for Uncertain
Source§impl<'de> Deserialize<'de> for Uncertain
impl<'de> Deserialize<'de> for Uncertain
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
impl Eq for Uncertain
impl StructuralPartialEq for Uncertain
Auto Trait Implementations§
impl Forget for Uncertain
impl Freeze for Uncertain
impl Move for Uncertain
impl RefUnwindSafe for Uncertain
impl Send for Uncertain
impl Sync for Uncertain
impl Unpin for Uncertain
impl UnsafeUnpin for Uncertain
impl UnwindSafe for Uncertain
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