Remove useless stuff
This commit is contained in:
parent
338d0c20e7
commit
0cd1169e50
8 changed files with 6 additions and 14 deletions
|
|
@ -1,7 +1,5 @@
|
||||||
package mysticworld.items;
|
package mysticworld.items;
|
||||||
|
|
||||||
import java.util.Random;
|
|
||||||
|
|
||||||
import cpw.mods.fml.relauncher.Side;
|
import cpw.mods.fml.relauncher.Side;
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
|
|
@ -10,8 +8,6 @@ import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.item.Item;
|
import net.minecraft.item.Item;
|
||||||
|
|
||||||
public class ItemOrb extends Item {
|
public class ItemOrb extends Item {
|
||||||
Random rand = new Random();
|
|
||||||
|
|
||||||
public ItemOrb() {
|
public ItemOrb() {
|
||||||
super();
|
super();
|
||||||
this.setMaxStackSize(1);
|
this.setMaxStackSize(1);
|
||||||
|
|
|
||||||
|
|
@ -53,7 +53,7 @@ public class ItemOrbEnergy extends ItemOrb {
|
||||||
public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) {
|
public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) {
|
||||||
if (entity instanceof EntityPlayer && par5) {
|
if (entity instanceof EntityPlayer && par5) {
|
||||||
((EntityPlayer)entity).addPotionEffect(new PotionEffect(Potion.moveSpeed.getId(), 20, 2));
|
((EntityPlayer)entity).addPotionEffect(new PotionEffect(Potion.moveSpeed.getId(), 20, 2));
|
||||||
MysticWorld.proxy.energyFX(world, (entity.posX - 0.5D) + rand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + rand.nextDouble(), 1.0F);
|
MysticWorld.proxy.energyFX(world, (entity.posX - 0.5D) + itemRand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + itemRand.nextDouble(), 1.0F);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -68,7 +68,7 @@ public class ItemOrbFire extends ItemOrb {
|
||||||
public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) {
|
public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) {
|
||||||
if (entity instanceof EntityPlayer && par5) {
|
if (entity instanceof EntityPlayer && par5) {
|
||||||
((EntityPlayer)entity).addPotionEffect(new PotionEffect(Potion.fireResistance.getId(), 20, 0));
|
((EntityPlayer)entity).addPotionEffect(new PotionEffect(Potion.fireResistance.getId(), 20, 0));
|
||||||
MysticWorld.proxy.fireFX(world, (entity.posX - 0.5D) + rand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + rand.nextDouble(), 1.0F);
|
MysticWorld.proxy.fireFX(world, (entity.posX - 0.5D) + itemRand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + itemRand.nextDouble(), 1.0F);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -75,7 +75,7 @@ public class ItemOrbWater extends ItemOrb {
|
||||||
@Override
|
@Override
|
||||||
public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) {
|
public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) {
|
||||||
if (par5) {
|
if (par5) {
|
||||||
MysticWorld.proxy.waterFX(world, (entity.posX - 0.5D) + rand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + rand.nextDouble(), 1.0F);
|
MysticWorld.proxy.waterFX(world, (entity.posX - 0.5D) + itemRand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + itemRand.nextDouble(), 1.0F);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,5 @@
|
||||||
package mysticworld.items;
|
package mysticworld.items;
|
||||||
|
|
||||||
import java.util.Random;
|
|
||||||
|
|
||||||
import mysticworld.MysticWorld;
|
import mysticworld.MysticWorld;
|
||||||
import net.minecraft.client.renderer.texture.IIconRegister;
|
import net.minecraft.client.renderer.texture.IIconRegister;
|
||||||
import net.minecraft.item.Item;
|
import net.minecraft.item.Item;
|
||||||
|
|
@ -9,8 +7,6 @@ import cpw.mods.fml.relauncher.Side;
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
|
|
||||||
public class ItemStaff extends Item {
|
public class ItemStaff extends Item {
|
||||||
Random rand = new Random();
|
|
||||||
|
|
||||||
public ItemStaff() {
|
public ItemStaff() {
|
||||||
super();
|
super();
|
||||||
this.setMaxStackSize(1);
|
this.setMaxStackSize(1);
|
||||||
|
|
|
||||||
|
|
@ -79,7 +79,7 @@ public class ItemStaffEnegy extends ItemStaff {
|
||||||
public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) {
|
public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) {
|
||||||
if (entity instanceof EntityPlayer && par5) {
|
if (entity instanceof EntityPlayer && par5) {
|
||||||
((EntityPlayer)entity).addPotionEffect(new PotionEffect(Potion.moveSpeed.getId(), 20, 2));
|
((EntityPlayer)entity).addPotionEffect(new PotionEffect(Potion.moveSpeed.getId(), 20, 2));
|
||||||
MysticWorld.proxy.energyFX(world, (entity.posX - 0.5D) + rand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + rand.nextDouble(), 1.0F);
|
MysticWorld.proxy.energyFX(world, (entity.posX - 0.5D) + itemRand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + itemRand.nextDouble(), 1.0F);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -83,7 +83,7 @@ public class ItemStaffFire extends ItemStaff {
|
||||||
public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) {
|
public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) {
|
||||||
if (entity instanceof EntityPlayer && par5) {
|
if (entity instanceof EntityPlayer && par5) {
|
||||||
((EntityPlayer)entity).addPotionEffect(new PotionEffect(Potion.fireResistance.getId(), 20, 0));
|
((EntityPlayer)entity).addPotionEffect(new PotionEffect(Potion.fireResistance.getId(), 20, 0));
|
||||||
MysticWorld.proxy.fireFX(world, (entity.posX - 0.5D) + rand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + rand.nextDouble(), 1.0F);
|
MysticWorld.proxy.fireFX(world, (entity.posX - 0.5D) + itemRand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + itemRand.nextDouble(), 1.0F);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -88,7 +88,7 @@ public class ItemStaffWater extends ItemStaff {
|
||||||
@Override
|
@Override
|
||||||
public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) {
|
public void onUpdate(ItemStack itemStack, World world, Entity entity, int par4, boolean par5) {
|
||||||
if (par5) {
|
if (par5) {
|
||||||
MysticWorld.proxy.waterFX(world, (entity.posX - 0.5D) + rand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + rand.nextDouble(), 1.0F);
|
MysticWorld.proxy.waterFX(world, (entity.posX - 0.5D) + itemRand.nextDouble(), entity.posY, (entity.posZ - 0.5D) + itemRand.nextDouble(), 1.0F);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Loading…
Reference in a new issue