Massive rework of configs, items and blocks.

I redone where the items/blocsks are stored and how the configs are
handled to clean up it and give space. You can change the config line to
AWWayofTime if you want to keep the compatibility with old configs. Now
you reference the blocks from the ModBlocks and Items from the ModItems.
This commit is contained in:
Fenn 2014-01-17 21:05:38 +00:00
parent 8601e9faff
commit e3644f2d2b
304 changed files with 3941 additions and 5108 deletions

View file

@ -1,7 +1,11 @@
package WayofTime.alchemicalWizardry.common.items.sigil;
import java.util.List;
import WayofTime.alchemicalWizardry.common.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.common.ArmourUpgrade;
import WayofTime.alchemicalWizardry.common.items.EnergyBattery;
import WayofTime.alchemicalWizardry.common.items.EnergyItems;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import net.minecraft.block.Block;
import net.minecraft.client.renderer.texture.IconRegister;
import net.minecraft.entity.player.EntityPlayer;
@ -13,16 +17,13 @@ import net.minecraft.potion.PotionEffect;
import net.minecraft.util.EnumMovingObjectType;
import net.minecraft.util.MovingObjectPosition;
import net.minecraft.world.World;
import WayofTime.alchemicalWizardry.common.AlchemicalWizardry;
import WayofTime.alchemicalWizardry.common.ArmourUpgrade;
import WayofTime.alchemicalWizardry.common.items.EnergyBattery;
import WayofTime.alchemicalWizardry.common.items.EnergyItems;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class LavaSigil extends ItemBucket implements ArmourUpgrade
{
/** field for checking if the bucket has been filled. */
import java.util.List;
public class LavaSigil extends ItemBucket implements ArmourUpgrade {
/**
* field for checking if the bucket has been filled.
*/
private int isFull = Block.lavaMoving.blockID;
private int energyUsed;
@ -76,17 +77,16 @@ public class LavaSigil extends ItemBucket implements ArmourUpgrade
}
float f = 1.0F;
double d0 = par3EntityPlayer.prevPosX + (par3EntityPlayer.posX - par3EntityPlayer.prevPosX) * (double)f;
double d1 = par3EntityPlayer.prevPosY + (par3EntityPlayer.posY - par3EntityPlayer.prevPosY) * (double)f + 1.62D - (double)par3EntityPlayer.yOffset;
double d2 = par3EntityPlayer.prevPosZ + (par3EntityPlayer.posZ - par3EntityPlayer.prevPosZ) * (double)f;
double d0 = par3EntityPlayer.prevPosX + (par3EntityPlayer.posX - par3EntityPlayer.prevPosX) * (double) f;
double d1 = par3EntityPlayer.prevPosY + (par3EntityPlayer.posY - par3EntityPlayer.prevPosY) * (double) f + 1.62D - (double) par3EntityPlayer.yOffset;
double d2 = par3EntityPlayer.prevPosZ + (par3EntityPlayer.posZ - par3EntityPlayer.prevPosZ) * (double) f;
boolean flag = this.isFull == 0;
MovingObjectPosition movingobjectposition = this.getMovingObjectPositionFromPlayer(par2World, par3EntityPlayer, flag);
if (movingobjectposition == null)
{
return par1ItemStack;
}
else
} else
{
if (movingobjectposition.typeOfHit == EnumMovingObjectType.TILE)
{
@ -102,8 +102,7 @@ public class LavaSigil extends ItemBucket implements ArmourUpgrade
if (this.isFull == 0)
{
//Empty
}
else
} else
{
if (movingobjectposition.sideHit == 0)
{
@ -147,8 +146,7 @@ public class LavaSigil extends ItemBucket implements ArmourUpgrade
if (!EnergyItems.syphonBatteries(par1ItemStack, par3EntityPlayer, getEnergyUsed()))
{
}
}
else
} else
{
return par1ItemStack;
}
@ -168,16 +166,13 @@ public class LavaSigil extends ItemBucket implements ArmourUpgrade
if (this.isFull <= 0)
{
return false;
}
else if (!par1World.isAirBlock(par8, par9, par10) && par1World.getBlockMaterial(par8, par9, par10).isSolid())
} else if (!par1World.isAirBlock(par8, par9, par10) && par1World.getBlockMaterial(par8, par9, par10).isSolid())
{
return false;
}
else if ((par1World.getBlockId(par8, par9, par10) == Block.lavaMoving.blockID || par1World.getBlockId(par8, par9, par10) == Block.lavaStill.blockID) && par1World.getBlockMetadata(par8, par9, par10) == 0)
} else if ((par1World.getBlockId(par8, par9, par10) == Block.lavaMoving.blockID || par1World.getBlockId(par8, par9, par10) == Block.lavaStill.blockID) && par1World.getBlockMetadata(par8, par9, par10) == 0)
{
return false;
}
else
} else
{
par1World.setBlock(par8, par9, par10, this.isFull, 0, 3);
return true;
@ -196,7 +191,7 @@ public class LavaSigil extends ItemBucket implements ArmourUpgrade
//Heals the player using the item. If the player is at full health, or if the durability cannot be used any more,
//the item is not used.
// protected void damagePlayer(World world, EntityPlayer player, int damage)
// protected void damagePlayer(World world, EntityPlayer player, int damage)
// {
// if (world != null)
// {
@ -258,8 +253,7 @@ public class LavaSigil extends ItemBucket implements ArmourUpgrade
}
return true;
}
else
} else
{
return true;
}