CraftingButton

CraftingButton inherits from TradeButton

CraftingButton sends Player Inputs like Pointer Enter, Pointer Exit, or Click Events to the CraftingUI & CraftingBench. It also handles UI updates to display the current Crafting Progress.


CRAFTING BUTTON

  • craftCallToAction: Text displayed on the Button when an Item can be crafted.

  • collectCallToAction: Text displayed on the Button when an Item has been successfully crafted & can be collected.

  • craftingProgressIndicator: Fills up to display the current progress of a Crafting Process.

The rest of properties are part of TradeButton.

Getters | CraftingButton.cs

RecipeSO

Returns the recipe associated to the Button.

Functions | CraftingButton.cs

SetCurrentAmountText()

Updates Current Amount Text with the current amount value to ensure it is up-to-date.

StartCrafting()

Begins a Crafting Process for the current recipeSO.

FinishCrafting()

Finishes the Crafting Process for the current recipeSO.

Last updated