/**
  * finds a random target within par1(x,z) and par2 (y) blocks in the reverse direction of the
  * point par3
  */
 public static Vec3 findRandomTargetBlockAwayFrom(
     EntityCreature par0EntityCreature, int par1, int par2, Vec3 par3Vec3) {
   staticVector.xCoord = par0EntityCreature.posX - par3Vec3.xCoord;
   staticVector.yCoord = par0EntityCreature.posY - par3Vec3.yCoord;
   staticVector.zCoord = par0EntityCreature.posZ - par3Vec3.zCoord;
   return findRandomTargetBlock(par0EntityCreature, par1, par2, staticVector);
 }
Beispiel #2
0
 /**
  * Can add to the passed in vector for a movement vector to be applied to the entity. Args: x, y,
  * z, entity, vec3d
  */
 public void velocityToAddToEntity(
     World par1World, int par2, int par3, int par4, Entity par5Entity, Vec3 par6Vec3) {
   Vec3 var7 = this.getFlowVector(par1World, par2, par3, par4);
   par6Vec3.xCoord += var7.xCoord;
   par6Vec3.yCoord += var7.yCoord;
   par6Vec3.zCoord += var7.zCoord;
 }
 /**
  * finds a random target within par1(x,z) and par2 (y) blocks in the direction of the point par3
  */
 public static Vec3 findRandomTargetBlockTowards(
     EntityCreature par0EntityCreature, int par1, int par2, Vec3 par3Vec3) {
   staticVector.xCoord = par3Vec3.xCoord - par0EntityCreature.posX;
   staticVector.yCoord = par3Vec3.yCoord - par0EntityCreature.posY;
   staticVector.zCoord = par3Vec3.zCoord - par0EntityCreature.posZ;
   return findRandomTargetBlock(par0EntityCreature, par1, par2, staticVector);
 }