mirror of
https://github.com/PaperMC/Paper.git
synced 2024-09-12 15:08:27 +02:00
SPIGOT-3142: Plugin event changes not using TeleportCause.PLUGIN
This commit is contained in:
parent
acf544e775
commit
31a852d619
@ -260,7 +260,7 @@
|
||||
+ // there to avoid any 'Moved wrongly' or 'Moved too quickly' errors.
|
||||
+ // We only do this if the Event was not cancelled.
|
||||
+ if (!oldTo.equals(event.getTo()) && !event.isCancelled()) {
|
||||
+ this.player.getBukkitEntity().teleport(event.getTo(), PlayerTeleportEvent.TeleportCause.UNKNOWN);
|
||||
+ this.player.getBukkitEntity().teleport(event.getTo(), PlayerTeleportEvent.TeleportCause.PLUGIN);
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
@ -397,7 +397,7 @@
|
||||
+ // there to avoid any 'Moved wrongly' or 'Moved too quickly' errors.
|
||||
+ // We only do this if the Event was not cancelled.
|
||||
+ if (!oldTo.equals(event.getTo()) && !event.isCancelled()) {
|
||||
+ this.player.getBukkitEntity().teleport(event.getTo(), PlayerTeleportEvent.TeleportCause.UNKNOWN);
|
||||
+ this.player.getBukkitEntity().teleport(event.getTo(), PlayerTeleportEvent.TeleportCause.PLUGIN);
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
|
Loading…
Reference in New Issue
Block a user