TechReborn/src/main/java/techreborn/items/tools/ItemTechPda.java

28 lines
782 B
Java
Raw Normal View History

package techreborn.items.tools;
2015-04-17 21:12:58 +02:00
2015-04-18 13:13:22 +02:00
import net.minecraft.entity.player.EntityPlayer;
2015-04-17 21:12:58 +02:00
import net.minecraft.item.Item;
2015-04-18 13:13:22 +02:00
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import techreborn.Core;
import techreborn.client.GuiHandler;
import techreborn.client.TechRebornCreativeTab;
2015-04-17 21:12:58 +02:00
2015-04-24 15:20:09 +02:00
public class ItemTechPda extends Item {
public ItemTechPda() {
setCreativeTab(TechRebornCreativeTab.instance);
setUnlocalizedName("techreborn.pda");
setMaxStackSize(1);
}
2015-04-24 15:20:09 +02:00
@Override
public ItemStack onItemRightClick(ItemStack itemStack, World world, EntityPlayer player) {
player.openGui(Core.INSTANCE, GuiHandler.pdaID, world,
(int) player.posX, (int) player.posY, (int) player.posY);
return itemStack;
}
2015-04-17 21:12:58 +02:00
}