Finished (almost) everything !items

This commit is contained in:
Arcaratus 2015-07-30 14:52:39 -04:00
parent 8eed901fcb
commit a9507b3b68
145 changed files with 1261 additions and 2156 deletions

View file

@ -17,8 +17,6 @@ import WayofTime.alchemicalWizardry.AlchemicalWizardry;
public class EntityBileDemon extends EntityDemon
{
public EntityBileDemon(World par1World)
{
super(par1World, AlchemicalWizardry.entityBileDemonID);

View file

@ -21,9 +21,6 @@ public class EntityBoulderFist extends EntityDemon
{
private EntityAIAttackOnCollide aiAttackOnCollide = new EntityAIAttackOnCollide(this, EntityPlayer.class, 1.2D, false);
private static float maxTamedHealth = 60.0F;
private static float maxUntamedHealth = 50.0F;
public EntityBoulderFist(World par1World)
{
super(par1World, AlchemicalWizardry.entityBoulderFistID);
@ -56,6 +53,8 @@ public class EntityBoulderFist extends EntityDemon
super.applyEntityAttributes();
//This line affects the speed of the monster
this.getEntityAttribute(SharedMonsterAttributes.movementSpeed).setBaseValue(0.30000001192092896D);
float maxTamedHealth = 60.0F;
float maxUntamedHealth = 50.0F;
//My guess is that this will alter the max health
if (this.isTamed())

View file

@ -9,7 +9,6 @@ import net.minecraft.entity.monster.EntityGhast;
import net.minecraft.entity.passive.EntityAnimal;
import net.minecraft.entity.passive.EntityHorse;
import net.minecraft.entity.passive.EntityTameable;
import net.minecraft.entity.passive.EntityWolf;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.entity.projectile.EntityArrow;
import net.minecraft.item.ItemFood;
@ -183,6 +182,7 @@ public class EntityDemon extends EntityTameable implements IDemon
}
}
@Override
/**
* main AI tick function, replaces updateEntityActionState
*/
@ -191,6 +191,7 @@ public class EntityDemon extends EntityTameable implements IDemon
this.dataWatcher.updateObject(18, this.getHealth());
}
@Override
protected void entityInit()
{
super.entityInit();
@ -207,6 +208,7 @@ public class EntityDemon extends EntityTameable implements IDemon
this.playSound("mob.zombie.step", 0.15F, 1.0F);
}
@Override
/**
* (abstract) Protected helper method to write subclass entity data to NBT.
*/
@ -217,6 +219,7 @@ public class EntityDemon extends EntityTameable implements IDemon
par1NBTTagCompound.setByte("attackTimer", (byte) attackTimer);
}
@Override
/**
* (abstract) Protected helper method to read subclass entity data from NBT.
*/
@ -228,6 +231,7 @@ public class EntityDemon extends EntityTameable implements IDemon
attackTimer = par1NBTTagCompound.getByte("attackTimer");
}
@Override
/**
* Returns the sound this mob makes while it's alive.
*/
@ -236,6 +240,7 @@ public class EntityDemon extends EntityTameable implements IDemon
return "none";
}
@Override
/**
* Returns the sound this mob makes when it is hurt.
*/
@ -244,6 +249,7 @@ public class EntityDemon extends EntityTameable implements IDemon
return "mob.irongolem.hit";
}
@Override
/**
* Returns the sound this mob makes on death.
*/
@ -252,6 +258,7 @@ public class EntityDemon extends EntityTameable implements IDemon
return "mob.irongolem.death";
}
@Override
/**
* Returns the volume for the sounds this mob makes.
*/
@ -273,6 +280,7 @@ public class EntityDemon extends EntityTameable implements IDemon
return attackTimer;
}
@Override
/**
* Called to update the entity's position/logic.
*/
@ -281,11 +289,13 @@ public class EntityDemon extends EntityTameable implements IDemon
super.onUpdate();
}
@Override
public float getEyeHeight()
{
return this.height * 0.8F;
}
@Override
/**
* The speed it takes to move the entityliving's rotationPitch through the faceEntity method. This is only currently
* use in wolves.
@ -295,6 +305,7 @@ public class EntityDemon extends EntityTameable implements IDemon
return this.isSitting() ? 20 : super.getVerticalFaceSpeed();
}
@Override
/**
* Called when the entity is attacked.
*/
@ -317,6 +328,7 @@ public class EntityDemon extends EntityTameable implements IDemon
}
}
@Override
public boolean attackEntityAsMob(Entity par1Entity)
{
this.attackTimer = 10;
@ -332,6 +344,7 @@ public class EntityDemon extends EntityTameable implements IDemon
return flag;
}
@Override
public void setTamed(boolean par1)
{
super.setTamed(par1);
@ -402,7 +415,7 @@ public class EntityDemon extends EntityTameable implements IDemon
if (itemstack.stackSize <= 0)
{
par1EntityPlayer.inventory.setInventorySlotContents(par1EntityPlayer.inventory.currentItem, (ItemStack) null);
par1EntityPlayer.inventory.setInventorySlotContents(par1EntityPlayer.inventory.currentItem, null);
}
if (!this.worldObj.isRemote)
@ -463,41 +476,7 @@ public class EntityDemon extends EntityTameable implements IDemon
}
}
/**
* Return this wolf's collar color.
*/
public int getCollarColor()
{
return this.dataWatcher.getWatchableObjectByte(20) & 15;
}
/**
* Set this wolf's collar color.
*/
public void setCollarColor(int par1)
{
this.dataWatcher.updateObject(20, par1 & 15);
}
/**
* This function is used when two same-species animals in 'love mode' breed to generate the new baby animal.
*/
public EntityWolf spawnBabyAnimal(EntityAgeable par1EntityAgeable)
{
return null;
}
public void func_70918_i(boolean par1)
{
if (par1)
{
this.dataWatcher.updateObject(19, 1);
} else
{
this.dataWatcher.updateObject(19, 0);
}
}
@Override
/**
* Returns true if the mob is currently able to mate with the specified mob.
*/
@ -511,6 +490,7 @@ public class EntityDemon extends EntityTameable implements IDemon
return this.dataWatcher.getWatchableObjectByte(19) == 1;
}
@Override
/**
* Determines if an entity can be despawned, used on idle far away entities
*/

