Security News
38% of CISOs Fear They’re Not Moving Fast Enough on AI
CISOs are racing to adopt AI for cybersecurity, but hurdles in budgets and governance may leave some falling behind in the fight against cyber threats.
prismarine-item
Advanced tools
Represent a minecraft item with its associated data
const Item = require('prismarine-item')('1.8')
const ironShovelItem = new Item(256, 1)
console.log(ironShovelItem)
const notchItem = Item.toNotch(ironShovelItem)
console.log(notchItem)
console.log(Item.fromNotch(notchItem))
Take an Item
instance and returns it in the format of the minecraft packets.
Take an item
in the format of the minecraft packets and return an Item
instance.
Take two seperate item
instances, and makes one item using the same combining done by the vanilla anvil
itemOne
- first item
itemTwo
- second item
matchStackSize
- whether to check for count equality
matchNbt
- wether to check for NBT equality
Checks equality between two items based on itemType, count, metadata, and stringified nbt
Numerical id.
Number which represents different things depending on the item. See http://www.minecraftwiki.net/wiki/Data_values#Data
Buffer.
The stack ID of the item, if the version supports Stack IDs.
Return true if items are equal.
A getter/setter for abstracting the underlying nbt
the item's custom name (ie. anvil name)
the item's custom lore (ie. set in give command)
Returns an array of enchants on the Item with their name and level
Updates the Item's NBT enchantments based on assigned array
In adventure mode, the list of block names (as strings) that this Item can be placed on
In adventure mode, the list of block names (as strings) that this Item can be used to break
A getter/setter for abstracting the underlying nbt. See https://minecraft.gamepedia.com/Anvil_mechanics#Anvil_Uses
If the current item is a type of Spawn Egg, the protocol name of the entity that will be spawned. For example, a zombie spawn egg on 1.8 will return Zombie
.
Max durability for the item, if it supports durability
maxDurability
field, fix handling item sent by server with new sentByServer
arg (#106) (thanks @extremeheat)FAQs
Represent a minecraft item with its associated data
The npm package prismarine-item receives a total of 9,400 weekly downloads. As such, prismarine-item popularity was classified as popular.
We found that prismarine-item demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
CISOs are racing to adopt AI for cybersecurity, but hurdles in budgets and governance may leave some falling behind in the fight against cyber threats.
Research
Security News
Socket researchers uncovered a backdoored typosquat of BoltDB in the Go ecosystem, exploiting Go Module Proxy caching to persist undetected for years.
Security News
Company News
Socket is joining TC54 to help develop standards for software supply chain security, contributing to the evolution of SBOMs, CycloneDX, and Package URL specifications.