Added changes from master to Chat

This commit is contained in:
Shaun Bennett 2014-12-17 20:07:39 -06:00
parent 899add5fcd
commit 9ef0ea629c

View File

@ -305,7 +305,8 @@ public class Chat extends MiniPlugin
event.setCancelled(true);
return;
}
else if (!Recharge.Instance.use(sender, "Chat Message", 500, false, false))
else if (!_clientManager.Get(sender).GetRank().Has(Rank.MODERATOR) &&
!Recharge.Instance.use(sender, "Chat Message", 500, false, false))
{
UtilPlayer.message(sender, F.main("Chat", "You are sending messages too fast."));
event.setCancelled(true);
@ -320,7 +321,8 @@ public class Chat extends MiniPlugin
UtilPlayer.message(sender, F.main("Chat", "Chat slow enabled. Please wait " + F.time(UtilTime.convertString(chatSlowTime - timeDiff, 1, UtilTime.TimeUnit.FIT))));
event.setCancelled(true);
}
else if (lastMessage.getMessage().equalsIgnoreCase(event.getMessage()))
else if (!_clientManager.Get(sender).GetRank().Has(Rank.MODERATOR) &&
lastMessage.getMessage().equalsIgnoreCase(event.getMessage()))
{
UtilPlayer.message(sender, F.main("Chat", "You can't repeat the same message."));
event.setCancelled(true);