cCraftingRecipe


Index:
Articles
Classes
Hooks

Quick navigation:
BannerPattern
BossBarColor
BossBarDivisionType
cArrowEntity
cBeaconEntity
cBedEntity
cBlockArea
cBlockEntity
cBlockEntityWithItems
cBlockInfo
cBoat
cBoundingBox
cBrewingstandEntity
cChatColor
cChestEntity
cChunkDesc
cClientHandle
cColor
cCommandBlockEntity
cCompositeChat
cCraftingGrid
cCraftingRecipe
cCryptoHash
cCuboid
cDispenserEntity
cDropperEntity
cDropSpenserEntity
cEnchantments
cEnderCrystal
cEntity
cEntityEffect
cExpBottleEntity
cExpOrb
cFallingBlock
cFile
cFireChargeEntity
cFireworkEntity
cFloater
cFlowerPotEntity
cFurnaceEntity
cGhastFireballEntity
cHangingEntity
cHopperEntity
cIniFile
cInventory
cItem
cItemFrame
cItemGrid
cItems
cJson
cJukeboxEntity
cLeashKnot
cLineBlockTracer
cLuaWindow
cMap
cMapManager
cMobHeadEntity
cMobSpawnerEntity
cMojangAPI
cMonster
cNetwork
cNoteEntity
cObjective
cPainting
cPawn
cPickup
cPlayer
cPlugin
cPluginLua
cPluginManager
cProjectileEntity
cRankManager
cRoot
cScoreboard
cServer
cServerHandle
cSignEntity
cSplashPotionEntity
cStringCompression
cTCPLink
cTeam
cThrownEggEntity
cThrownEnderPearlEntity
cThrownSnowballEntity
cTNTEntity
cUDPEndpoint
cUrlClient
cUrlParser
CustomStatistic
cUUID
cWebAdmin
cWindow
cWitherSkullEntity
cWorld
EffectID
HTTPFormData
HTTPRequest
HTTPTemplateRequest
ItemCategory
lxp
SmokeDirection
sqlite3
StatisticsManager
TakeDamageInfo
tolua
Vector3d
Vector3f
Vector3i
Globals

Contents


cCraftingRecipe class

This class is used to represent a crafting recipe, either a built-in one, or one created dynamically in a plugin. It is used only as a parameter for OnCraftingNoRecipe, OnPostCrafting and OnPreCrafting hooks. Plugins may use it to inspect or modify a crafting recipe that a player views in their crafting window, either at a crafting table or the survival inventory screen.

Internally, the class contains a cCraftingGrid for the ingredients and a cItem for the result.


Functions

NameParametersReturn valueNotes
Clear Clears the entire recipe, both ingredients and results
ConsumeIngredients
CraftingGridcCraftingGrid
Consumes ingredients specified in the given cCraftingGrid class
Dump DEBUG build: dumps ingredients and result into server log. RELEASE build: no action
GetIngredient
xnumber
ynumber
cItem
Returns the ingredient stored in the recipe at the specified coords
GetIngredientsHeight
number
Returns the height of the ingredients' grid
GetIngredientsWidth
number
Returns the width of the ingredients' grid
GetResult
cItem
Returns the result of the recipe
SetIngredient
xnumber
ynumber
cItemcItem
Sets the ingredient at the specified coords
SetIngredient
xnumber
ynumber
ItemTypenumber
ItemCountnumber
ItemDamagenumber
Sets the ingredient at the specified coords
SetResult
ItemTypenumber
ItemCountnumber
ItemDamagenumber
Sets the result item
SetResult
cItemcItem
Sets the result item
Generated by APIDump on 2024-10-25 05:01:00, Build ID Unknown, Commit approx: 0325de7dacaf1e2feaea5eaab4791bc23d78f9e7