From 6e097a5056ad343271e21109f593f7cb77e4667e Mon Sep 17 00:00:00 2001 From: bculkin2442 Date: Thu, 5 Sep 2019 20:11:13 -0400 Subject: More affix work, and some other cleanups --- .../java/darkknight/jewelrycraft/worldGen/WorldGenStructure2.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/main/java/darkknight/jewelrycraft/worldGen') diff --git a/src/main/java/darkknight/jewelrycraft/worldGen/WorldGenStructure2.java b/src/main/java/darkknight/jewelrycraft/worldGen/WorldGenStructure2.java index 3c304b0..afde2b1 100755 --- a/src/main/java/darkknight/jewelrycraft/worldGen/WorldGenStructure2.java +++ b/src/main/java/darkknight/jewelrycraft/worldGen/WorldGenStructure2.java @@ -41,7 +41,9 @@ public class WorldGenStructure2 extends WorldGenStructure { world.setBlockMetadataWithNotify(x + i, y, z + k, (k == -1) ? 3 : (k == 0) ? (i == 1) ? 0 : 1 : 2, 2); world.setBlock(x, y, z, Blocks.air); ItemStack stack = new ItemStack(ItemList.bucket); - JewelryNBT.addMetal(stack, JewelrycraftUtil.metal.get(rand.nextInt(JewelrycraftUtil.metal.size()))); + if (JewelrycraftUtil.metal.size() > 0) { + JewelryNBT.addMetal(stack, JewelrycraftUtil.metal.get(rand.nextInt(JewelrycraftUtil.metal.size()))); + } if (stack != null && JewelryNBT.ingot(stack) != null) { if (!world.isRemote) world.func_147480_a(x, y, z, true); -- cgit v1.2.3