let's add titles shall we

This commit is contained in:
Ivan
2019-11-30 12:43:16 -05:00
parent 9a50903c14
commit 4344ae58bf
4 changed files with 15 additions and 0 deletions

View File

@ -33,6 +33,7 @@ public class Command_freeze extends FreedomCommand
{
if (!isAdmin(player))
{
player.sendTitle(ChatColor.RED + "You've been globally frozen.", ChatColor.YELLOW + "Please be patient and you will be unfrozen shortly." + args, 20, 100, 60);
msg(player, "You have been globally frozen due to an OP breaking the rules, please wait and you will be unfrozen soon.", ChatColor.RED);
}
}
@ -44,6 +45,13 @@ public class Command_freeze extends FreedomCommand
if (args[0].equals("purge"))
{
FUtil.adminAction(sender.getName(), "Unfreezing all players", false);
for (Player player : server.getOnlinePlayers())
{
if (!isAdmin(player))
{
player.sendTitle(ChatColor.RED + "You've been unfrozen.", ChatColor.YELLOW + "Please be patient and you will be unfrozen shortly." + args, 20, 100, 60);
}
}
plugin.fm.purge();
return true;
}