From 4df74d8876efc2b1bf7970172940181fd5b47dc6 Mon Sep 17 00:00:00 2001 From: UnknownShadow200 Date: Mon, 30 May 2016 16:31:25 +1000 Subject: [PATCH] Remove /staff and /mods, just use /devs. --- Commands/Information/CmdDevs.cs | 37 ++++++++++++++ Commands/Information/CmdStaff.cs | 76 ---------------------------- Commands/Information/CmdViewRanks.cs | 2 +- MCGalaxy_.csproj | 2 +- 4 files changed, 39 insertions(+), 78 deletions(-) create mode 100644 Commands/Information/CmdDevs.cs delete mode 100644 Commands/Information/CmdStaff.cs diff --git a/Commands/Information/CmdDevs.cs b/Commands/Information/CmdDevs.cs new file mode 100644 index 000000000..01d42562b --- /dev/null +++ b/Commands/Information/CmdDevs.cs @@ -0,0 +1,37 @@ +/* + Copyright 2010 MCLawl Team - Written by Valek (Modified for use with MCGalaxy) + + Dual-licensed under the Educational Community License, Version 2.0 and + the GNU General Public License, Version 3 (the "Licenses"); you may + not use this file except in compliance with the Licenses. You may + obtain a copy of the Licenses at + + http://www.opensource.org/licenses/ecl2.php + http://www.gnu.org/licenses/gpl-3.0.html + + Unless required by applicable law or agreed to in writing, + software distributed under the Licenses are distributed on an "AS IS" + BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + or implied. See the Licenses for the specific language governing + permissions and limitations under the Licenses. +*/ +namespace MCGalaxy.Commands { + + public sealed class CmdDevs : Command { + public override string name { get { return "devs"; } } + public override string shortcut { get { return "dev"; } } + public override string type { get { return CommandTypes.Information; } } + public override bool museumUsable { get { return true; } } + public override LevelPermission defaultRank { get { return LevelPermission.Banned; } } + + public override void Use(Player p, string message) { + if (message != "") { Help(p); return; } + Player.Message(p, "&9MCGalaxy devs: %S{0}", string.Join(", ", Server.Devs)); + Player.Message(p, "&9MCGalaxy mods: %S{0}", string.Join(", ", Server.Mods)); + } + + public override void Help(Player p) { + Player.Message(p, "/devs - Displays the MCGalaxy team (Developers and moderators)."); + } + } +} diff --git a/Commands/Information/CmdStaff.cs b/Commands/Information/CmdStaff.cs deleted file mode 100644 index 176a5e8fc..000000000 --- a/Commands/Information/CmdStaff.cs +++ /dev/null @@ -1,76 +0,0 @@ -/* - Copyright 2010 MCLawl Team - Written by Valek (Modified for use with MCGalaxy) - - Dual-licensed under the Educational Community License, Version 2.0 and - the GNU General Public License, Version 3 (the "Licenses"); you may - not use this file except in compliance with the Licenses. You may - obtain a copy of the Licenses at - - http://www.opensource.org/licenses/ecl2.php - http://www.gnu.org/licenses/gpl-3.0.html - - Unless required by applicable law or agreed to in writing, - software distributed under the Licenses are distributed on an "AS IS" - BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express - or implied. See the Licenses for the specific language governing - permissions and limitations under the Licenses. -*/ -namespace MCGalaxy.Commands { - - public sealed class CmdStaff : Command { - public override string name { get { return "staff"; } } - public override string shortcut { get { return ""; } } - public override string type { get { return CommandTypes.Information; } } - public override bool museumUsable { get { return true; } } - public override LevelPermission defaultRank { get { return LevelPermission.Banned; } } - public CmdStaff() { } - - public override void Use(Player p, string message) { - if (message != "") { Help(p); return; } - Command.all.Find("devs").Use(p, ""); - Command.all.Find("mods").Use(p, ""); - } - - public override void Help(Player p) { - Player.Message(p, "/staff - Displays the MCGalaxy team."); - } - } - - public sealed class CmdMods : Command { - - public override string name { get { return "mods"; } } - public override string shortcut { get { return "mod"; } } - public override string type { get { return CommandTypes.Information; } } - public override bool museumUsable { get { return true; } } - public override LevelPermission defaultRank { get { return LevelPermission.Banned; } } - - public override void Use(Player p, string message) { - if (message != "") { Help(p); return; } - string modlist = string.Join(", ", Server.Mods); - Player.Message(p, "&9MCGalaxy mods: %S" + modlist + "&e."); - } - - public override void Help(Player p) { - Player.Message(p, "/mods - Displays the list of MCGalaxy moderators."); - } - } - - public sealed class CmdDevs : Command { - - public override string name { get { return "devs"; } } - public override string shortcut { get { return "dev"; } } - public override string type { get { return CommandTypes.Information; } } - public override bool museumUsable { get { return true; } } - public override LevelPermission defaultRank { get { return LevelPermission.Banned; } } - - public override void Use(Player p, string message) { - if (message != "") { Help(p); return; } - string devlist = string.Join(", ", Server.Devs); - Player.Message(p, "&9MCGalaxy devs: %S" + devlist + "&e."); - } - - public override void Help(Player p) { - Player.Message(p, "/devs - Displays the list of MCGalaxy developers."); - } - } -} diff --git a/Commands/Information/CmdViewRanks.cs b/Commands/Information/CmdViewRanks.cs index 95f953523..6210b3f3a 100644 --- a/Commands/Information/CmdViewRanks.cs +++ b/Commands/Information/CmdViewRanks.cs @@ -27,7 +27,7 @@ namespace MCGalaxy.Commands { public override LevelPermission defaultRank { get { return LevelPermission.Guest; } } public override CommandAlias[] Aliases { get { return new[] { new CommandAlias("ops", "operator"), new CommandAlias("admins", "superop"), - new CommandAlias("banned", "banned"), new CommandAlias("balist", "banned") }; } + new CommandAlias("banned", "banned"), new CommandAlias("banlist", "banned") }; } } public CmdViewRanks() { } diff --git a/MCGalaxy_.csproj b/MCGalaxy_.csproj index ff1e4dadb..b508e0de2 100644 --- a/MCGalaxy_.csproj +++ b/MCGalaxy_.csproj @@ -255,7 +255,7 @@ - +