mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-27 13:06:02 +01:00
Always use the set exit location for portal events. Fixes BUKKIT-3555.
This commit is contained in:
parent
94da64ee93
commit
d661c67a70
@ -1771,7 +1771,7 @@ public abstract class Entity {
|
||||
if (event.isCancelled() || event.getTo() == null || !this.isAlive()) {
|
||||
return;
|
||||
}
|
||||
exit = event.useTravelAgent() ? event.getPortalTravelAgent().findOrCreate(exit) : event.getTo();
|
||||
exit = event.useTravelAgent() ? event.getPortalTravelAgent().findOrCreate(event.getTo()) : event.getTo();
|
||||
this.teleportTo(exit, true);
|
||||
}
|
||||
}
|
||||
|
@ -459,7 +459,7 @@ public abstract class PlayerList {
|
||||
return;
|
||||
}
|
||||
|
||||
exit = event.useTravelAgent() ? event.getPortalTravelAgent().findOrCreate(exit) : event.getTo();
|
||||
exit = event.useTravelAgent() ? event.getPortalTravelAgent().findOrCreate(event.getTo()) : event.getTo();
|
||||
exitWorld = ((CraftWorld) exit.getWorld()).getHandle();
|
||||
|
||||
Vector velocity = entityplayer.getBukkitEntity().getVelocity();
|
||||
|
Loading…
Reference in New Issue
Block a user