View file

@ -45,19 +45,20 @@ public class EntityElemental extends EntityDemon
}
}
public int courseChangeCooldown;
// public int courseChangeCooldown;
public double waypointX;
public double waypointY;
public double waypointZ;
private Entity targetedEntity;
/* private Entity targetedEntity;
/**
* Cooldown time between target loss and new target aquirement.
*/
private int aggroCooldown;
public int prevAttackCounter;
public int attackCounter;
*/
@Override
/**
* The explosion radius of spawned fireballs.
*/
@ -69,18 +70,7 @@ public class EntityElemental extends EntityDemon
}
}
protected void fall(float par1)
{
}
/**
* Takes in the distance the entity has fallen this tick and whether its on the ground to update the fall distance
* and deal fall damage if landing on the ground. Args: distanceFallenThisTick, onGround
*/
protected void updateFallState(double par1, boolean par3)
{
}
@Override
/**
* Moves the entity based on the specified heading. Args: strafe, forward
*/
@ -140,6 +130,7 @@ public class EntityElemental extends EntityDemon
this.limbSwing += this.limbSwingAmount;
}
@Override
/**
* returns true if this entity is by a ladder, false otherwise
*/
@ -177,6 +168,7 @@ public class EntityElemental extends EntityDemon
return true;
}
@Override
/**
* Will return how many at most can spawn in a chunk at once.
*/
@ -185,6 +177,7 @@ public class EntityElemental extends EntityDemon
return 1;
}
@Override
/**
* (abstract) Protected helper method to write subclass entity data to NBT.
*/
@ -193,6 +186,7 @@ public class EntityElemental extends EntityDemon
super.writeEntityToNBT(par1NBTTagCompound);
}
@Override
/**
* (abstract) Protected helper method to read subclass entity data from NBT.
*/
@ -221,6 +215,7 @@ public class EntityElemental extends EntityDemon
}
}
@Override
/**
* Returns true if the newer Entity AI code should be run
*/
@ -229,6 +224,7 @@ public class EntityElemental extends EntityDemon
return false;
}
@Override
/**
* Sets the active target the Task system uses for tracking
*/
@ -245,6 +241,7 @@ public class EntityElemental extends EntityDemon
}
}
@Override
/**
* main AI tick function, replaces updateEntityActionState
*/
@ -253,6 +250,7 @@ public class EntityElemental extends EntityDemon
this.dataWatcher.updateObject(18, this.getHealth());
}
@Override
protected void entityInit()
{
super.entityInit();
@ -261,6 +259,7 @@ public class EntityElemental extends EntityDemon
this.dataWatcher.addObject(25, 0);
}
@Override
/**
* Plays step sound at given x, y, z for the entity
*/
@ -269,6 +268,7 @@ public class EntityElemental extends EntityDemon
this.playSound("mob.zombie.step", 0.15F, 1.0F);
}
@Override
/**
* Returns the sound this mob makes while it's alive.
*/
@ -278,6 +278,7 @@ public class EntityElemental extends EntityDemon
return "none";
}
@Override
/**
* Returns the sound this mob makes when it is hurt.
*/
@ -286,6 +287,7 @@ public class EntityElemental extends EntityDemon
return "none";
}
@Override
/**
* Returns the sound this mob makes on death.
*/
@ -294,6 +296,7 @@ public class EntityElemental extends EntityDemon
return "none";
}
@Override
/**
* Returns the volume for the sounds this mob makes.
*/
@ -302,6 +305,7 @@ public class EntityElemental extends EntityDemon
return 0.4F;
}
@Override
/**
* Returns the item ID for the item the mob drops on death.
*/
@ -310,6 +314,7 @@ public class EntityElemental extends EntityDemon
return -1;
}
@Override
/**
* Called to update the entity's position/logic.
*/
@ -323,11 +328,13 @@ public class EntityElemental extends EntityDemon
}
}
@Override
public float getEyeHeight()
{
return this.height * 0.8F;
}
@Override
/**
* The speed it takes to move the entityliving's rotationPitch through the faceEntity method. This is only currently
* use in wolves.
@ -337,6 +344,7 @@ public class EntityElemental extends EntityDemon
return this.isSitting() ? 20 : super.getVerticalFaceSpeed();
}
@Override
/**
* Called when the entity is attacked.
*/
@ -359,12 +367,14 @@ public class EntityElemental extends EntityDemon
}
}
@Override
public boolean attackEntityAsMob(Entity par1Entity)
{
int i = this.isTamed() ? 6 : 7;
return par1Entity.attackEntityFrom(DamageSource.causeMobDamage(this), (float) i);
}
@Override
public void setTamed(boolean par1)
{
super.setTamed(par1);
@ -378,10 +388,7 @@ public class EntityElemental extends EntityDemon
}
}
/**
* Called when a player interacts with a mob. e.g. gets milk from a cow, gets into the saddle on a pig.
*/
@Override
/**
* Checks if the parameter is an item which this animal can be fed to breed it (wheat, carrots or seeds depending on
* the animal type)
@ -391,6 +398,7 @@ public class EntityElemental extends EntityDemon
return false;
}
@Override
/**
* Determines whether this wolf is angry or not.
*/
@ -399,6 +407,7 @@ public class EntityElemental extends EntityDemon
return (this.dataWatcher.getWatchableObjectByte(16) & 2) != 0;
}
@Override
/**
* Sets whether this wolf is angry or not.
*/
@ -426,6 +435,7 @@ public class EntityElemental extends EntityDemon
}
}
@Override
/**
* Returns true if the mob is currently able to mate with the specified mob.
*/
@ -434,11 +444,13 @@ public class EntityElemental extends EntityDemon
return false;
}
@Override
public boolean func_70922_bv()
{
return this.dataWatcher.getWatchableObjectByte(19) == 1;
}
@Override
/**
* Determines if an entity can be despawned, used on idle far away entities
*/

