mirror of
https://github.com/AtlasMediaGroup/TotalFreedomMod.git
synced 2025-07-01 20:46:41 +00:00
Update NMS + Use PaperLib for teleportAsync
This commit is contained in:
@ -1,5 +1,6 @@
|
||||
package me.totalfreedom.totalfreedommod;
|
||||
|
||||
import io.papermc.lib.PaperLib;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import java.util.regex.Pattern;
|
||||
@ -197,7 +198,7 @@ public class LoginProcess extends FreedomService
|
||||
int z = FUtil.randomInteger(-10000, 10000);
|
||||
int y = player.getWorld().getHighestBlockYAt(x, z);
|
||||
Location location = new Location(player.getLocation().getWorld(), x, y, z);
|
||||
player.teleport(location);
|
||||
PaperLib.teleportAsync(player, location);
|
||||
player.sendMessage(ChatColor.AQUA + "You have been teleported to a random location automatically.");
|
||||
return;
|
||||
}
|
||||
|
Reference in New Issue
Block a user