diff options
author | Travis Watkins <amaranth@ubuntu.com> | 2012-11-06 06:05:28 -0600 |
---|---|---|
committer | Travis Watkins <amaranth@ubuntu.com> | 2012-11-13 16:09:52 -0600 |
commit | 7f7192f8fd8357e664e7e2d6e7c5f65fd0fcd2f7 (patch) | |
tree | 843902ff94d82e86f40d7e0af1ac838fee859e75 /src/main/java/net/minecraft/server/BlockCommand.java | |
parent | a0c3b4f9d1b403fa64230f22b5dd3222181ba646 (diff) | |
download | craftbukkit-7f7192f8fd8357e664e7e2d6e7c5f65fd0fcd2f7.tar craftbukkit-7f7192f8fd8357e664e7e2d6e7c5f65fd0fcd2f7.tar.gz craftbukkit-7f7192f8fd8357e664e7e2d6e7c5f65fd0fcd2f7.tar.lz craftbukkit-7f7192f8fd8357e664e7e2d6e7c5f65fd0fcd2f7.tar.xz craftbukkit-7f7192f8fd8357e664e7e2d6e7c5f65fd0fcd2f7.zip |
Update CraftBukkit to Minecraft 1.4.4.
Diffstat (limited to 'src/main/java/net/minecraft/server/BlockCommand.java')
-rw-r--r-- | src/main/java/net/minecraft/server/BlockCommand.java | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/src/main/java/net/minecraft/server/BlockCommand.java b/src/main/java/net/minecraft/server/BlockCommand.java index c43ba944..34f50ca4 100644 --- a/src/main/java/net/minecraft/server/BlockCommand.java +++ b/src/main/java/net/minecraft/server/BlockCommand.java @@ -1,5 +1,7 @@ package net.minecraft.server; +import java.util.Random; + import org.bukkit.event.block.BlockRedstoneEvent; // CraftBukkit public class BlockCommand extends BlockContainer { @@ -28,19 +30,26 @@ public class BlockCommand extends BlockContainer { // CraftBukkit end if (eventRedstone.getNewCurrent() > 0 && !(eventRedstone.getOldCurrent() > 0)) { // CraftBukkit - TileEntity tileentity = world.getTileEntity(i, j, k); - - if (tileentity != null && tileentity instanceof TileEntityCommand) { - ((TileEntityCommand) tileentity).a(world); - } - world.setRawData(i, j, k, i1 | 1); + world.a(i, j, k, this.id, this.r_()); } else if (!(eventRedstone.getNewCurrent() > 0) && eventRedstone.getOldCurrent() > 0) { // CraftBukkit world.setRawData(i, j, k, i1 & -2); } } } + public void b(World world, int i, int j, int k, Random random) { + TileEntity tileentity = world.getTileEntity(i, j, k); + + if (tileentity != null && tileentity instanceof TileEntityCommand) { + ((TileEntityCommand) tileentity).a(world); + } + } + + public int r_() { + return 1; + } + public boolean interact(World world, int i, int j, int k, EntityHuman entityhuman, int l, float f, float f1, float f2) { TileEntityCommand tileentitycommand = (TileEntityCommand) world.getTileEntity(i, j, k); |