Archived
0

Fixed Mentio ignoring ignore

This commit is contained in:
minenash
2018-03-11 23:43:19 -04:00
parent 0e8da87003
commit 30fe935aee
3 changed files with 16 additions and 0 deletions

View File

@@ -26,6 +26,11 @@ command shrug {
run shrug message; run shrug message;
help Appends the shrug emoticon to the end of your message.; help Appends the shrug emoticon to the end of your message.;
} }
[empty] {
perm utils.shrug;
run shrug;
help Just the shrug emoticon.;
}
} }
command say { command say {
[string:message...] { [string:message...] {

View File

@@ -97,6 +97,13 @@ public class Chat implements Module, Listener
return true; return true;
} }
@Command(hook = "shrugnoarg")
public boolean shrug(CommandSender sender)
{
broadcastFormatted("shrug", sender, "");
return true;
}
@Command(hook = "mute") @Command(hook = "mute")
public boolean mute(CommandSender sender, String player) public boolean mute(CommandSender sender, String player)
{ {

View File

@@ -19,10 +19,12 @@ import com.nemez.cmdmgr.Command;
import com.redstoner.annotations.AutoRegisterListener; import com.redstoner.annotations.AutoRegisterListener;
import com.redstoner.annotations.Commands; import com.redstoner.annotations.Commands;
import com.redstoner.annotations.Version; import com.redstoner.annotations.Version;
import com.redstoner.coremods.moduleLoader.ModuleLoader;
import com.redstoner.misc.CommandHolderType; import com.redstoner.misc.CommandHolderType;
import com.redstoner.misc.JsonManager; import com.redstoner.misc.JsonManager;
import com.redstoner.misc.Main; import com.redstoner.misc.Main;
import com.redstoner.modules.Module; import com.redstoner.modules.Module;
import com.redstoner.modules.ignore.Ignore;
import net.nemez.chatapi.click.Message; import net.nemez.chatapi.click.Message;
@@ -127,6 +129,8 @@ public class Mentio implements Module, Listener
return; return;
for (Player player : event.getRecipients()) for (Player player : event.getRecipients())
{ {
if (ModuleLoader.exists("Ignore") ? !Ignore.getIgnoredBy(event.getPlayer()).sendTo(player) : false)
return;
UUID uuid = player.getUniqueId(); UUID uuid = player.getUniqueId();
JSONArray playerMentios = (JSONArray) mentios.get(uuid.toString()); JSONArray playerMentios = (JSONArray) mentios.get(uuid.toString());
if (playerMentios == null) if (playerMentios == null)