mirror of
https://github.com/GTNewHorizons/ForbiddenMagic.git
synced 2026-11-24 05:44:40 +00:00
Fixing NullPointerException
Will not throw NPE when other mods muck with gold armor anymore.
This commit is contained in:
1 parent
ad5defb1a9
commit
bd92f19615
1 file changed
+19
-10
@@ -92,25 +92,34 @@ public class DarkAspects
|
||||
ThaumcraftApi.registerObjectTag(Block.tnt.blockID, 0, list);
|
||||
|
||||
list = ThaumcraftApiHelper.getObjectAspects(new ItemStack(Item.helmetGold));
|
||||
list.add(PRIDE, 2);
|
||||
ThaumcraftApi.registerObjectTag(Item.helmetGold.itemID, -1, list);
|
||||
if(list != null){
|
||||
list.add(PRIDE, 2);
|
||||
ThaumcraftApi.registerObjectTag(Item.helmetGold.itemID, -1, list);
|
||||
}
|
||||
|
||||
list = ThaumcraftApiHelper.getObjectAspects(new ItemStack(Item.plateGold));
|
||||
list.add(PRIDE, 1);
|
||||
ThaumcraftApi.registerObjectTag(Item.plateGold.itemID, -1, list);
|
||||
if(list != null){
|
||||
list.add(PRIDE, 1);
|
||||
ThaumcraftApi.registerObjectTag(Item.plateGold.itemID, -1, list);
|
||||
}
|
||||
|
||||
list = ThaumcraftApiHelper.getObjectAspects(new ItemStack(Item.legsGold));
|
||||
list.add(PRIDE, 1);
|
||||
ThaumcraftApi.registerObjectTag(Item.legsGold.itemID, -1, list);
|
||||
if(list != null){
|
||||
list.add(PRIDE, 1);
|
||||
ThaumcraftApi.registerObjectTag(Item.legsGold.itemID, -1, list);
|
||||
}
|
||||
|
||||
list = ThaumcraftApiHelper.getObjectAspects(new ItemStack(Item.bootsGold));
|
||||
list.add(PRIDE, 1);
|
||||
ThaumcraftApi.registerObjectTag(Item.bootsGold.itemID, -1, list);
|
||||
if(list != null){
|
||||
list.add(PRIDE, 1);
|
||||
ThaumcraftApi.registerObjectTag(Item.bootsGold.itemID, -1, list);
|
||||
}
|
||||
|
||||
list = ThaumcraftApiHelper.getObjectAspects(new ItemStack(Item.swordGold));
|
||||
if(list != null)
|
||||
if(list != null){
|
||||
list.add(PRIDE, 2);
|
||||
ThaumcraftApi.registerObjectTag(Item.swordGold.itemID, -1, list);
|
||||
ThaumcraftApi.registerObjectTag(Item.swordGold.itemID, -1, list);
|
||||
}
|
||||
|
||||
//list = ThaumcraftApiHelper.getObjectAspects(new ItemStack(Item.bed));
|
||||
//list.add(SLOTH, 4);
|
||||
|
||||
Reference in new issue
Block a user