Fork of Poseidon providing Bukkit #1060 to older Beta versions (b1.0-b1.7.3)
1package net.minecraft.server;
2
3public class PathEntity {
4
5 private final PathPoint[] b;
6 public final int a;
7 private int c;
8
9 public PathEntity(PathPoint[] apathpoint) {
10 this.b = apathpoint;
11 this.a = apathpoint.length;
12 }
13
14 public void a() {
15 ++this.c;
16 }
17
18 public boolean b() {
19 return this.c >= this.b.length;
20 }
21
22 public PathPoint c() {
23 return this.a > 0 ? this.b[this.a - 1] : null;
24 }
25
26 public Vec3D a(Entity entity) {
27 double d0 = (double) this.b[this.c].a + (double) ((int) (entity.length + 1.0F)) * 0.5D;
28 double d1 = (double) this.b[this.c].b;
29 double d2 = (double) this.b[this.c].c + (double) ((int) (entity.length + 1.0F)) * 0.5D;
30
31 return Vec3D.create(d0, d1, d2);
32 }
33}