mirror of
https://github.com/NoCheatPlus/NoCheatPlus.git
synced 2024-08-31 09:39:32 +02:00
Fix players counting for logins checks if already denied to login.
Also lets "tempkick" feature come first.
This commit is contained in:
parent
76d70f7b3b
commit
c0ddeef104
|
@ -708,10 +708,9 @@ public class NoCheatPlus extends JavaPlugin implements NoCheatPlusAPI {
|
|||
private Listener getCoreListener() {
|
||||
return new NCPListener() {
|
||||
@SuppressWarnings("unused")
|
||||
@EventHandler(priority = EventPriority.HIGHEST)
|
||||
@EventHandler(priority = EventPriority.NORMAL)
|
||||
public void onPlayerLogin(final PlayerLoginEvent event) {
|
||||
// (HGHEST to give other plugins the possibility to add
|
||||
// permissions or allow the player).
|
||||
// (NORMAL to have chat checks come after this.)
|
||||
if (event.getResult() != Result.ALLOWED) return;
|
||||
final Player player = event.getPlayer();
|
||||
// Check if login is denied:
|
||||
|
|
|
@ -198,7 +198,7 @@ public class ChatListener extends CheckListener implements INotifyReload {
|
|||
@EventHandler(
|
||||
priority = EventPriority.NORMAL)
|
||||
public void onPlayerLogin(final PlayerLoginEvent event) {
|
||||
|
||||
if (event.getResult() != Result.ALLOWED) return;
|
||||
final Player player = event.getPlayer();
|
||||
final ChatConfig cc = ChatConfig.getConfig(player);
|
||||
final ChatData data = ChatData.getData(player);
|
||||
|
|
Loading…
Reference in New Issue
Block a user