Banned players no longer show leave messages.
Admins still see the confirmation for the ban, and notifications for any auto-bans (with reasons). Players just aren't bothered with the leave message. Important for spam using lots of different accounts.
This commit is contained in:
parent
259e285847
commit
ae56fdcbcc
|
|
@ -594,6 +594,12 @@ class PlayerEventHandler implements Listener
|
||||||
event.setQuitMessage(null);
|
event.setQuitMessage(null);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//silence notifications when the player is banned
|
||||||
|
if(player.isBanned())
|
||||||
|
{
|
||||||
|
event.setQuitMessage(null);
|
||||||
|
}
|
||||||
|
|
||||||
//make sure his data is all saved - he might have accrued some claim blocks while playing that were not saved immediately
|
//make sure his data is all saved - he might have accrued some claim blocks while playing that were not saved immediately
|
||||||
this.dataStore.savePlayerData(player.getUniqueId(), playerData);
|
this.dataStore.savePlayerData(player.getUniqueId(), playerData);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue
Block a user