pub struct ScoreAward {
pub base: u32,
pub tier: u32,
pub multiplier: u32,
pub chain: u32,
pub nominal_points: u64,
pub total_change: u64,
pub total_before: u64,
pub total_after: u64,
pub chain_saturated: bool,
pub total_saturated: bool,
}Expand description
An accepted award, or a forecast returned by ScoreChain::preview_award.
A forecast is not feedback evidence; see the module example for acceptance.
Fields§
§base: u32Caller-supplied nonzero base points.
tier: u32One-based tier after this action, before applying the multiplier cap.
multiplier: u32Capped multiplier used for this award.
chain: u32Chain length after this action, saturating at u32::MAX.
nominal_points: u64base * multiplier, exactly representable in u64 (maximum multiplier 100).
total_change: u64Actual increase in the helper’s total; can be smaller than nominal points.
total_before: u64Total before this award.
total_after: u64Total after this award, saturating at u64::MAX.
chain_saturated: boolIncrementing the chain exceeded u32::MAX; merely reaching it is false.
total_saturated: boolAdding nominal points exceeded u64::MAX; merely reaching it is false.
Trait Implementations§
Source§impl Clone for ScoreAward
impl Clone for ScoreAward
Source§fn clone(&self) -> ScoreAward
fn clone(&self) -> ScoreAward
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ScoreAward
impl Debug for ScoreAward
Source§impl PartialEq for ScoreAward
impl PartialEq for ScoreAward
impl Copy for ScoreAward
impl Eq for ScoreAward
impl StructuralPartialEq for ScoreAward
Auto Trait Implementations§
impl Freeze for ScoreAward
impl RefUnwindSafe for ScoreAward
impl Send for ScoreAward
impl Sync for ScoreAward
impl Unpin for ScoreAward
impl UnwindSafe for ScoreAward
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