View file

@ -25,9 +25,6 @@ public class EntityFallenAngel extends EntityDemon implements IRangedAttackMob
private EntityAIArrowAttack aiArrowAttack = new EntityAIArrowAttack(this, 1.0D, 40, 40, 15.0F);
private EntityAIAttackOnCollide aiAttackOnCollide = new EntityAIAttackOnCollide(this, EntityPlayer.class, 1.2D, false);
private static float maxTamedHealth = 50.0F;
private static float maxUntamedHealth = 50.0F;
public EntityFallenAngel(World par1World)
{
super(par1World, AlchemicalWizardry.entityFallenAngelID);
@ -60,6 +57,8 @@ public class EntityFallenAngel extends EntityDemon implements IRangedAttackMob
super.applyEntityAttributes();
//This line affects the speed of the monster
this.getEntityAttribute(SharedMonsterAttributes.movementSpeed).setBaseValue(0.30000001192092896D);
float maxTamedHealth = 50.0F;
float maxUntamedHealth = 50.0F;
//My guess is that this will alter the max health
if (this.isTamed())

View file

@ -15,6 +15,7 @@ public class EntityFireElemental extends EntityElemental implements IMob
this.isImmuneToFire = true;
}
@Override
public void inflictEffectOnEntity(Entity target)
{
if (target instanceof EntityLivingBase)

View file

@ -16,6 +16,7 @@ public class EntityHolyElemental extends EntityElemental implements IMob
super(world, AlchemicalWizardry.entityHolyElementalID);
}
@Override
public void inflictEffectOnEntity(Entity target)
{
if (target instanceof EntityLivingBase)

View file

@ -24,9 +24,6 @@ public class EntityIceDemon extends EntityDemon implements IRangedAttackMob
private EntityAIArrowAttack aiArrowAttack = new EntityAIArrowAttack(this, 1.0D, 30, 50, 15.0F);
private EntityAIAttackOnCollide aiAttackOnCollide = new EntityAIAttackOnCollide(this, EntityPlayer.class, 1.2D, false);
private static float maxTamedHealth = 50.0F;
private static float maxUntamedHealth = 30.0F;
public EntityIceDemon(World par1World)
{
super(par1World, AlchemicalWizardry.entityIceDemonID);
@ -56,6 +53,8 @@ public class EntityIceDemon extends EntityDemon implements IRangedAttackMob
super.applyEntityAttributes();
//This line affects the speed of the monster
this.getEntityAttribute(SharedMonsterAttributes.movementSpeed).setBaseValue(0.40000001192092896D);
float maxTamedHealth = 50.0F;
float maxUntamedHealth = 30.0F;
//My guess is that this will alter the max health
if (this.isTamed())
@ -67,6 +66,7 @@ public class EntityIceDemon extends EntityDemon implements IRangedAttackMob
}
}
@Override
/**
* Attack the specified entity using a ranged attack.
*/

