Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

prismarine-item

Package Overview
Dependencies
Maintainers
1
Versions
31
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

prismarine-item - npm Package Compare versions

Comparing version 1.8.0 to 1.9.0

.github/dependabot.yml

4

index.d.ts
/// <reference types="node" />
import { Tag, TagType } from 'prismarine-nbt'
declare class Item {

@@ -9,3 +11,3 @@ constructor(type: number, count: number, metadata?: number, nbt?: object);

metadata: number;
nbt: Buffer | null;
nbt: Tags[TagType] | null;
name: string;

@@ -12,0 +14,0 @@ displayName: string;

@@ -73,5 +73,8 @@ const nbt = require('prismarine-nbt')

static fromNotch (item) {
if (mcData.isNewerOrEqualTo('1.13')) {
if (mcData.isNewerOrEqualTo('1.14')) {
if (item.present === false) return null
return new Item(item.itemId, item.itemCount, item.nbtData)
} else if (mcData.isNewerOrEqualTo('1.13')) {
if (item.itemId === -1) return null
return new Item(item.itemId, item.itemCount, item.nbtData)
} else {

@@ -78,0 +81,0 @@ if (item.blockId === -1) return null

{
"name": "prismarine-item",
"version": "1.8.0",
"version": "1.9.0",
"description": "Represent a minecraft item with its associated data",

@@ -21,5 +21,5 @@ "main": "index.js",

"devDependencies": {
"@types/node": "^14.0.1",
"@types/node": "^15.0.1",
"jest": "^26.1.0",
"minecraft-data": "2.79.0",
"minecraft-data": "^2.79.0",
"standard": "^16.0.1"

@@ -26,0 +26,0 @@ },

@@ -93,2 +93,8 @@ # prismarine-item

## 1.9.0
* Revise typings (thanks @extremeheat)
* Revise deps (thanks @rom1504)
* Correctly identify null items in MC 1.13 (thanks @u9g)
## 1.8.0

@@ -95,0 +101,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc