Fork of Poseidon providing Bukkit #1060 to older Beta versions (b1.0-b1.7.3)
1package net.minecraft.server;
2
3public class ItemRecord extends Item {
4
5 public final String a;
6
7 protected ItemRecord(int i, String s) {
8 super(i);
9 this.a = s;
10 this.maxStackSize = 1;
11 }
12
13 public boolean a(ItemStack itemstack, EntityHuman entityhuman, World world, int i, int j, int k, int l) {
14 if (world.getTypeId(i, j, k) == Block.JUKEBOX.id && world.getData(i, j, k) == 0) {
15 if (world.isStatic) {
16 return true;
17 } else {
18 ((BlockJukeBox) Block.JUKEBOX).f(world, i, j, k, this.id);
19 world.a((EntityHuman) null, 1005, i, j, k, this.id);
20 --itemstack.count;
21 return true;
22 }
23 } else {
24 return false;
25 }
26 }
27}