View file

@ -19,10 +19,6 @@ import WayofTime.alchemicalWizardry.common.EntityAITargetAggro;
public class EntityLowerGuardian extends EntityDemon
{
private static float maxTamedHealth = 50.0F;
private static float maxUntamedHealth = 30.0F;
private int attackTimer;
public EntityLowerGuardian(World par1World)
{
super(par1World, AlchemicalWizardry.entityLowerGuardianID);
@ -41,7 +37,6 @@ public class EntityLowerGuardian extends EntityDemon
this.targetTasks.addTask(4, new EntityAITargetAggro(this, EntityPlayer.class, 0, false));
this.setAggro(false);
this.setTamed(false);
attackTimer = 0;
}
@Override
@ -50,6 +45,8 @@ public class EntityLowerGuardian extends EntityDemon
super.applyEntityAttributes();
//This line affects the speed of the monster
this.getEntityAttribute(SharedMonsterAttributes.movementSpeed).setBaseValue(0.30000001192092896D);
float maxTamedHealth = 50.0F;
float maxUntamedHealth = 30.0F;
//My guess is that this will alter the max health
if (this.isTamed())
@ -61,8 +58,10 @@ public class EntityLowerGuardian extends EntityDemon
}
}
public EntityAgeable createChild(EntityAgeable par1EntityAgeable)
/* public EntityAgeable createChild(EntityAgeable par1EntityAgeable)
{
return this.spawnBabyAnimal(par1EntityAgeable);
}
I don't know what this method changed to
*/
}

View file

