Ignore private hc messages.

This commit is contained in:
cnaude 2016-05-01 22:07:43 -07:00
parent d558739877
commit 69b79c586e
2 changed files with 6 additions and 0 deletions

View File

@ -60,6 +60,10 @@ public class HeroChatListener implements Listener {
ChatResult result = event.getResult();
plugin.logDebug("HC Format: " + event.getFormat());
plugin.logDebug("HC Result: " + event.getResult());
if (plugin.heroPrivateChatFormat.equals(event.getFormat())) {
plugin.logDebug("HC Private: TRUE");
return;
}
ChatColor chatColor = event.getChannel().getColor();
Player player = chatter.getPlayer();

View File

@ -138,6 +138,7 @@ public class PurpleIRC extends JavaPlugin {
defaultGroupSuffix,
customTabPrefix,
heroChatEmoteFormat,
heroPrivateChatFormat,
listFormat,
listSeparator,
listPlayer,
@ -1540,6 +1541,7 @@ public class PurpleIRC extends JavaPlugin {
logError(ex.getMessage());
}
heroChatEmoteFormat = heroConfig.getString("format.emote", "");
heroPrivateChatFormat = heroConfig.getString("format.private-message");
} else {
hookList.add(hookFormat(PL_HEROCHAT, false));
}