Update CraftBukkit to Minecraft 1.4.4.

By: Travis Watkins <amaranth@ubuntu.com>
This commit is contained in:
CraftBukkit/Spigot
2012-11-06 06:05:28 -06:00
parent f6c50c0851
commit 3f728bab1a
11 changed files with 25 additions and 192 deletions

View File

@@ -1,5 +1,7 @@
package org.bukkit.craftbukkit.block;
import net.minecraft.server.Item;
import net.minecraft.server.ItemStack;
import org.bukkit.Effect;
import org.bukkit.Material;
import org.bukkit.block.Block;
@@ -21,14 +23,14 @@ public class CraftJukebox extends CraftBlockState implements Jukebox {
}
public Material getPlaying() {
return Material.getMaterial(jukebox.record);
return Material.getMaterial(jukebox.record.id);
}
public void setPlaying(Material record) {
if (record == null) {
record = Material.AIR;
}
jukebox.record = record.getId();
jukebox.record = new ItemStack(Item.byId[record.getId()], 1);
jukebox.update();
if (record == Material.AIR) {
world.getHandle().setData(getX(), getY(), getZ(), 0);