more notes
This commit is contained in:
@@ -126,6 +126,8 @@ public class Bot extends EntityPlayer {
|
||||
}
|
||||
|
||||
private void updateLocation() {
|
||||
// Eventually there will be a whole algorithm here to slow a player down to a certain velocity depending on the liquid a player is in
|
||||
|
||||
velocity.setY(velocity.getY() - 0.1);
|
||||
|
||||
double y;
|
||||
@@ -181,15 +183,6 @@ public class Bot extends EntityPlayer {
|
||||
velocity.setZ(velocity.getZ() * 0.5);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void die() {
|
||||
super.die();
|
||||
for (Player player : Bukkit.getOnlinePlayers()) {
|
||||
PlayerConnection connection = ((CraftPlayer) player).getHandle().playerConnection;
|
||||
connection.sendPacket(new PacketPlayOutPlayerInfo(PacketPlayOutPlayerInfo.EnumPlayerInfoAction.REMOVE_PLAYER, this));
|
||||
}
|
||||
}
|
||||
|
||||
public void despawn() {
|
||||
getBukkitEntity().remove();
|
||||
}
|
||||
@@ -254,6 +247,10 @@ public class Bot extends EntityPlayer {
|
||||
kbTicks = 10;
|
||||
}
|
||||
|
||||
public Location getLocation() {
|
||||
return getBukkitEntity().getLocation();
|
||||
}
|
||||
|
||||
public void faceLocation(Location loc) {
|
||||
try {
|
||||
CraftPlayer playerBot = this.getBukkitEntity();
|
||||
|
||||
Reference in New Issue
Block a user