Enum trane::data::PassingScoreOptions
source · pub enum PassingScoreOptions {
ConstantScore(f32),
IncreasingScore {
starting_score: f32,
step_size: f32,
max_steps: usize,
},
}Expand description
Options to compute the passing score for a unit.
Variants§
ConstantScore(f32)
The score will be a fixed value.
IncreasingScore
Fields
§
starting_score: f32The initial score. The units at the starting depth will use this value as their passing score.
The score will start at a fixed value and increase by a fixed amount based on the depth of the unit relative to the starting unit. This is useful for allowing users to make faster progress at the beginning, so to avoid boredom. Once enough of the graph has been mastered, the passing score will settle to a fixed value.
Implementations§
Trait Implementations§
source§impl Clone for PassingScoreOptions
impl Clone for PassingScoreOptions
source§fn clone(&self) -> PassingScoreOptions
fn clone(&self) -> PassingScoreOptions
Returns a copy 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 PassingScoreOptions
impl Debug for PassingScoreOptions
source§impl Default for PassingScoreOptions
impl Default for PassingScoreOptions
source§impl PartialEq<PassingScoreOptions> for PassingScoreOptions
impl PartialEq<PassingScoreOptions> for PassingScoreOptions
source§fn eq(&self, other: &PassingScoreOptions) -> bool
fn eq(&self, other: &PassingScoreOptions) -> bool
This method tests for
self and other values to be equal, and is used
by ==.impl StructuralPartialEq for PassingScoreOptions
Auto Trait Implementations§
impl RefUnwindSafe for PassingScoreOptions
impl Send for PassingScoreOptions
impl Sync for PassingScoreOptions
impl Unpin for PassingScoreOptions
impl UnwindSafe for PassingScoreOptions
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
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere T: Any,
§fn into_any(self: Box<T, Global>) -> Box<dyn Any, Global>
fn into_any(self: Box<T, Global>) -> Box<dyn Any, Global>
Convert
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.