7fea4768fc
By: Dinnerbone <dinnerbone@dinnerbone.com>
26 lines
541 B
Java
26 lines
541 B
Java
package org.bukkit.craftbukkit;
|
|
|
|
import org.bukkit.inventory.Inventory;
|
|
import org.bukkit.inventory.ItemStack;
|
|
import net.minecraft.server.Slot;
|
|
|
|
public class CraftSlot implements org.bukkit.inventory.Slot {
|
|
private final Slot slot;
|
|
|
|
public CraftSlot(Slot slot) {
|
|
this.slot = slot;
|
|
}
|
|
|
|
public Inventory getInventory() {
|
|
return new CraftInventory( slot.b );
|
|
}
|
|
|
|
public int getIndex() {
|
|
return slot.a;
|
|
}
|
|
|
|
public ItemStack getItem() {
|
|
return new CraftItemStack( slot.c() );
|
|
}
|
|
}
|