mirror of
https://github.com/NoCheatPlus/NoCheatPlus.git
synced 2024-10-31 07:40:16 +01: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() {
|
private Listener getCoreListener() {
|
||||||
return new NCPListener() {
|
return new NCPListener() {
|
||||||
@SuppressWarnings("unused")
|
@SuppressWarnings("unused")
|
||||||
@EventHandler(priority = EventPriority.HIGHEST)
|
@EventHandler(priority = EventPriority.NORMAL)
|
||||||
public void onPlayerLogin(final PlayerLoginEvent event) {
|
public void onPlayerLogin(final PlayerLoginEvent event) {
|
||||||
// (HGHEST to give other plugins the possibility to add
|
// (NORMAL to have chat checks come after this.)
|
||||||
// permissions or allow the player).
|
|
||||||
if (event.getResult() != Result.ALLOWED) return;
|
if (event.getResult() != Result.ALLOWED) return;
|
||||||
final Player player = event.getPlayer();
|
final Player player = event.getPlayer();
|
||||||
// Check if login is denied:
|
// Check if login is denied:
|
||||||
|
@ -198,7 +198,7 @@ public class ChatListener extends CheckListener implements INotifyReload {
|
|||||||
@EventHandler(
|
@EventHandler(
|
||||||
priority = EventPriority.NORMAL)
|
priority = EventPriority.NORMAL)
|
||||||
public void onPlayerLogin(final PlayerLoginEvent event) {
|
public void onPlayerLogin(final PlayerLoginEvent event) {
|
||||||
|
if (event.getResult() != Result.ALLOWED) return;
|
||||||
final Player player = event.getPlayer();
|
final Player player = event.getPlayer();
|
||||||
final ChatConfig cc = ChatConfig.getConfig(player);
|
final ChatConfig cc = ChatConfig.getConfig(player);
|
||||||
final ChatData data = ChatData.getData(player);
|
final ChatData data = ChatData.getData(player);
|
||||||
|
Loading…
Reference in New Issue
Block a user