Joshie comment!

This commit is contained in:
WayofTime 2014-06-02 15:16:36 -04:00
parent 1c0deadfc6
commit ac943e9d38
753 changed files with 8715 additions and 1184 deletions

View file

@ -1,11 +1,7 @@
package WayofTime.alchemicalWizardry.common.items.sigil;
import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.api.items.interfaces.ArmourUpgrade;
import WayofTime.alchemicalWizardry.common.items.EnergyItems;
import WayofTime.alchemicalWizardry.common.spell.complex.effect.SpellHelper;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import java.util.List;
import net.minecraft.block.Block;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.entity.player.EntityPlayer;
@ -14,11 +10,20 @@ import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.potion.Potion;
import net.minecraft.potion.PotionEffect;
import net.minecraft.tileentity.TileEntity;
import net.minecraft.util.EnumMovingObjectType;
import net.minecraft.util.MovingObjectPosition;
import net.minecraft.world.World;
import java.util.List;
import net.minecraftforge.common.ForgeDirection;
import net.minecraftforge.fluids.FluidRegistry;
import net.minecraftforge.fluids.FluidStack;
import net.minecraftforge.fluids.IFluidHandler;
import WayofTime.alchemicalWizardry.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.api.items.interfaces.ArmourUpgrade;
import WayofTime.alchemicalWizardry.common.items.EnergyItems;
import WayofTime.alchemicalWizardry.common.spell.complex.effect.SpellHelper;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class WaterSigil extends ItemBucket implements ArmourUpgrade
{
@ -112,6 +117,26 @@ public class WaterSigil extends ItemBucket implements ArmourUpgrade
{
return par1ItemStack;
}
TileEntity tile = par2World.getBlockTileEntity(i, j, k);
if(tile instanceof IFluidHandler)
{
FluidStack fluid = new FluidStack(FluidRegistry.WATER,1000);
int amount = ((IFluidHandler) tile).fill(ForgeDirection.getOrientation(movingobjectposition.sideHit), fluid, false);
if(amount>0)
{
((IFluidHandler) tile).fill(ForgeDirection.getOrientation(movingobjectposition.sideHit), fluid, true);
if (!par3EntityPlayer.capabilities.isCreativeMode)
{
if (!EnergyItems.syphonBatteries(par1ItemStack, par3EntityPlayer, getEnergyUsed()))
{
}
}
}
return par1ItemStack;
}
if (this.isFull == 0)
{
@ -254,7 +279,7 @@ public class WaterSigil extends ItemBucket implements ArmourUpgrade
{
// TODO Auto-generated method stub
//PotionEffect effect = new PotionEffect(Potion.waterBreathing.id, 2,9);
player.addPotionEffect(new PotionEffect(Potion.waterBreathing.id, 2, 9));
player.addPotionEffect(new PotionEffect(Potion.waterBreathing.id, 2, 9,true));
}
@Override