Fixed some issues with vanish and relogging
This commit is contained in:
parent
d6b4b166cc
commit
f8c2665c84
@ -19,7 +19,7 @@ import com.redstoner.misc.Utils;
|
|||||||
import com.redstoner.modules.Module;
|
import com.redstoner.modules.Module;
|
||||||
|
|
||||||
@AutoRegisterListener
|
@AutoRegisterListener
|
||||||
@Version(major = 1, minor = 0, revision = 2, compatible = 1)
|
@Version(major = 1, minor = 0, revision = 3, compatible = 1)
|
||||||
public class Vanish implements Module, Listener
|
public class Vanish implements Module, Listener
|
||||||
{
|
{
|
||||||
private boolean enabled = false;
|
private boolean enabled = false;
|
||||||
@ -130,6 +130,11 @@ public class Vanish implements Module, Listener
|
|||||||
public void onPlayerJoin(PlayerJoinEvent event)
|
public void onPlayerJoin(PlayerJoinEvent event)
|
||||||
{
|
{
|
||||||
Player player = event.getPlayer();
|
Player player = event.getPlayer();
|
||||||
|
if (vanished.contains(player.getUniqueId()))
|
||||||
|
{
|
||||||
|
for (Player p : Bukkit.getOnlinePlayers())
|
||||||
|
p.hidePlayer(player);
|
||||||
|
}
|
||||||
if (player.hasPermission("utils.vanish"))
|
if (player.hasPermission("utils.vanish"))
|
||||||
return;
|
return;
|
||||||
for (UUID uid : vanished)
|
for (UUID uid : vanished)
|
||||||
@ -192,7 +197,7 @@ public class Vanish implements Module, Listener
|
|||||||
private void unvanishPlayer(Player player)
|
private void unvanishPlayer(Player player)
|
||||||
{
|
{
|
||||||
for (Player p : Bukkit.getOnlinePlayers())
|
for (Player p : Bukkit.getOnlinePlayers())
|
||||||
p.showPlayer(p);
|
p.showPlayer(player);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
Reference in New Issue
Block a user