mirror of
https://github.com/AtlasMediaGroup/TotalFreedomMod.git
synced 2024-11-16 12:26:12 +00:00
why did that not push
This commit is contained in:
parent
4cf338bfb5
commit
6647088429
@ -13,7 +13,7 @@ import org.bukkit.command.CommandSender;
|
|||||||
import org.bukkit.entity.Player;
|
import org.bukkit.entity.Player;
|
||||||
|
|
||||||
@CommandPermissions(level = Rank.OP, source = SourceType.BOTH)
|
@CommandPermissions(level = Rank.OP, source = SourceType.BOTH)
|
||||||
@CommandParameters(description = "Manage my admin entry", usage = "/<command> [-o <admin>] <clearips | clearip <ip> | setlogin <message> | clearlogin | settag <tag> | cleartag>")
|
@CommandParameters(description = "Manage my admin entry", usage = "/<command> [-o <admin>] <clearips | clearip <ip> | setlogin <message> | clearlogin | settag <tag> | cleartag | setacformat <format> | clearacformat> | oldtags>")
|
||||||
public class Command_myadmin extends FreedomCommand
|
public class Command_myadmin extends FreedomCommand
|
||||||
{
|
{
|
||||||
|
|
||||||
@ -174,12 +174,38 @@ public class Command_myadmin extends FreedomCommand
|
|||||||
case "cleartag":
|
case "cleartag":
|
||||||
{
|
{
|
||||||
FUtil.adminAction(sender.getName(), "Clearing personal default tag" + (init == null ? "" : " for " + targetPlayer.getName()), false);
|
FUtil.adminAction(sender.getName(), "Clearing personal default tag" + (init == null ? "" : " for " + targetPlayer.getName()), false);
|
||||||
String tag = StringUtils.join(args, " ", 1, args.length);
|
|
||||||
target.setTag(null);
|
target.setTag(null);
|
||||||
plugin.al.save();
|
plugin.al.save();
|
||||||
plugin.al.updateTables();
|
plugin.al.updateTables();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
case "setacformat":
|
||||||
|
{
|
||||||
|
String format = StringUtils.join(args, " ", 1, args.length);
|
||||||
|
target.setAcFormat(format);
|
||||||
|
plugin.al.save();
|
||||||
|
plugin.al.updateTables();
|
||||||
|
msg("Set admin chat format to \"" + format + "\".", ChatColor.GRAY);
|
||||||
|
String example = format.replace("%name%", "ExampleAdmin").replace("%rank%", "STA").replace("%msg%", "The quick brown fox jumps over the lazy dog.");
|
||||||
|
msg(ChatColor.GRAY + "Example: " + FUtil.colorize(example));
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
case "clearacformat":
|
||||||
|
{
|
||||||
|
target.setAcFormat(null);
|
||||||
|
plugin.al.save();
|
||||||
|
plugin.al.updateTables();
|
||||||
|
msg("Cleared admin chat format.", ChatColor.GRAY);
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
case "oldtags":
|
||||||
|
{
|
||||||
|
target.setOldTags(!target.getOldTags());
|
||||||
|
plugin.al.save();
|
||||||
|
plugin.al.updateTables();
|
||||||
|
msg(target.getOldTags() ? "Enabled" : "Disabled" + " old tags.");
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
default:
|
default:
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user