Enum RecipeBookLayout
pub enum RecipeBookLayout {
Crafting {
width: u16,
height: u16,
slots: Vec<u16>,
result: u16,
},
Furnace {
input: u16,
fuel: u16,
result: u16,
},
Stonecutter {
input: u16,
result: u16,
},
Smithing {
template: u16,
base: u16,
addition: u16,
result: u16,
},
}Expand description
Menu-owned roles, never indices into the appended player inventory.
Variants§
Implementations§
§impl RecipeBookLayout
impl RecipeBookLayout
pub fn validate_screen(&self, screen: &Screen) -> Result<(), String>
pub fn validate_screen(&self, screen: &Screen) -> Result<(), String>
Validate typed screen geometry at the same registration boundary as roles.
Menus with declarations, for content-load validation, never per tick.
pub fn registered(
menu: &str,
) -> Option<(RecipeBookTypeKey, String, RecipeBookLayout)>
pub fn registered( menu: &str, ) -> Option<(RecipeBookTypeKey, String, RecipeBookLayout)>
Frozen declaration for a menu, as registered at startup. No declaration means that the menu has no custom-book placement contract.
Trait Implementations§
§impl Clone for RecipeBookLayout
impl Clone for RecipeBookLayout
§fn clone(&self) -> RecipeBookLayout
fn clone(&self) -> RecipeBookLayout
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 more§impl Debug for RecipeBookLayout
impl Debug for RecipeBookLayout
impl Eq for RecipeBookLayout
§impl PartialEq for RecipeBookLayout
impl PartialEq for RecipeBookLayout
impl StructuralPartialEq for RecipeBookLayout
Auto Trait Implementations§
impl Freeze for RecipeBookLayout
impl RefUnwindSafe for RecipeBookLayout
impl Send for RecipeBookLayout
impl Sync for RecipeBookLayout
impl Unpin for RecipeBookLayout
impl UnsafeUnpin for RecipeBookLayout
impl UnwindSafe for RecipeBookLayout
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