mirror of
https://github.com/AtlasMediaGroup/TotalFreedomMod.git
synced 2024-11-27 01:05:38 +00:00
let's add titles shall we
This commit is contained in:
parent
9a50903c14
commit
4344ae58bf
@ -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;
|
||||
}
|
||||
|
@ -56,6 +56,7 @@ public class Command_smite extends FreedomCommand
|
||||
public static void smite(CommandSender sender, Player player, String reason)
|
||||
{
|
||||
FUtil.bcastMsg(player.getName() + " has been a naughty, naughty boy.", ChatColor.RED);
|
||||
player.sendTitle(ChatColor.RED + "You've been smitten.", ChatColor.YELLOW + "Be sure to follow the rules!", 20, 100, 60);
|
||||
|
||||
if (reason != null)
|
||||
{
|
||||
@ -90,6 +91,7 @@ public class Command_smite extends FreedomCommand
|
||||
if (reason != null)
|
||||
{
|
||||
player.sendMessage(ChatColor.RED + "You've been smitten. Reason: " + ChatColor.YELLOW + reason);
|
||||
player.sendTitle(ChatColor.RED + "You've been smitten.", ChatColor.YELLOW + "Reason: " + reason, 20, 100, 60);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -63,6 +63,7 @@ public class Command_stfu extends FreedomCommand
|
||||
if (info.isMuted())
|
||||
{
|
||||
info.setMuted(false);
|
||||
mp.sendTitle(ChatColor.RED + "You've been unmuted.", ChatColor.YELLOW + "Be sure to follow the rules!" + args, 20, 100, 60);
|
||||
count++;
|
||||
}
|
||||
}
|
||||
@ -81,6 +82,7 @@ public class Command_stfu extends FreedomCommand
|
||||
{
|
||||
if (!plugin.al.isAdmin(player))
|
||||
{
|
||||
player.sendTitle(ChatColor.RED + "You've been muted globally.", ChatColor.YELLOW + "Please be patient and you will be unmuted shortly." + args, 20, 100, 60);
|
||||
playerdata = plugin.pl.getPlayer(player);
|
||||
playerdata.setMuted(true);
|
||||
counter++;
|
||||
@ -124,6 +126,7 @@ public class Command_stfu extends FreedomCommand
|
||||
msg("Unmuted " + player.getName());
|
||||
|
||||
msg(player, "You have been unmuted.", ChatColor.RED);
|
||||
player.sendTitle(ChatColor.RED + "You've been unmuted.", ChatColor.YELLOW + "Be sure to follow the rules!" + args, 20, 100, 60);
|
||||
}
|
||||
else
|
||||
{
|
||||
@ -142,6 +145,7 @@ public class Command_stfu extends FreedomCommand
|
||||
}
|
||||
|
||||
msg(player, "You have been muted by " + ChatColor.YELLOW + sender.getName(), ChatColor.RED);
|
||||
player.sendTitle(ChatColor.RED + "You've been muted.", ChatColor.YELLOW + "Be sure to follow the rules!" + args, 20, 100, 60);
|
||||
if (reason != null)
|
||||
{
|
||||
msg(player, "Reason: " + ChatColor.YELLOW + reason);
|
||||
|
@ -47,6 +47,7 @@ public class Command_warn extends FreedomCommand
|
||||
String warnReason = StringUtils.join(ArrayUtils.subarray(args, 1, args.length), " ");
|
||||
|
||||
msg(player, ChatColor.RED + "[WARNING] You received a warning: " + warnReason);
|
||||
player.sendTitle(ChatColor.RED + "You've been warned.", ChatColor.YELLOW + "Reason: " + warnReason, 20, 100, 60);
|
||||
msg(ChatColor.GREEN + "You have successfully warned " + player.getName());
|
||||
final StringBuilder adminNotice = new StringBuilder()
|
||||
.append(ChatColor.RED)
|
||||
|
Loading…
Reference in New Issue
Block a user