mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-13 05:27:37 +00:00
Try and work?
This commit is contained in:
1 parent
e316946915
commit
639e44f98f
2 files changed
+4
-13
No files matched your search
@@ -8,7 +8,7 @@ import noppes.npcs.controllers.data.INpcScriptHandler;
|
||||
import noppes.npcs.controllers.data.LinkedItem;
|
||||
|
||||
public class ScriptLinkedItem extends ScriptCustomizableItem implements IItemLinked {
|
||||
public LinkedItem linkedItem;
|
||||
public LinkedItem linkedItem = new LinkedItem();
|
||||
public double durabilityValue = 1.0D;
|
||||
public int linkedVersion = 1;
|
||||
public ScriptLinkedItem(ItemStack item) {
|
||||
@@ -16,13 +16,6 @@ public class ScriptLinkedItem extends ScriptCustomizableItem implements IItemLin
|
||||
loadItemData();
|
||||
}
|
||||
|
||||
// For Building
|
||||
public ScriptLinkedItem(ItemStack item, LinkedItem original) {
|
||||
super(item);
|
||||
setDefaults();
|
||||
this.linkedItem = original.clone();
|
||||
}
|
||||
|
||||
public void setDefaults(){
|
||||
this.itemDisplay.texture = null;
|
||||
this.itemDisplay.translateX = null;
|
||||
@@ -201,8 +194,6 @@ public class ScriptLinkedItem extends ScriptCustomizableItem implements IItemLin
|
||||
|
||||
public void setItemNBT(NBTTagCompound compound) {
|
||||
this.itemDisplay.readFromNBT(compound);
|
||||
if(linkedItem == null)
|
||||
this.linkedItem = new LinkedItem();
|
||||
this.linkedItem.readFromNBT(compound, false);
|
||||
this.linkedVersion = compound.getInteger(LinkedItem.LINKED_VERSION_VERSION_TAG);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user