SPIGOT-4396: Improve vehicle movement

By: Aikar <aikar@aikar.co>
This commit is contained in:
CraftBukkit/Spigot
2018-09-26 17:19:16 +10:00
parent 5d8f320fb0
commit f1c24bbfa2
4 changed files with 115 additions and 65 deletions

View File

@@ -8,7 +8,15 @@
import java.util.Iterator;
import java.util.List;
import javax.annotation.Nullable;
@@ -67,22 +69,42 @@
@@ -29,6 +31,7 @@
this.locX = (double) this.blockPosition.getX() + 0.5D;
this.locY = (double) this.blockPosition.getY() + 0.5D;
this.locZ = (double) this.blockPosition.getZ() + 0.5D;
+ if (valid) world.entityJoinedWorld(this, false); // CraftBukkit
}
public void setDirection(EnumDirection enumdirection) {}
@@ -67,22 +70,42 @@
while (iterator.hasNext()) {
entityinsentient = (EntityInsentient) iterator.next();
if (entityinsentient.isLeashed() && entityinsentient.getLeashHolder() == entityhuman) {