pub struct TechRecipe<T: Technology> { /* private fields */ }Expand description
A recipe for producing research points for specific technologies.
Trait Implementations§
Source§impl<T: Debug + Technology> Debug for TechRecipe<T>
impl<T: Debug + Technology> Debug for TechRecipe<T>
Source§impl<T> Recipe for TechRecipe<T>where
T: Technology,
impl<T> Recipe for TechRecipe<T>where
T: Technology,
Source§const TIME: u64 = T::POINT_RECIPE_TIME
const TIME: u64 = T::POINT_RECIPE_TIME
Amount of ticks one cycle of the recipe takes to complete.
Source§const INPUT_AMOUNTS: Self::InputAmountsType = T::INPUT_AMOUNTS
const INPUT_AMOUNTS: Self::InputAmountsType = T::INPUT_AMOUNTS
Amount for each of the input resource types, per recipe cycle.
Source§const OUTPUT_AMOUNTS: (u32,)
const OUTPUT_AMOUNTS: (u32,)
Amount for each of the output resource types, per recipe cycle.
Source§type Inputs = <T as TechnologyEx>::Inputs
type Inputs = <T as TechnologyEx>::Inputs
Typically a tuple of multiple
RecipeTypes, to define the inputs
for one cycle of the recipe.Source§type InputAmountsType = <T as TechnologyEx>::InputAmountsType
type InputAmountsType = <T as TechnologyEx>::InputAmountsType
The type for
Self::InputAmountsType, which is used to allow users to
access the input amount for each of the input resource types, per recipe cycle.Source§type Outputs = (Resource<ResearchPoint<T>>,)
type Outputs = (Resource<ResearchPoint<T>>,)
Typically a tuple of multiple
RecipeTypes, to define the outputs
for one cycle of the recipe.Source§type OutputAmountsType = (u32,)
type OutputAmountsType = (u32,)
The type for
Self::OuptutAmountsType, which is used to allow users to
access the output amount for each of the output resource types, per recipe cycle.Source§fn new_inputs() -> Self::Inputs
fn new_inputs() -> Self::Inputs
Factory function to create a new
Self::Inputs with zero resources.Source§fn new_outputs() -> Self::Outputs
fn new_outputs() -> Self::Outputs
Factory function to create a new
Self::Outputs with zero resources.Auto Trait Implementations§
impl<T> Freeze for TechRecipe<T>
impl<T> RefUnwindSafe for TechRecipe<T>where
T: RefUnwindSafe,
impl<T> Send for TechRecipe<T>where
T: Send,
impl<T> Sync for TechRecipe<T>where
T: Sync,
impl<T> Unpin for TechRecipe<T>where
T: Unpin,
impl<T> UnwindSafe for TechRecipe<T>where
T: UnwindSafe,
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