mirror of
https://github.com/AtlasMediaGroup/TotalFreedomMod.git
synced 2024-11-17 21:06:11 +00:00
command void issue is no more
This commit is contained in:
parent
5206ab5b27
commit
d78d28cc7a
@ -8,6 +8,7 @@ import org.bukkit.Bukkit;
|
||||
import org.bukkit.ChatColor;
|
||||
import org.bukkit.Location;
|
||||
import org.bukkit.World;
|
||||
import org.bukkit.entity.Entity;
|
||||
import org.bukkit.entity.Player;
|
||||
import org.bukkit.event.EventHandler;
|
||||
import org.bukkit.event.EventPriority;
|
||||
@ -161,6 +162,17 @@ public class WorldManager extends FreedomService
|
||||
return;
|
||||
}
|
||||
|
||||
for (Player p : Bukkit.getOnlinePlayers())
|
||||
{
|
||||
for (Entity passengerEntity : p.getPassengers())
|
||||
{
|
||||
if (passengerEntity == player)
|
||||
{
|
||||
p.removePassenger(passengerEntity);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (player.getWorld().getName().equalsIgnoreCase(targetWorld))
|
||||
{
|
||||
playerMsg(player, "Going to main world.", ChatColor.GRAY);
|
||||
|
Loading…
Reference in New Issue
Block a user