Adds item to creative inventory.
string or numeric item ID
amount of the item to be added, generally should be 1
item data
Optional
extra: ItemExtraDataCreates armor item using specified parameters.
string ID of the item; you should register it via IDRegistry.genItemID call first
item name in English; add translations to the name using Translation module, all translation to the item and block names are applied automatically
texture data used to create item
general armor item parameters object, the armor type there is required
Creates eatable item using specified parameters.
string ID of the item. You should register it via IDRegistry.genItemID call first
item name in English; add translations to the name using Translation module, all translation to the item and block names are applied automatically
texture data used to create item
Optional
params: FoodParamsadditional item parameters
Optional
params: ItemParamsUse Item.createItem and Recipes.addFurnaceFuel instead.
Creates new item using specified parameters.
string ID of the item; you should register it via IDRegistry.genItemID call first
item name in English; add translations to the name using Translation module, all translation to the item and block names are applied automatically
texture data used to create item
Optional
params: ItemParamsadditional item parameters
Creates throwable item using specified parameters.
string ID of the item; you should register it via IDRegistry.genItemID call first
item name in English; add translations to the name using Translation module, all translation to the item and block names are applied automatically
texture data used to create item
Optional
params: ItemParamsadditional item parameters
Gets NativeItem instance that can be used to apply some properties to the item.
string ID of the item
NativeItem instance associated with this item.
Internal
Invoke click on the block in world without target.
item which used on the block
if true
, mod ItemUse callback will be not executed
Internal
Invoke click on the block in world.
coords of click on the block
item which used on the block
if true
, mod ItemUse callback will be not executed
player which clicked on the block
numeric item ID
true
, if an item with such ID exists, false
otherwise.
numeric item ID
no longer supported, do not use this parameter
true
, if an item with such ID exists, false
otherwise.
Registers function to be called when item is dispensed from dispenser.
string or numeric ID of the item
function that is called when such an event occurs
Registers item ID as requiring item icon override and registers function to perform such an override.
string or numeric ID of the item
function that is called to override item icon. Should return Item.TextureData object to be used for the item. See Callback.ItemIconOverrideFunction documentation for details
Registers function to perform item name override.
string or numeric ID of the item
function that is called to override item name. Should return string to be used as new item name
Registers function to be called when player uses item in the air (not on the block).
string or numeric ID of the item
function that is called when such an event occurs
Registers function that is called when throwable item with specified ID hits block or entity.
string or numeric ID of the item
function that is called when such an event occurs
Same as Item.registerThrowableFunction, but supports numeric IDs only.
Registers function that is called when user touches some block in the world with specified item.
string or numeric ID of the item
function that is called when such an event occurs
Same as Item.registerUseFunction, but supports numeric IDs only.
Registers function to be called when player completes using item that has maximum use time set with Item.setMaxUseDuration function.
string or numeric ID of the item
function that is called when such an event occurs
Registers function to be called when player doesn't complete using item that has maximum use time set with Item.setMaxUseDuration function. Vanilla bow uses this function with max use duration of 72000 ticks.
string or numeric ID of the item
function that is called when such an event occurs
Sets item creative category.
string or numeric item ID
item category, should be one of the EItemCategory values
Specifies how the item can be enchanted.
string or numeric item ID
enchant type defining when enchants can or cannot be applied to this item, one of the EEnchantType
quality of the enchants that are applied, the higher this value is, the better enchants you get with the same level
Should not be used in new mods, consider using Item properties setters instead.
Sets animation type for the item.
string or numeric item ID
use animation type, one of the EItemAnimation values
Copyright © 2024 Nernar. Copyright © 2020 #mineprogramming. Built with ❤ and TypeDoc.
Module used to define items and their properties.