recipe

package
v1.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 30, 2026 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Perform

func Perform(block string, input ...world.Item) (output []item.Stack, ok bool)

func Register

func Register(recipe Recipe)

func RegisterDynamic

func RegisterDynamic(recipe DynamicRecipe)

func ValidBrewingReagent

func ValidBrewingReagent(i world.Item) bool

Types

type DecoratedPotRecipe

type DecoratedPotRecipe struct {
	// contains filtered or unexported fields
}

func NewDecoratedPotRecipe

func NewDecoratedPotRecipe() DecoratedPotRecipe

func (DecoratedPotRecipe) Block

func (r DecoratedPotRecipe) Block() string

func (DecoratedPotRecipe) Match

func (r DecoratedPotRecipe) Match(input []Item) (output []item.Stack, ok bool)

type DynamicRecipe

type DynamicRecipe interface {
	Match(input []Item) (output []item.Stack, ok bool)

	Block() string
}

func DynamicRecipes

func DynamicRecipes() []DynamicRecipe

type Item

type Item interface {
	Count() int

	Empty() bool
}

type ItemTag

type ItemTag struct {
	// contains filtered or unexported fields
}

func NewItemTag

func NewItemTag(tag string, count int) ItemTag

func (ItemTag) Contains

func (i ItemTag) Contains(name string) bool

func (ItemTag) Count

func (i ItemTag) Count() int

func (ItemTag) Empty

func (i ItemTag) Empty() bool

func (ItemTag) Tag

func (i ItemTag) Tag() string

type Potion

type Potion struct {
	// contains filtered or unexported fields
}

func NewPotion

func NewPotion(input, reagent Item, output item.Stack) Potion

func (Potion) Block

func (r Potion) Block() string

func (Potion) Input

func (r Potion) Input() []Item

func (Potion) Output

func (r Potion) Output() []item.Stack

func (Potion) Priority

func (r Potion) Priority() uint32

type PotionContainerChange

type PotionContainerChange struct {
	// contains filtered or unexported fields
}

func NewPotionContainerChange

func NewPotionContainerChange(input, output world.Item, reagent item.Stack) PotionContainerChange

func (PotionContainerChange) Block

func (r PotionContainerChange) Block() string

func (PotionContainerChange) Input

func (r PotionContainerChange) Input() []Item

func (PotionContainerChange) Output

func (r PotionContainerChange) Output() []item.Stack

func (PotionContainerChange) Priority

func (r PotionContainerChange) Priority() uint32

type Recipe

type Recipe interface {
	Input() []Item

	Output() []item.Stack

	Block() string

	Priority() uint32
}

func Recipes

func Recipes() []Recipe

type Shape

type Shape [2]int

func NewShape

func NewShape(width, height int) Shape

func (Shape) Height

func (s Shape) Height() int

func (Shape) Width

func (s Shape) Width() int

type Shaped

type Shaped struct {
	// contains filtered or unexported fields
}

func NewShaped

func NewShaped(input []Item, output item.Stack, shape Shape, block string) Shaped

func (Shaped) Block

func (r Shaped) Block() string

func (Shaped) Input

func (r Shaped) Input() []Item

func (Shaped) Output

func (r Shaped) Output() []item.Stack

func (Shaped) Priority

func (r Shaped) Priority() uint32

func (Shaped) Shape

func (r Shaped) Shape() Shape

type Shapeless

type Shapeless struct {
	// contains filtered or unexported fields
}

func NewShapeless

func NewShapeless(input []Item, output item.Stack, block string) Shapeless

func (Shapeless) Block

func (r Shapeless) Block() string

func (Shapeless) Input

func (r Shapeless) Input() []Item

func (Shapeless) Output

func (r Shapeless) Output() []item.Stack

func (Shapeless) Priority

func (r Shapeless) Priority() uint32

type SmithingTransform

type SmithingTransform struct {
	// contains filtered or unexported fields
}

func NewSmithingTransform

func NewSmithingTransform(base, addition, template Item, output item.Stack, block string) SmithingTransform

func (SmithingTransform) Block

func (r SmithingTransform) Block() string

func (SmithingTransform) Input

func (r SmithingTransform) Input() []Item

func (SmithingTransform) Output

func (r SmithingTransform) Output() []item.Stack

func (SmithingTransform) Priority

func (r SmithingTransform) Priority() uint32

type SmithingTrim

type SmithingTrim struct {
	// contains filtered or unexported fields
}

func NewSmithingTrim

func NewSmithingTrim(base, addition, template Item, block string) SmithingTrim

func (SmithingTrim) Block

func (r SmithingTrim) Block() string

func (SmithingTrim) Input

func (r SmithingTrim) Input() []Item

func (SmithingTrim) Output

func (r SmithingTrim) Output() []item.Stack

func (SmithingTrim) Priority

func (r SmithingTrim) Priority() uint32

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL