diff --git a/src/main/java/micdoodle8/mods/galacticraft/core/entities/EntityParachest.java b/src/main/java/micdoodle8/mods/galacticraft/core/entities/EntityParachest.java index d55102be0d..04591737ba 100644 --- a/src/main/java/micdoodle8/mods/galacticraft/core/entities/EntityParachest.java +++ b/src/main/java/micdoodle8/mods/galacticraft/core/entities/EntityParachest.java @@ -109,16 +109,6 @@ public void onUpdate() this.setDead(); return; } - else if (this.cargo != null) - { - for (final ItemStack stack : this.cargo) - { - final EntityItem e = new EntityItem(this.worldObj, this.posX, this.posY, this.posZ, stack); - this.worldObj.spawnEntityInWorld(e); - } - - return; - } } } @@ -126,9 +116,14 @@ else if (this.cargo != null) { for (final ItemStack stack : this.cargo) { - final EntityItem e = new EntityItem(this.worldObj, this.posX, this.posY, this.posZ, stack); - this.worldObj.spawnEntityInWorld(e); + if (stack != null) + { + final EntityItem e = new EntityItem(this.worldObj, this.posX, this.posY, this.posZ, stack); + this.worldObj.spawnEntityInWorld(e); + } } + this.setDead(); + return; } } else