pub struct RecipeIngredient {
pub name: &'static str,
pub amount: i64,
pub fluid: bool,
}Expand description
Item or fluid ingredient for a Recipe.
Factorio 2.0 requires {type, name, amount}. Set Self::fluid to emit
type = "fluid"; otherwise type = "item" is injected.
Fields§
§name: &'static strIngredient prototype name.
amount: i64Count (items) or amount (fluids).
fluid: boolWhen true, Lua type = "fluid"; otherwise "item".
Trait Implementations§
Source§impl Clone for RecipeIngredient
impl Clone for RecipeIngredient
Source§fn clone(&self) -> RecipeIngredient
fn clone(&self) -> RecipeIngredient
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for RecipeIngredient
Source§impl Debug for RecipeIngredient
impl Debug for RecipeIngredient
Source§impl Default for RecipeIngredient
impl Default for RecipeIngredient
Source§fn default() -> RecipeIngredient
fn default() -> RecipeIngredient
Returns the “default value” for a type. Read more
impl Eq for RecipeIngredient
Source§impl PartialEq for RecipeIngredient
impl PartialEq for RecipeIngredient
impl StructuralPartialEq for RecipeIngredient
Auto Trait Implementations§
impl Freeze for RecipeIngredient
impl RefUnwindSafe for RecipeIngredient
impl Send for RecipeIngredient
impl Sync for RecipeIngredient
impl Unpin for RecipeIngredient
impl UnsafeUnpin for RecipeIngredient
impl UnwindSafe for RecipeIngredient
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