mirror of
https://github.com/AtlasMediaGroup/TotalFreedomMod.git
synced 2024-11-30 02:05:41 +00:00
Fixed false positive plugin specific command block. Resolves #575
This commit is contained in:
parent
2dd8e00201
commit
42266c37ea
@ -1,3 +1,3 @@
|
||||
#Build Number for ANT. Do not edit!
|
||||
#Mon Apr 27 00:47:37 CEST 2015
|
||||
build.number=993
|
||||
#Sun May 10 23:13:43 CEST 2015
|
||||
build.number=995
|
||||
|
@ -712,7 +712,7 @@ public class TFM_PlayerListener implements Listener
|
||||
command = command.toLowerCase().trim();
|
||||
|
||||
// Blocked commands
|
||||
if (TFM_CommandBlocker.isCommandBlocked(command, event.getPlayer()))
|
||||
if (TFM_CommandBlocker.isCommandBlocked(command, event.getPlayer(), true))
|
||||
{
|
||||
// CommandBlocker handles messages and broadcasts
|
||||
event.setCancelled(true);
|
||||
|
@ -102,7 +102,7 @@ public class TFM_CommandBlocker
|
||||
|
||||
public static boolean isCommandBlocked(String command, CommandSender sender)
|
||||
{
|
||||
return isCommandBlocked(command, sender, true);
|
||||
return isCommandBlocked(command, sender, false);
|
||||
}
|
||||
|
||||
public static boolean isCommandBlocked(String command, CommandSender sender, boolean doAction)
|
||||
@ -112,7 +112,7 @@ public class TFM_CommandBlocker
|
||||
return false;
|
||||
}
|
||||
|
||||
if (command.contains(":"))
|
||||
if (command.split(" ")[0].contains(":"))
|
||||
{
|
||||
TFM_Util.playerMsg(sender, "Plugin-specific commands are disabled.");
|
||||
return true;
|
||||
|
Loading…
Reference in New Issue
Block a user