示例#1
0
 private void initiateEntityPet() {
   this.setSize();
   this.fireProof = true;
   if (this.FIELD_JUMP == null) {
     try {
       this.FIELD_JUMP = EntityLiving.class.getDeclaredField("bd");
       this.FIELD_JUMP.setAccessible(true);
     } catch (NoSuchFieldException e) {
       e.printStackTrace();
     }
   }
   this.getBukkitEntity().setMaxHealth(pet.getPetType().getMaxHealth());
   this.setHealth((float) pet.getPetType().getMaxHealth());
   this.jumpHeight = EchoPet.getOptions().getRideJumpHeight(this.getPet().getPetType());
   this.rideSpeed = EchoPet.getOptions().getRideSpeed(this.getPet().getPetType());
   this.setPathfinding();
 }
示例#2
0
 public Player getPlayerOwner() {
   return pet.getOwner();
 }