Fixed a couple of crashes reported on OpenEye

This commit is contained in:
CrazyPants committed 2014-07-15 12:03:11 +08:00
1 parent c0def671cd
commit d8d40b2330
2 files changed
+10 -7

No files matched your search

+2 -2
View File
@@ -141,7 +141,7 @@ public class Util {
}
public static void dropItems(World world, ItemStack stack, double x, double y, double z, boolean doRandomSpread) {
if(stack.stackSize <= 0) {
if(stack == null || stack.stackSize <= 0) {
return;
}
@@ -165,7 +165,7 @@ public class Util {
}
public static void dropItems(World world, ItemStack stack, int x, int y, int z, boolean doRandomSpread) {
if(stack.stackSize <= 0) {
if(stack == null || stack.stackSize <= 0) {
return;
}