[][src]Struct evolution::fish::FishConfig

pub struct FishConfig {
    pub quantity: usize,
    pub eating_radius: f32,
    pub mutation_rate: f32,
    pub scale_range: (f32, f32),
    pub max_speed_range: (f32, f32),
    pub max_steering_force_range: (f32, f32),
    pub total_food_chain_links: usize,
    pub frames_per_animation_frame: f32,
}

The configuration structure specifically for fish that is read and deserialized from config.ron

Fields

quantity: usize

The number of fish in the simulation

eating_radius: f32

The constant radius around the fish where prey can be consumed

mutation_rate: f32

The frequency at which the fish's dna will mutate

scale_range: (f32, f32)

The range of scales of the fish. E.g. A scale of 2 would result in a fish twice as large as the original image.

max_speed_range: (f32, f32)

The range of maximum speeds for the fish

max_steering_force_range: (f32, f32)

The range of maximum turning forces for the fish

total_food_chain_links: usize

The number of links in the food chain, excluding food

frames_per_animation_frame: f32

The number of frames in the simulation that will go by before going to the next animation frame at the fish's maximum speed.

Trait Implementations

impl Debug for FishConfig[src]

impl<'de> Deserialize<'de> for FishConfig[src]

fn deserialize_in_place<D>(
    deserializer: D,
    place: &mut Self
) -> Result<(), <D as Deserializer<'de>>::Error> where
    D: Deserializer<'de>, 
[src]

Deserializes a value into self from the given Deserializer. Read more

Auto Trait Implementations

impl Send for FishConfig

impl Sync for FishConfig

Blanket Implementations

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<SS, SP> SupersetOf<SS> for SP where
    SS: SubsetOf<SP>, 

impl<T> DeserializeOwned for T where
    T: Deserialize<'de>, 
[src]

impl<T> SetParameter for T

fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
    T: Parameter<Self>, 

Sets value as a parameter of self.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,