added magical orbs. so far the air orb is the only one with functionality.
This commit is contained in:
parent
61ce5e3bce
commit
f3ebfbc7c1
11 changed files with 238 additions and 23 deletions
|
|
@ -17,6 +17,32 @@ import net.minecraftforge.liquids.LiquidStack;
|
|||
|
||||
public class ItemHandler$1 {
|
||||
|
||||
public static Item staffParts;
|
||||
|
||||
public static Item imbuedShard;
|
||||
|
||||
public static Item fireStaff;
|
||||
public static Item waterStaff;
|
||||
public static Item earthStaff;
|
||||
public static Item airStaff;
|
||||
public static Item energyStaff;
|
||||
|
||||
public static Item fireStaffPower;
|
||||
public static Item waterStaffPower;
|
||||
public static Item earthStaffPower;
|
||||
public static Item airStaffPower;
|
||||
public static Item energyStaffPower;
|
||||
|
||||
public static Item staffPower;
|
||||
|
||||
public static Item fireOrb;
|
||||
public static Item waterOrb;
|
||||
public static Item earthOrb;
|
||||
public static Item airOrb;
|
||||
public static Item energyOrb;
|
||||
|
||||
public static Item bushFruit;
|
||||
|
||||
public static Item verditeHelmet;
|
||||
public static Item verditeChestplate;
|
||||
public static Item verditeLeggings;
|
||||
|
|
@ -37,25 +63,6 @@ public class ItemHandler$1 {
|
|||
public static Item iridiumLeggings;
|
||||
public static Item iridiumBoots;
|
||||
|
||||
public static Item staffParts;
|
||||
|
||||
public static Item imbuedShard;
|
||||
|
||||
public static Item fireStaff;
|
||||
public static Item waterStaff;
|
||||
public static Item earthStaff;
|
||||
public static Item airStaff;
|
||||
public static Item energyStaff;
|
||||
|
||||
public static Item fireStaffPower;
|
||||
public static Item waterStaffPower;
|
||||
public static Item earthStaffPower;
|
||||
public static Item airStaffPower;
|
||||
public static Item energyStaffPower;
|
||||
|
||||
public static Item ItemStaffPower;
|
||||
|
||||
public static Item bushFruit;
|
||||
|
||||
public static void init(){
|
||||
|
||||
|
|
@ -69,7 +76,13 @@ public class ItemHandler$1 {
|
|||
airStaff = new ItemStaffAir(ItemIds.AIR_STAFF).setUnlocalizedName(Strings.AIR_STAFF_NAME);
|
||||
energyStaff = new ItemStaffEnegy(ItemIds.ENERGY_STAFF).setUnlocalizedName(Strings.ENERGY_STAFF_NAME);
|
||||
|
||||
ItemStaffPower = new ItemStaffPower(ItemIds.STAFF_POWER);
|
||||
staffPower = new ItemStaffPower(ItemIds.STAFF_POWER).setUnlocalizedName(Strings.POWER_STAFF_NAME);
|
||||
|
||||
fireOrb = new ItemOrbFire(ItemIds.FIRE_ORB).setUnlocalizedName(Strings.FIRE_ORB_NAME);
|
||||
waterOrb = new ItemOrbWater(ItemIds.WATER_ORB).setUnlocalizedName(Strings.WATER_ORB_NAME);
|
||||
earthOrb = new ItemOrbEarth(ItemIds.EARTH_ORB).setUnlocalizedName(Strings.EARTH_ORB_NAME);
|
||||
airOrb = new ItemOrbAir(ItemIds.AIR_ORB).setUnlocalizedName(Strings.AIR_ORB_NAME);
|
||||
energyOrb = new ItemOrbEnergy(ItemIds.ENERGY_ORB).setUnlocalizedName(Strings.EARTH_ORB_NAME);
|
||||
|
||||
bushFruit = new ItemBushFruit(ItemIds.BUSH_FRUIT, 2).setUnlocalizedName(Strings.BUSH_FRUIT_NAME);
|
||||
|
||||
|
|
|
|||
|
|
@ -5,6 +5,7 @@ import java.util.List;
|
|||
import net.minecraft.client.renderer.texture.IconRegister;
|
||||
import net.minecraft.creativetab.CreativeTabs;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.potion.Potion;
|
||||
import net.minecraft.potion.PotionEffect;
|
||||
|
|
@ -16,7 +17,7 @@ import MysticWorld.Lib.Strings;
|
|||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
||||
public class ItemImbuedShard extends ItemMysticWorld {
|
||||
public class ItemImbuedShard extends Item {
|
||||
|
||||
private Icon[] icons;
|
||||
|
||||
|
|
|
|||
35
common/MysticWorld/Items/ItemOrbAir.java
Normal file
35
common/MysticWorld/Items/ItemOrbAir.java
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
package MysticWorld.Items;
|
||||
|
||||
import MysticWorld.MysticWorld;
|
||||
import MysticWorld.Entity.EntityChargeAir;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.MathHelper;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class ItemOrbAir extends Item {
|
||||
|
||||
public ItemOrbAir(int par1)
|
||||
{
|
||||
super(par1);
|
||||
this.setMaxStackSize(1);
|
||||
this.setMaxDamage(500);
|
||||
this.setCreativeTab(MysticWorld.MysticWorldTab);
|
||||
}
|
||||
|
||||
public ItemStack onItemRightClick(ItemStack itemStack, World world, EntityPlayer entityPlayer)
|
||||
{
|
||||
world.playSoundEffect(entityPlayer.posX, entityPlayer.posY, entityPlayer.posZ, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F);
|
||||
|
||||
entityPlayer.addVelocity(0, 2.5, 0);
|
||||
|
||||
if (!world.isRemote)
|
||||
{
|
||||
itemStack.damageItem(1, entityPlayer);
|
||||
}
|
||||
|
||||
return itemStack;
|
||||
}
|
||||
|
||||
}
|
||||
32
common/MysticWorld/Items/ItemOrbEarth.java
Normal file
32
common/MysticWorld/Items/ItemOrbEarth.java
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
package MysticWorld.Items;
|
||||
|
||||
import MysticWorld.MysticWorld;
|
||||
import MysticWorld.Entity.EntityChargeAir;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class ItemOrbEarth extends Item {
|
||||
|
||||
public ItemOrbEarth(int par1)
|
||||
{
|
||||
super(par1);
|
||||
this.setMaxStackSize(1);
|
||||
this.setMaxDamage(64);
|
||||
this.setCreativeTab(MysticWorld.MysticWorldTab);
|
||||
}
|
||||
|
||||
public ItemStack onItemRightClick(ItemStack itemStack, World world, EntityPlayer entityPlayer)
|
||||
{
|
||||
world.playSoundEffect(entityPlayer.posX, entityPlayer.posY, entityPlayer.posZ, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F);
|
||||
|
||||
if (!world.isRemote)
|
||||
{
|
||||
itemStack.damageItem(1, entityPlayer);
|
||||
}
|
||||
|
||||
return itemStack;
|
||||
}
|
||||
|
||||
}
|
||||
32
common/MysticWorld/Items/ItemOrbEnergy.java
Normal file
32
common/MysticWorld/Items/ItemOrbEnergy.java
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
package MysticWorld.Items;
|
||||
|
||||
import MysticWorld.MysticWorld;
|
||||
import MysticWorld.Entity.EntityChargeAir;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class ItemOrbEnergy extends Item {
|
||||
|
||||
public ItemOrbEnergy(int par1)
|
||||
{
|
||||
super(par1);
|
||||
this.setMaxStackSize(1);
|
||||
this.setMaxDamage(64);
|
||||
this.setCreativeTab(MysticWorld.MysticWorldTab);
|
||||
}
|
||||
|
||||
public ItemStack onItemRightClick(ItemStack itemStack, World world, EntityPlayer entityPlayer)
|
||||
{
|
||||
world.playSoundEffect(entityPlayer.posX, entityPlayer.posY, entityPlayer.posZ, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F);
|
||||
|
||||
if (!world.isRemote)
|
||||
{
|
||||
itemStack.damageItem(1, entityPlayer);
|
||||
}
|
||||
|
||||
return itemStack;
|
||||
}
|
||||
|
||||
}
|
||||
32
common/MysticWorld/Items/ItemOrbFire.java
Normal file
32
common/MysticWorld/Items/ItemOrbFire.java
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
package MysticWorld.Items;
|
||||
|
||||
import MysticWorld.MysticWorld;
|
||||
import MysticWorld.Entity.EntityChargeAir;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class ItemOrbFire extends Item {
|
||||
|
||||
public ItemOrbFire(int par1)
|
||||
{
|
||||
super(par1);
|
||||
this.setMaxStackSize(1);
|
||||
this.setMaxDamage(64);
|
||||
this.setCreativeTab(MysticWorld.MysticWorldTab);
|
||||
}
|
||||
|
||||
public ItemStack onItemRightClick(ItemStack itemStack, World world, EntityPlayer entityPlayer)
|
||||
{
|
||||
world.playSoundEffect(entityPlayer.posX, entityPlayer.posY, entityPlayer.posZ, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F);
|
||||
|
||||
if (!world.isRemote)
|
||||
{
|
||||
itemStack.damageItem(1, entityPlayer);
|
||||
}
|
||||
|
||||
return itemStack;
|
||||
}
|
||||
|
||||
}
|
||||
32
common/MysticWorld/Items/ItemOrbWater.java
Normal file
32
common/MysticWorld/Items/ItemOrbWater.java
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
package MysticWorld.Items;
|
||||
|
||||
import MysticWorld.MysticWorld;
|
||||
import MysticWorld.Entity.EntityChargeAir;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.world.World;
|
||||
|
||||
public class ItemOrbWater extends Item {
|
||||
|
||||
public ItemOrbWater(int par1)
|
||||
{
|
||||
super(par1);
|
||||
this.setMaxStackSize(1);
|
||||
this.setMaxDamage(64);
|
||||
this.setCreativeTab(MysticWorld.MysticWorldTab);
|
||||
}
|
||||
|
||||
public ItemStack onItemRightClick(ItemStack itemStack, World world, EntityPlayer entityPlayer)
|
||||
{
|
||||
world.playSoundEffect(entityPlayer.posX, entityPlayer.posY, entityPlayer.posZ, "fire.ignite", 1.0F, itemRand.nextFloat() * 0.4F + 0.8F);
|
||||
|
||||
if (!world.isRemote)
|
||||
{
|
||||
itemStack.damageItem(1, entityPlayer);
|
||||
}
|
||||
|
||||
return itemStack;
|
||||
}
|
||||
|
||||
}
|
||||
Loading…
Reference in a new issue