Package net.minecraft.server

Examples of net.minecraft.server.PathEntity


      double z = location.getZ();
      if(!navigation.a(x, y, z, speed)) {
        int dx = MathUtil.floor(x);
        int dy = (int) y;
        int dz = MathUtil.floor(z);
        PathEntity path = nmsEntity.world.a(nmsEntity, dx, dy, dz, (float) this.getPathfindingRange(), true, false, false, true);
        this.moveWithPath(path, speed);
      }
    }
  }
View Full Code Here


    EntityLiving nmsEntity = CommonNMS.getNative(this.entity);
    net.minecraft.server.Entity nmsTargetEntity = CommonNMS.getNative(entity);
    if(nmsEntity instanceof EntityInsentient) {
      Navigation navigation = (Navigation) EntityLivingRef.getNavigation.invoke(nmsEntity);
      if(!navigation.a(nmsTargetEntity, speed)) {
        PathEntity path = nmsEntity.world.findPath(nmsEntity, nmsTargetEntity, (float) this.getPathfindingRange(), true, false, false, true);
        this.moveWithPath(path, speed);
      }
    }
  }
View Full Code Here

TOP

Related Classes of net.minecraft.server.PathEntity

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.