From 8939b7e728acf9bc2f126df65ebd08f0281ef2a5 Mon Sep 17 00:00:00 2001 From: Jerom van der Sar Date: Mon, 18 Mar 2013 17:08:51 +0100 Subject: [PATCH 1/2] Some changes, I hope we can settle with this first init of /twitter command --- .../{ADMIN_LEVEL.java => AdminLevel.java} | 2 +- .../Commands/CommandPermissions.java | 6 ++--- .../Commands/Command_adminmode.java | 2 +- .../Commands/Command_blockcommand.java | 2 +- .../Commands/Command_cage.java | 2 +- .../Commands/Command_cake.java | 2 +- .../Commands/Command_cartsit.java | 2 +- .../Commands/Command_clearall.java | 2 +- .../Commands/Command_cmdlist.java | 2 +- .../Commands/Command_cookie.java | 2 +- .../Commands/Command_creative.java | 2 +- .../Commands/Command_csay.java | 2 +- .../Commands/Command_deafen.java | 2 +- .../Commands/Command_deop.java | 2 +- .../Commands/Command_deopall.java | 2 +- .../Commands/Command_dispfill.java | 2 +- .../Commands/Command_doom.java | 2 +- .../Commands/Command_enchant.java | 2 +- .../Commands/Command_ender.java | 2 +- .../Commands/Command_expel.java | 2 +- .../Commands/Command_explosives.java | 2 +- .../Commands/Command_fireplace.java | 2 +- .../Commands/Command_firespread.java | 2 +- .../Commands/Command_flatlands.java | 2 +- .../Commands/Command_fluidspread.java | 2 +- .../TotalFreedomMod/Commands/Command_fr.java | 2 +- .../Commands/Command_fuckoff.java | 2 +- .../Commands/Command_gadmin.java | 2 +- .../Commands/Command_gcmd.java | 2 +- .../Commands/Command_glist.java | 2 +- .../Commands/Command_gtfo.java | 2 +- .../Commands/Command_halt.java | 2 +- .../Commands/Command_kicknoob.java | 2 +- .../Commands/Command_landmine.java | 2 +- .../Commands/Command_lastcmd.java | 2 +- .../Commands/Command_lavadmg.java | 2 +- .../Commands/Command_lavaplace.java | 2 +- .../Commands/Command_list.java | 2 +- .../Commands/Command_listsync.java | 2 +- .../Commands/Command_lockup.java | 2 +- .../Commands/Command_moblimiter.java | 2 +- .../TotalFreedomMod/Commands/Command_mp.java | 2 +- .../Commands/Command_mp44.java | 2 +- .../Commands/Command_nether.java | 2 +- .../Commands/Command_nonuke.java | 2 +- .../TotalFreedomMod/Commands/Command_o.java | 2 +- .../Commands/Command_onlinemode.java | 2 +- .../TotalFreedomMod/Commands/Command_op.java | 2 +- .../Commands/Command_opall.java | 2 +- .../Commands/Command_opme.java | 2 +- .../TotalFreedomMod/Commands/Command_ops.java | 2 +- .../Commands/Command_orbit.java | 2 +- .../Commands/Command_permban.java | 2 +- .../Commands/Command_potion.java | 2 +- .../Commands/Command_prelog.java | 2 +- .../Commands/Command_protectarea.java | 2 +- .../Commands/Command_qdeop.java | 2 +- .../TotalFreedomMod/Commands/Command_qop.java | 2 +- .../Commands/Command_radar.java | 2 +- .../Commands/Command_rank.java | 2 +- .../Commands/Command_rawsay.java | 2 +- .../TotalFreedomMod/Commands/Command_rd.java | 2 +- .../TotalFreedomMod/Commands/Command_ro.java | 2 +- .../Commands/Command_saconfig.java | 2 +- .../TotalFreedomMod/Commands/Command_say.java | 2 +- .../Commands/Command_setlevel.java | 2 +- .../Commands/Command_setspawnworld.java | 2 +- .../Commands/Command_smite.java | 2 +- .../Commands/Command_status.java | 2 +- .../Commands/Command_stfu.java | 2 +- .../Commands/Command_stop.java | 2 +- .../Commands/Command_survival.java | 2 +- .../Commands/Command_tempban.java | 2 +- .../Commands/Command_terminal.java | 2 +- .../Commands/Command_tfbanlist.java | 2 +- .../Commands/Command_tfipbanlist.java | 2 +- .../Commands/Command_tfupdate.java | 2 +- .../Commands/Command_tossmob.java | 2 +- .../Commands/Command_twitter.java | 22 +++++++++++++++++++ .../Commands/Command_uall.java | 2 +- .../Commands/Command_waterplace.java | 2 +- .../Commands/Command_whitelist.java | 2 +- .../Commands/Command_wildcard.java | 2 +- .../Commands/Command_wipeflatlands.java | 2 +- .../Commands/Command_ziptool.java | 2 +- .../Commands/SOURCE_TYPE_ALLOWED.java | 6 ----- .../TotalFreedomMod/Commands/SourceType.java | 6 +++++ .../TotalFreedomMod/Commands/TFM_Command.java | 16 +++++++------- src/plugin.yml | 7 ++++-- 89 files changed, 127 insertions(+), 102 deletions(-) rename src/me/StevenLawson/TotalFreedomMod/Commands/{ADMIN_LEVEL.java => AdminLevel.java} (77%) create mode 100644 src/me/StevenLawson/TotalFreedomMod/Commands/Command_twitter.java delete mode 100644 src/me/StevenLawson/TotalFreedomMod/Commands/SOURCE_TYPE_ALLOWED.java create mode 100644 src/me/StevenLawson/TotalFreedomMod/Commands/SourceType.java diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/ADMIN_LEVEL.java b/src/me/StevenLawson/TotalFreedomMod/Commands/AdminLevel.java similarity index 77% rename from src/me/StevenLawson/TotalFreedomMod/Commands/ADMIN_LEVEL.java rename to src/me/StevenLawson/TotalFreedomMod/Commands/AdminLevel.java index c8b5d318..48131c86 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/ADMIN_LEVEL.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/AdminLevel.java @@ -1,6 +1,6 @@ package me.StevenLawson.TotalFreedomMod.Commands; -public enum ADMIN_LEVEL +public enum AdminLevel { ALL, OP, SUPER, SENIOR } diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/CommandPermissions.java b/src/me/StevenLawson/TotalFreedomMod/Commands/CommandPermissions.java index cf08067a..af04509c 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/CommandPermissions.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/CommandPermissions.java @@ -6,11 +6,11 @@ import java.lang.annotation.RetentionPolicy; @Retention(RetentionPolicy.RUNTIME) public @interface CommandPermissions { - ADMIN_LEVEL level(); + AdminLevel level(); - SOURCE_TYPE_ALLOWED source(); + SourceType source(); boolean block_host_console() default false; - boolean ignore_permissions() default true; + boolean ignore_permissions() default false; // O_o } diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_adminmode.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_adminmode.java index 3c74ab1b..c79704c2 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_adminmode.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_adminmode.java @@ -7,7 +7,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) public class Command_adminmode extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_blockcommand.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_blockcommand.java index f0a46e6f..a8b1aa4b 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_blockcommand.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_blockcommand.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_blockcommand extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cage.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cage.java index 1f918f91..bdfe4dc7 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cage.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cage.java @@ -10,7 +10,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_cage extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cake.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cake.java index 328b3e8e..1a18c4a3 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cake.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cake.java @@ -10,7 +10,7 @@ import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; import org.bukkit.inventory.ItemStack; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_cake extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cartsit.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cartsit.java index 0b05da32..ed69c6c9 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cartsit.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cartsit.java @@ -6,7 +6,7 @@ import org.bukkit.command.CommandSender; import org.bukkit.entity.Minecart; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.ALL, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = true) +@CommandPermissions(level = AdminLevel.ALL, source = SourceType.BOTH, ignore_permissions = true) public class Command_cartsit extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_clearall.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_clearall.java index b9f36770..9ac42ae4 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_clearall.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_clearall.java @@ -4,7 +4,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_clearall extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cmdlist.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cmdlist.java index 1a90456d..c1e2113d 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cmdlist.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cmdlist.java @@ -12,7 +12,7 @@ import org.bukkit.entity.Player; import org.bukkit.plugin.Plugin; import org.bukkit.plugin.PluginDescriptionFile; -@CommandPermissions(level = ADMIN_LEVEL.ALL, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = true) +@CommandPermissions(level = AdminLevel.ALL, source = SourceType.BOTH, ignore_permissions = true) public class Command_cmdlist extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cookie.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cookie.java index 179b080d..259c9d58 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cookie.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_cookie.java @@ -10,7 +10,7 @@ import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; import org.bukkit.inventory.ItemStack; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_cookie extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_creative.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_creative.java index c4a716a5..60a97168 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_creative.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_creative.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.BOTH, ignore_permissions = false) public class Command_creative extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_csay.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_csay.java index b7772fe8..a95f64c9 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_csay.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_csay.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.ONLY_CONSOLE, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.ONLY_CONSOLE, ignore_permissions = false) public class Command_csay extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_deafen.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_deafen.java index 400aba9f..0ded5983 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_deafen.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_deafen.java @@ -7,7 +7,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SENIOR, source = SOURCE_TYPE_ALLOWED.BOTH, block_host_console = true, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SENIOR, source = SourceType.BOTH, block_host_console = true, ignore_permissions = false) public class Command_deafen extends TFM_Command { private static final Random random = new Random(); diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_deop.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_deop.java index b854e048..b070f53f 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_deop.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_deop.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_deop extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_deopall.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_deopall.java index 4cb49692..fa20623c 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_deopall.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_deopall.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_deopall extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_dispfill.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_dispfill.java index 7b588b93..e5a0e194 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_dispfill.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_dispfill.java @@ -14,7 +14,7 @@ import org.bukkit.entity.Player; import org.bukkit.inventory.Inventory; import org.bukkit.inventory.ItemStack; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.ONLY_IN_GAME, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.ONLY_IN_GAME, ignore_permissions = false) public class Command_dispfill extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_doom.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_doom.java index dfc4f4fe..8ae001d8 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_doom.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_doom.java @@ -9,7 +9,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SENIOR, source = SOURCE_TYPE_ALLOWED.ONLY_CONSOLE, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SENIOR, source = SourceType.ONLY_CONSOLE, ignore_permissions = false) public class Command_doom extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_enchant.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_enchant.java index 61c04d11..67a7fb76 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_enchant.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_enchant.java @@ -6,7 +6,7 @@ import org.bukkit.enchantments.Enchantment; import org.bukkit.entity.Player; import org.bukkit.inventory.ItemStack; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.ONLY_IN_GAME, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.ONLY_IN_GAME, ignore_permissions = false) public class Command_enchant extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ender.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ender.java index c2ef84e1..8bdda743 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ender.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ender.java @@ -5,7 +5,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.ALL, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = true) +@CommandPermissions(level = AdminLevel.ALL, source = SourceType.BOTH, ignore_permissions = true) public class Command_ender extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_expel.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_expel.java index 448a175a..c09a53f9 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_expel.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_expel.java @@ -5,7 +5,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.ONLY_IN_GAME, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.ONLY_IN_GAME, ignore_permissions = false) public class Command_expel extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_explosives.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_explosives.java index 5c6f9758..dc9e85f9 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_explosives.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_explosives.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_explosives extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fireplace.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fireplace.java index 72af02e6..ff8b9c5d 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fireplace.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fireplace.java @@ -5,7 +5,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_fireplace extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_firespread.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_firespread.java index ed148790..887fc529 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_firespread.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_firespread.java @@ -5,7 +5,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_firespread extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_flatlands.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_flatlands.java index 338519cf..1d18b51d 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_flatlands.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_flatlands.java @@ -7,7 +7,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.ALL, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = true) +@CommandPermissions(level = AdminLevel.ALL, source = SourceType.BOTH, ignore_permissions = true) public class Command_flatlands extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fluidspread.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fluidspread.java index b26e5725..b8413cef 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fluidspread.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fluidspread.java @@ -5,7 +5,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_fluidspread extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fr.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fr.java index 52e5a8bc..3c493153 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fr.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fr.java @@ -8,7 +8,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_fr extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fuckoff.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fuckoff.java index 1b6bdfe6..41cb3b60 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fuckoff.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_fuckoff.java @@ -5,7 +5,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SENIOR, source = SOURCE_TYPE_ALLOWED.ONLY_IN_GAME, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SENIOR, source = SourceType.ONLY_IN_GAME, ignore_permissions = false) public class Command_fuckoff extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_gadmin.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_gadmin.java index c0b63032..96ce0300 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_gadmin.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_gadmin.java @@ -9,7 +9,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_gadmin extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_gcmd.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_gcmd.java index 833e538f..e768b14f 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_gcmd.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_gcmd.java @@ -5,7 +5,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_gcmd extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_glist.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_glist.java index 72917409..4a4d6d2d 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_glist.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_glist.java @@ -12,7 +12,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_glist extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_gtfo.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_gtfo.java index cabe7b20..abe17f7e 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_gtfo.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_gtfo.java @@ -9,7 +9,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_gtfo extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_halt.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_halt.java index c1917407..7daa9312 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_halt.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_halt.java @@ -8,7 +8,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_halt extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_kicknoob.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_kicknoob.java index 33a2b2b4..b90729ea 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_kicknoob.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_kicknoob.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SENIOR, source = SOURCE_TYPE_ALLOWED.BOTH, block_host_console = true, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SENIOR, source = SourceType.BOTH, block_host_console = true, ignore_permissions = false) public class Command_kicknoob extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_landmine.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_landmine.java index d3a3c597..dcb7a6cf 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_landmine.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_landmine.java @@ -10,7 +10,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.ONLY_IN_GAME, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.ONLY_IN_GAME, ignore_permissions = false) public class Command_landmine extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lastcmd.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lastcmd.java index 819a68c0..e24c9302 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lastcmd.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lastcmd.java @@ -7,7 +7,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_lastcmd extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lavadmg.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lavadmg.java index 45719b55..3e696a50 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lavadmg.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lavadmg.java @@ -5,7 +5,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_lavadmg extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lavaplace.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lavaplace.java index 59c07ccf..72ed492f 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lavaplace.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lavaplace.java @@ -5,7 +5,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_lavaplace extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_list.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_list.java index 0706c7c6..1ce1c44c 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_list.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_list.java @@ -10,7 +10,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.ALL, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = true) +@CommandPermissions(level = AdminLevel.ALL, source = SourceType.BOTH, ignore_permissions = true) public class Command_list extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_listsync.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_listsync.java index 7187a6be..61fa31f7 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_listsync.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_listsync.java @@ -8,7 +8,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SENIOR, source = SOURCE_TYPE_ALLOWED.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SENIOR, source = SourceType.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) public class Command_listsync extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lockup.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lockup.java index 5bb9bd83..c2989f59 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lockup.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_lockup.java @@ -9,7 +9,7 @@ import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; import org.bukkit.scheduler.BukkitTask; -@CommandPermissions(level = ADMIN_LEVEL.SENIOR, source = SOURCE_TYPE_ALLOWED.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SENIOR, source = SourceType.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) public class Command_lockup extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_moblimiter.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_moblimiter.java index 67386b92..0d75e374 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_moblimiter.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_moblimiter.java @@ -5,7 +5,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.ONLY_CONSOLE, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.ONLY_CONSOLE, ignore_permissions = false) public class Command_moblimiter extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_mp.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_mp.java index 302c4822..f912db4c 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_mp.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_mp.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.*; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.BOTH, ignore_permissions = false) public class Command_mp extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_mp44.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_mp44.java index 29738c6f..42a106af 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_mp44.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_mp44.java @@ -9,7 +9,7 @@ import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; import org.bukkit.inventory.ItemStack; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.ONLY_IN_GAME, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.ONLY_IN_GAME, ignore_permissions = false) public class Command_mp44 extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_nether.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_nether.java index e4d3d5a9..c888c8a6 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_nether.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_nether.java @@ -5,7 +5,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.ALL, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = true) +@CommandPermissions(level = AdminLevel.ALL, source = SourceType.BOTH, ignore_permissions = true) public class Command_nether extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_nonuke.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_nonuke.java index 73c1570c..07f58dee 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_nonuke.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_nonuke.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SENIOR, source = SOURCE_TYPE_ALLOWED.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SENIOR, source = SourceType.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) public class Command_nonuke extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_o.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_o.java index f172a217..51de08b6 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_o.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_o.java @@ -7,7 +7,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_o extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_onlinemode.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_onlinemode.java index 826268ef..93d8b5e0 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_onlinemode.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_onlinemode.java @@ -7,7 +7,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SENIOR, source = SOURCE_TYPE_ALLOWED.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SENIOR, source = SourceType.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) public class Command_onlinemode extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_op.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_op.java index 50a57f26..0d35bf2c 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_op.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_op.java @@ -8,7 +8,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.BOTH, ignore_permissions = false) public class Command_op extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_opall.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_opall.java index 5aadbf32..8aab1445 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_opall.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_opall.java @@ -7,7 +7,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_opall extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_opme.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_opme.java index d50b0e52..6359f3a4 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_opme.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_opme.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.ONLY_IN_GAME, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.ONLY_IN_GAME, ignore_permissions = false) public class Command_opme extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ops.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ops.java index 66fcdfdc..df287850 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ops.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ops.java @@ -8,7 +8,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.BOTH, ignore_permissions = false) public class Command_ops extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_orbit.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_orbit.java index 27fb00cf..b3dbe794 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_orbit.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_orbit.java @@ -9,7 +9,7 @@ import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; import org.bukkit.util.Vector; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_orbit extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_permban.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_permban.java index 58121385..24a41c4c 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_permban.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_permban.java @@ -8,7 +8,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SENIOR, source = SOURCE_TYPE_ALLOWED.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SENIOR, source = SourceType.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) public class Command_permban extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_potion.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_potion.java index 85a8f0af..37c96df1 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_potion.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_potion.java @@ -11,7 +11,7 @@ import org.bukkit.entity.Player; import org.bukkit.potion.PotionEffect; import org.bukkit.potion.PotionEffectType; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.BOTH, ignore_permissions = false) public class Command_potion extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_prelog.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_prelog.java index 8786c1a1..98a46417 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_prelog.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_prelog.java @@ -5,7 +5,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SENIOR, source = SOURCE_TYPE_ALLOWED.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SENIOR, source = SourceType.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) public class Command_prelog extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_protectarea.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_protectarea.java index 7474f114..189da656 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_protectarea.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_protectarea.java @@ -7,7 +7,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_protectarea extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_qdeop.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_qdeop.java index f794caf4..09ff3521 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_qdeop.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_qdeop.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_qdeop extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_qop.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_qop.java index 7dc01ca5..776b2dd3 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_qop.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_qop.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_qop extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_radar.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_radar.java index 829fec04..8262030b 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_radar.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_radar.java @@ -10,7 +10,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.ALL, source = SOURCE_TYPE_ALLOWED.ONLY_IN_GAME, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.ALL, source = SourceType.ONLY_IN_GAME, ignore_permissions = false) public class Command_radar extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_rank.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_rank.java index 7f4711df..707159a2 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_rank.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_rank.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.ALL, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = true) +@CommandPermissions(level = AdminLevel.ALL, source = SourceType.BOTH, ignore_permissions = true) public class Command_rank extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_rawsay.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_rawsay.java index 5a5df00c..bf52aa33 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_rawsay.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_rawsay.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SENIOR, source = SOURCE_TYPE_ALLOWED.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SENIOR, source = SourceType.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) public class Command_rawsay extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_rd.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_rd.java index 6c9620f8..48cf37a2 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_rd.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_rd.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_rd extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ro.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ro.java index 828b85ff..0be2f607 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ro.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ro.java @@ -7,7 +7,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, block_host_console = false, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, block_host_console = false, ignore_permissions = false) public class Command_ro extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_saconfig.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_saconfig.java index 252e5996..0b43935c 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_saconfig.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_saconfig.java @@ -10,7 +10,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.BOTH, ignore_permissions = false) public class Command_saconfig extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_say.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_say.java index 0fc50384..a39ec115 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_say.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_say.java @@ -7,7 +7,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_say extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_setlevel.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_setlevel.java index 7c38c507..24372eda 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_setlevel.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_setlevel.java @@ -5,7 +5,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.ONLY_IN_GAME, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.ONLY_IN_GAME, ignore_permissions = false) public class Command_setlevel extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_setspawnworld.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_setspawnworld.java index a4436b20..28d0ce46 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_setspawnworld.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_setspawnworld.java @@ -9,7 +9,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.ONLY_IN_GAME, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.ONLY_IN_GAME, ignore_permissions = false) public class Command_setspawnworld extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_smite.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_smite.java index 1099387f..6b9bc13f 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_smite.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_smite.java @@ -9,7 +9,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_smite extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_status.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_status.java index 27681f8c..66176238 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_status.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_status.java @@ -22,7 +22,7 @@ import org.json.simple.JSONArray; import org.json.simple.JSONObject; import org.json.simple.JSONValue; -@CommandPermissions(level = ADMIN_LEVEL.ALL, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = true) +@CommandPermissions(level = AdminLevel.ALL, source = SourceType.BOTH, ignore_permissions = true) public class Command_status extends TFM_Command { public static final Map SERVICE_MAP = new HashMap(); diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_stfu.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_stfu.java index 8d8862a1..6d35b51b 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_stfu.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_stfu.java @@ -7,7 +7,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_stfu extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_stop.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_stop.java index f88e70a4..98557245 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_stop.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_stop.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_stop extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_survival.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_survival.java index 6b3a03f4..7b8bde8f 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_survival.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_survival.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.BOTH, ignore_permissions = false) public class Command_survival extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tempban.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tempban.java index 6a2334bc..c8dbe80f 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tempban.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tempban.java @@ -10,7 +10,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_tempban extends TFM_Command { private static final SimpleDateFormat date_format = new SimpleDateFormat("yyyy-MM-dd \'at\' HH:mm:ss z"); diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_terminal.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_terminal.java index fcf84b54..945b45e8 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_terminal.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_terminal.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SENIOR, source = SOURCE_TYPE_ALLOWED.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SENIOR, source = SourceType.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) public class Command_terminal extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tfbanlist.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tfbanlist.java index ce171994..d49611b3 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tfbanlist.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tfbanlist.java @@ -9,7 +9,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.BOTH, ignore_permissions = false) public class Command_tfbanlist extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tfipbanlist.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tfipbanlist.java index eda148d4..46272447 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tfipbanlist.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tfipbanlist.java @@ -11,7 +11,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.BOTH, ignore_permissions = false) public class Command_tfipbanlist extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tfupdate.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tfupdate.java index e3af55e4..b6f178b9 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tfupdate.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tfupdate.java @@ -8,7 +8,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SENIOR, source = SOURCE_TYPE_ALLOWED.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SENIOR, source = SourceType.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) public class Command_tfupdate extends TFM_Command { public static final String[] FILES = diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tossmob.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tossmob.java index 538f4466..ad668cd6 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tossmob.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_tossmob.java @@ -12,7 +12,7 @@ import org.bukkit.entity.EntityType; import org.bukkit.entity.Player; import org.bukkit.inventory.ItemStack; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.ONLY_IN_GAME, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.ONLY_IN_GAME, ignore_permissions = false) public class Command_tossmob extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_twitter.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_twitter.java new file mode 100644 index 00000000..415e915a --- /dev/null +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_twitter.java @@ -0,0 +1,22 @@ +package me.StevenLawson.TotalFreedomMod.Commands; + +import org.bukkit.command.Command; +import org.bukkit.command.CommandSender; +import org.bukkit.entity.Player; + + +public class Command_twitter +{ + @CommandPermissions(level = AdminLevel.SUPER, source = SourceType.ONLY_IN_GAME, ignore_permissions = false) + public class Command_cmdlist extends TFM_Command + { + @Override + public boolean run(CommandSender sender, Player sender_p, Command cmd, String commandLabel, String[] args, boolean senderIsConsole) + { + if (args.length < 1) { + return false; + } + return true; + } + } +} diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_uall.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_uall.java index c0489eda..e1d43239 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_uall.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_uall.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_uall extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_waterplace.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_waterplace.java index e24445b9..b0006763 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_waterplace.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_waterplace.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_waterplace extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_whitelist.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_whitelist.java index 7b7dbc6d..bd92b1b5 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_whitelist.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_whitelist.java @@ -10,7 +10,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.OP, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.OP, source = SourceType.BOTH, ignore_permissions = false) public class Command_whitelist extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_wildcard.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_wildcard.java index e2789130..07497823 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_wildcard.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_wildcard.java @@ -5,7 +5,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SUPER, source = SOURCE_TYPE_ALLOWED.BOTH, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.BOTH, ignore_permissions = false) public class Command_wildcard extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_wipeflatlands.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_wipeflatlands.java index 07a6fbcd..9202949b 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_wipeflatlands.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_wipeflatlands.java @@ -6,7 +6,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SENIOR, source = SOURCE_TYPE_ALLOWED.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SENIOR, source = SourceType.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) public class Command_wipeflatlands extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ziptool.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ziptool.java index 1e8c906c..0e1af5f6 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ziptool.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_ziptool.java @@ -8,7 +8,7 @@ import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -@CommandPermissions(level = ADMIN_LEVEL.SENIOR, source = SOURCE_TYPE_ALLOWED.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) +@CommandPermissions(level = AdminLevel.SENIOR, source = SourceType.ONLY_CONSOLE, block_host_console = true, ignore_permissions = false) public class Command_ziptool extends TFM_Command { @Override diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/SOURCE_TYPE_ALLOWED.java b/src/me/StevenLawson/TotalFreedomMod/Commands/SOURCE_TYPE_ALLOWED.java deleted file mode 100644 index 376c22c9..00000000 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/SOURCE_TYPE_ALLOWED.java +++ /dev/null @@ -1,6 +0,0 @@ -package me.StevenLawson.TotalFreedomMod.Commands; - -public enum SOURCE_TYPE_ALLOWED -{ - ONLY_IN_GAME, ONLY_CONSOLE, BOTH -} diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/SourceType.java b/src/me/StevenLawson/TotalFreedomMod/Commands/SourceType.java new file mode 100644 index 00000000..63096dd9 --- /dev/null +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/SourceType.java @@ -0,0 +1,6 @@ +package me.StevenLawson.TotalFreedomMod.Commands; + +public enum SourceType +{ + ONLY_IN_GAME, ONLY_CONSOLE, BOTH; +} diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/TFM_Command.java b/src/me/StevenLawson/TotalFreedomMod/Commands/TFM_Command.java index 5476ad7e..e27613a3 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/TFM_Command.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/TFM_Command.java @@ -52,8 +52,8 @@ public class TFM_Command is_senior = TFM_SuperadminList.isSeniorAdmin(sender); } - ADMIN_LEVEL level = permissions.level(); - SOURCE_TYPE_ALLOWED source = permissions.source(); + AdminLevel level = permissions.level(); + SourceType source = permissions.source(); boolean block_host_console = permissions.block_host_console(); Player sender_p = null; @@ -64,11 +64,11 @@ public class TFM_Command if (sender_p == null) { - if (source == SOURCE_TYPE_ALLOWED.ONLY_IN_GAME) + if (source == SourceType.ONLY_IN_GAME) { return false; } - else if (level == ADMIN_LEVEL.SENIOR && !is_senior) + else if (level == AdminLevel.SENIOR && !is_senior) { return false; } @@ -79,11 +79,11 @@ public class TFM_Command } else { - if (source == SOURCE_TYPE_ALLOWED.ONLY_CONSOLE) + if (source == SourceType.ONLY_CONSOLE) { return false; } - else if (level == ADMIN_LEVEL.SENIOR) + else if (level == AdminLevel.SENIOR) { if (is_senior) { @@ -103,11 +103,11 @@ public class TFM_Command return false; } } - else if (level == ADMIN_LEVEL.SUPER && !is_super) + else if (level == AdminLevel.SUPER && !is_super) { return false; } - else if (level == ADMIN_LEVEL.OP && !sender_p.isOp()) + else if (level == AdminLevel.OP && !sender_p.isOp()) { return false; } diff --git a/src/plugin.yml b/src/plugin.yml index 97a7f4ac..2dc7ed38 100644 --- a/src/plugin.yml +++ b/src/plugin.yml @@ -232,10 +232,13 @@ commands: usage: / [purge] tfupdate: description: Madgeek command - Update server files. - usave: / + usage: / tossmob: - description: Throw a mob in the direction you are facing when you left click with a stick. + description: SuperAdmin command - Throw a mob in the direction you are facing when you left click with a stick. usage: / + twitter: + description: Manage your twitter + usage: / uall: description: Superadmin command - Undisguises all players usage: / From d020293a26d0457aa0c7c4407a42c65d6e38a4fd Mon Sep 17 00:00:00 2001 From: Jerom van der Sar Date: Tue, 19 Mar 2013 11:06:31 +0100 Subject: [PATCH 2/2] Added /twitter (twitterbot) --- src/config.yml | 5 + .../Commands/Command_twitter.java | 118 +++++++++++++++++- .../TotalFreedomMod/TFM_TwitterHandler.java | 67 ++++++++++ .../TotalFreedomMod/TotalFreedomMod.java | 6 + 4 files changed, 190 insertions(+), 6 deletions(-) create mode 100644 src/me/StevenLawson/TotalFreedomMod/TFM_TwitterHandler.java diff --git a/src/config.yml b/src/config.yml index 166424f4..b94dfd2c 100644 --- a/src/config.yml +++ b/src/config.yml @@ -64,3 +64,8 @@ auto_protect_radius: 25.0 host_sender_names: - rcon - remotebukkit + +# TwitterBot - Used to allow superadmins to verify themselves using twitter +twitterbot_enabled: false +twitterbot_url: 'http://tftwitter.darthcraft.net/' +twitterbot_secret: '' diff --git a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_twitter.java b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_twitter.java index 415e915a..8c1e0875 100644 --- a/src/me/StevenLawson/TotalFreedomMod/Commands/Command_twitter.java +++ b/src/me/StevenLawson/TotalFreedomMod/Commands/Command_twitter.java @@ -1,22 +1,128 @@ package me.StevenLawson.TotalFreedomMod.Commands; +import me.StevenLawson.TotalFreedomMod.TFM_TwitterHandler; +import me.StevenLawson.TotalFreedomMod.TFM_Util; +import me.StevenLawson.TotalFreedomMod.TotalFreedomMod; +import org.bukkit.ChatColor; import org.bukkit.command.Command; import org.bukkit.command.CommandSender; import org.bukkit.entity.Player; -public class Command_twitter +@CommandPermissions(level = AdminLevel.SUPER, source = SourceType.ONLY_IN_GAME, ignore_permissions = false) +public class Command_twitter extends TFM_Command { - @CommandPermissions(level = AdminLevel.SUPER, source = SourceType.ONLY_IN_GAME, ignore_permissions = false) - public class Command_cmdlist extends TFM_Command + @Override + public boolean run(CommandSender sender, Player sender_p, Command cmd, String commandLabel, String[] args, boolean senderIsConsole) { - @Override - public boolean run(CommandSender sender, Player sender_p, Command cmd, String commandLabel, String[] args, boolean senderIsConsole) + if (!TotalFreedomMod.twitterbotEnabled) { - if (args.length < 1) { + TFM_Util.playerMsg(sender, "TwitterBot has been disabled in config.", ChatColor.RED); + return true; + } + + if (args.length < 1) + { + return false; + } + + TFM_TwitterHandler twitterbot = TFM_TwitterHandler.getInstance(plugin); + + if ("set".equals(args[0])) + { + if (args.length != 2) { return false; } + + if(args[1].startsWith("@")) + { + TFM_Util.playerMsg(sender, "Please do not prefix your twitter username with '@'"); + return true; + } + + String reply = twitterbot.setTwitter(sender.getName(), args[1]); + + if ("ok".equals(reply)) + { + TFM_Util.playerMsg(sender, "Your twitter handle has been set to: " + ChatColor.AQUA + "@" + args[1] + ChatColor.GRAY + "."); + } + else if ("disabled".equals(reply)) + { + TFM_Util.playerMsg(sender, "TwitterBot has been temporarily disabled,, please wait until it get re-enabled", ChatColor.RED); + } + else if ("failed".equals(reply)) + { + TFM_Util.playerMsg(sender, "There was a problem querying the database, please let a developer know.", ChatColor.RED); + } + else if ("false".equals(reply)) + { + TFM_Util.playerMsg(sender, "There was a problem with the database, please let a developer know.", ChatColor.RED); + } + else if ("cannotauth".equals(reply)) + { + TFM_Util.playerMsg(sender, "The database password is incorrect, please let a developer know.", ChatColor.RED); + } + else + { + TFM_Util.playerMsg(sender, "An unknown error occurred, please contact a developer", ChatColor.RED); + TFM_Util.playerMsg(sender, "Response code: " + reply); + } return true; } + + if (args.length != 1) + { + return false; + } + + if ("info".equals(args[0])) + { + String reply = twitterbot.getTwitter(sender.getName()); + TFM_Util.playerMsg(sender, "-- Twitter Information --", ChatColor.BLUE); + TFM_Util.playerMsg(sender, "Using this feature, you can re-super yourself using twitter."); + TFM_Util.playerMsg(sender, "You can set your twitter handle using " + ChatColor.AQUA + "/twitter set [twittername]"); + TFM_Util.playerMsg (sender, "Then, you can verify yourself by tweeting " + ChatColor.AQUA + "@TFUpdates #superme"); + if ("notfound".equals(reply)) { + TFM_Util.playerMsg(sender, "You currently have " + ChatColor.RED + "no" + ChatColor.BLUE + " Twitter handle set.", ChatColor.BLUE); + } + else if ("disabled".equals(reply)) + { + TFM_Util.playerMsg(sender, "TwitterBot has been temporarily disabled, please wait until re-enabled", ChatColor.RED); + } + else if ("failed".equals(reply)) + { + TFM_Util.playerMsg(sender, "There was a problem querying the database, please let a developer know.", ChatColor.RED); + } + else if ("false".equals(reply)) + { + TFM_Util.playerMsg(sender, "There was a problem with the database, please let a developer know.", ChatColor.RED); + } + else if ("cannotauth".equals(reply)) + { + TFM_Util.playerMsg(sender, "The database password is incorrect, please let a developer know.", ChatColor.RED); + } + else + { + TFM_Util.playerMsg(sender, "Your current twitter handle: " + ChatColor.AQUA + "@" + reply + ChatColor.BLUE + ".", ChatColor.BLUE); + } + return true; + } + + if ("enable".equals(args[0]) || "disable".equals(args[0])) + { + if (!sender.getName().equalsIgnoreCase("DarthSalamon")) + { + sender.sendMessage(TotalFreedomMod.MSG_NO_PERMS); + return true; + } + + TFM_Util.adminAction(sender.getName(), ("enable".equals(args[0]) ? "Ena" : "Disa") + "bling Twitterbot", true); + String reply = twitterbot.setEnabled(args[0] + "d"); + TFM_Util.playerMsg(sender, "Reply: " + reply); + return true; + } + + // Command not recognised + return false; } } diff --git a/src/me/StevenLawson/TotalFreedomMod/TFM_TwitterHandler.java b/src/me/StevenLawson/TotalFreedomMod/TFM_TwitterHandler.java new file mode 100644 index 00000000..b5f5f26f --- /dev/null +++ b/src/me/StevenLawson/TotalFreedomMod/TFM_TwitterHandler.java @@ -0,0 +1,67 @@ +package me.StevenLawson.TotalFreedomMod; + +import java.io.BufferedReader; +import java.io.InputStreamReader; +import java.net.URL; +import java.net.URLConnection; +import org.apache.commons.lang.exception.ExceptionUtils; + + +public class TFM_TwitterHandler { + + private TotalFreedomMod plugin; + + private TFM_TwitterHandler(TotalFreedomMod plugin) + { + this.plugin = plugin; + } + + public String getTwitter(String player) + { + return request("action=gettwitter&player=" + player); + } + + public String setTwitter(String player, String twitter) + { + if (twitter.startsWith("@")) + { + twitter = twitter.replaceAll("@", ""); + } + return request("action=settwitter&player=" + player + "&twitter=" + twitter); + } + + public String delTwitter(String player) { + return request("action=deltwitter&player=" + player); + } + + public String isEnabled() { + return request("action=getstatus"); + } + + public String setEnabled(String status) { + return request("action=setstatus&status=" + status); + } + + private String request(String queryString) { + String line = "failed"; + try + { + URL getUrl = new URL(TotalFreedomMod.twitterbotUrl + "?auth=" + TotalFreedomMod.twitterbotSecret + "&" + queryString); + URLConnection urlConnection = getUrl.openConnection(); + // Read the response + BufferedReader in = new BufferedReader(new InputStreamReader(urlConnection.getInputStream())); + line = in.readLine(); + in.close(); + } + catch (Exception ex) + { + TFM_Log.severe(ExceptionUtils.getFullStackTrace(ex)); + } + return line; + } + + public static TFM_TwitterHandler getInstance(TotalFreedomMod plugin) { + return new TFM_TwitterHandler(plugin); + } + +} diff --git a/src/me/StevenLawson/TotalFreedomMod/TotalFreedomMod.java b/src/me/StevenLawson/TotalFreedomMod/TotalFreedomMod.java index c703e849..51fd639c 100644 --- a/src/me/StevenLawson/TotalFreedomMod/TotalFreedomMod.java +++ b/src/me/StevenLawson/TotalFreedomMod/TotalFreedomMod.java @@ -221,6 +221,9 @@ public class TotalFreedomMod extends JavaPlugin public static boolean autoProtectSpawnpoints = true; public static double autoProtectRadius = 25.0D; public static List host_sender_names = Arrays.asList("rcon", "remotebukkit"); + public static boolean twitterbotEnabled = false; + public static String twitterbotUrl = "http://tftwitter.darthcraft.net/"; + public static String twitterbotSecret = ""; public static void loadMainConfig() { @@ -262,6 +265,9 @@ public class TotalFreedomMod extends JavaPlugin autoProtectSpawnpoints = config.getBoolean("auto_protect_spawnpoints", autoProtectSpawnpoints); autoProtectRadius = config.getDouble("auto_protect_radius", autoProtectRadius); host_sender_names = config.getStringList("host_sender_names"); + twitterbotEnabled = config.getBoolean("twitterbot_enabled"); + twitterbotUrl = config.getString("twitterbot_url"); + twitterbotSecret = config.getString("twitterbot_secret"); } catch (Exception ex) {