diff options
author | Erik Broes <erikbroes@grum.nl> | 2011-11-20 00:01:14 -0800 |
---|---|---|
committer | Erik Broes <erikbroes@ripe.net> | 2011-11-20 00:01:33 -0800 |
commit | 345ea36c7bb3383c6e4825355d0043a646194eaa (patch) | |
tree | df116b57d92315c0a13c2fdc87d792b031c7239a /src/main/java/net/minecraft/server/ItemBed.java | |
parent | 589f66bd1b766dc1fdd737ee885304196a2ed86a (diff) | |
download | craftbukkit-345ea36c7bb3383c6e4825355d0043a646194eaa.tar craftbukkit-345ea36c7bb3383c6e4825355d0043a646194eaa.tar.gz craftbukkit-345ea36c7bb3383c6e4825355d0043a646194eaa.tar.lz craftbukkit-345ea36c7bb3383c6e4825355d0043a646194eaa.tar.xz craftbukkit-345ea36c7bb3383c6e4825355d0043a646194eaa.zip |
Update for 1.0.0
Diffstat (limited to 'src/main/java/net/minecraft/server/ItemBed.java')
-rw-r--r-- | src/main/java/net/minecraft/server/ItemBed.java | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/src/main/java/net/minecraft/server/ItemBed.java b/src/main/java/net/minecraft/server/ItemBed.java index f78467c0..d0d284b9 100644 --- a/src/main/java/net/minecraft/server/ItemBed.java +++ b/src/main/java/net/minecraft/server/ItemBed.java @@ -40,7 +40,7 @@ public class ItemBed extends Item { b0 = 1; } - if (entityhuman.c(i, j, k) && entityhuman.c(i + b0, j, k + b1)) { + if (entityhuman.d(i, j, k) && entityhuman.d(i + b0, j, k + b1)) { if (world.isEmpty(i, j, k) && world.isEmpty(i + b0, j, k + b1) && world.e(i, j - 1, k) && world.e(i + b0, j - 1, k + b1)) { CraftBlockState blockState = CraftBlockState.getBlockState(world, i, j, k); // CraftBukkit @@ -55,7 +55,10 @@ public class ItemBed extends Item { } // CraftBukkit end - world.setTypeIdAndData(i + b0, j, k + b1, blockbed.id, i1 + 8); + if (world.getTypeId(i, j, k) == blockbed.id) { + world.setTypeIdAndData(i + b0, j, k + b1, blockbed.id, i1 + 8); + } + --itemstack.count; return true; } else { |