@ -22,9 +22,6 @@ public class EntityShade extends EntityDemon
{
private EntityAIAttackOnCollide aiAttackOnCollide = new EntityAIAttackOnCollide(this, EntityPlayer.class, 1.2D, false);
private static float maxTamedHealth = 50.0F;
private static float maxUntamedHealth = 100.0F;
public EntityShade(World par1World)
{
super(par1World, AlchemicalWizardry.entityShadeID);
@ -56,6 +53,8 @@ public class EntityShade extends EntityDemon
super.applyEntityAttributes();
//This line affects the speed of the monster
this.getEntityAttribute(SharedMonsterAttributes.movementSpeed).setBaseValue(0.30000001192092896D);
float maxTamedHealth = 50.0F;
float maxUntamedHealth = 100.0F;
//My guess is that this will alter the max health
if (this.isTamed())

View file

@ -15,6 +15,7 @@ public class EntityShadeElemental extends EntityElemental implements IMob
super(world, AlchemicalWizardry.entityShadeElementalID);
}
@Override
public void inflictEffectOnEntity(Entity target)
{
if (target instanceof EntityLivingBase)

View file

@ -25,9 +25,6 @@ public class EntitySmallEarthGolem extends EntityDemon implements IRangedAttackM
private EntityAIArrowAttack aiArrowAttack = new EntityAIArrowAttack(this, 1.0D, 25, 25, 15.0F);
private EntityAIAttackOnCollide aiAttackOnCollide = new EntityAIAttackOnCollide(this, EntityPlayer.class, 1.2D, false);
private static float maxTamedHealth = 20.0F;
private static float maxUntamedHealth = 10.0F;
public EntitySmallEarthGolem(World par1World)
{
super(par1World, AlchemicalWizardry.entitySmallEarthGolemID);
@ -58,6 +55,8 @@ public class EntitySmallEarthGolem extends EntityDemon implements IRangedAttackM
super.applyEntityAttributes();
//This line affects the speed of the monster
this.getEntityAttribute(SharedMonsterAttributes.movementSpeed).setBaseValue(0.40000001192092896D);
float maxTamedHealth = 20.0F;
float maxUntamedHealth = 10.0F;
//My guess is that this will alter the max health
if (this.isTamed())
@ -68,7 +67,8 @@ public class EntitySmallEarthGolem extends EntityDemon implements IRangedAttackM
this.getEntityAttribute(SharedMonsterAttributes.maxHealth).setBaseValue(maxUntamedHealth);
}
}
@Override
/**
* Attack the specified entity using a ranged attack.
*/

View file

@ -14,6 +14,7 @@ public class EntityWaterElemental extends EntityElemental implements IMob
super(world, AlchemicalWizardry.entityWaterElementalID);
}
@Override
public void inflictEffectOnEntity(Entity target)
{
if (target instanceof EntityLivingBase)

View file

@ -25,9 +25,6 @@ public class EntityWingedFireDemon extends EntityDemon implements IRangedAttackM
private EntityAIArrowAttack aiArrowAttack = new EntityAIArrowAttack(this, 1.0D, 40, 40, 15.0F);
private EntityAIAttackOnCollide aiAttackOnCollide = new EntityAIAttackOnCollide(this, EntityPlayer.class, 1.2D, false);
private static float maxTamedHealth = 100.0F;
private static float maxUntamedHealth = 200.0F;
public EntityWingedFireDemon(World par1World)
{
super(par1World, AlchemicalWizardry.entityWingedFireDemonID);
@ -60,6 +57,8 @@ public class EntityWingedFireDemon extends EntityDemon implements IRangedAttackM
super.applyEntityAttributes();
//This line affects the speed of the monster
this.getEntityAttribute(SharedMonsterAttributes.movementSpeed).setBaseValue(0.30000001192092896D);
float maxTamedHealth = 100.0F;
float maxUntamedHealth = 200.0F;
//My guess is that this will alter the max health
if (this.isTamed())
@ -73,6 +72,7 @@ public class EntityWingedFireDemon extends EntityDemon implements IRangedAttackM
//this.func_110148_a(SharedMonsterAttributes.field_111267_a).func_111128_a(10.0D);
}
@Override
/**
* Attack the specified entity using a ranged attack.
*/