Fix timed teleport being used in some cases where it shouldn't

This commit is contained in:
William committed 2022-08-25 17:14:49 +01:00
1 parent 327c798f6e
commit f77d9adf27
6 files changed
+37 -30

No files matched your search

@@ -24,7 +24,7 @@ public class TpHereCommand extends CommandBase implements TabCompletable {
return;
}
final String targetPlayerName = args[0];
plugin.getTeleportManager().teleportPlayerByName(targetPlayerName, onlineUser.getPosition(), onlineUser)
plugin.getTeleportManager().teleportPlayerByName(targetPlayerName, onlineUser.getPosition(), onlineUser, false)
.thenAccept(resultIfPlayerExists -> resultIfPlayerExists.ifPresentOrElse(
result -> {
if (result.successful) {