OSDN Git Service

修正・変更
[chemicraft/chemicraft.git] / common / pcc / chemicraft / item / ItemDust.java
1 package pcc.chemicraft.item;
2
3 import pcc.chemicraft.ChemiCraft;
4 import pcc.chemicraft.entity.EntityDust;
5 import net.minecraft.creativetab.CreativeTabs;
6 import net.minecraft.entity.player.EntityPlayer;
7 import net.minecraft.item.Item;
8 import net.minecraft.item.ItemStack;
9 import net.minecraft.world.World;
10
11 public class ItemDust extends Item {
12
13         public ItemDust(int par1) {
14                 super(par1);
15                 this.setCreativeTab(ChemiCraft.instance.creativeTabChemiCraft);
16         }
17
18         @Override
19         public ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World,
20                         EntityPlayer par3EntityPlayer) {
21                 par2World.spawnEntityInWorld(new EntityDust(par2World,
22                                 par3EntityPlayer.posX,
23                                 par3EntityPlayer.posY,
24                                 par3EntityPlayer.posZ));
25                 return par1ItemStack;
26         }
27
28         
29 }