Skip to content

Use Paper's new ServerListPingEvent methods if present#1436

Merged
SupaHam merged 2 commits intoEssentialsX:2.xfrom
N3FS:paper-list-vanish
Aug 4, 2017
Merged

Use Paper's new ServerListPingEvent methods if present#1436
SupaHam merged 2 commits intoEssentialsX:2.xfrom
N3FS:paper-list-vanish

Conversation

@mdcfe
Copy link
Copy Markdown
Member

@mdcfe mdcfe commented Aug 3, 2017

Fixes #1419 - as of the Paper patch that added the new methods, there's now no way to change the server list player count on Paper 1.12+, but this PR fixes the names of vanished players showing up in the server list.

Tested against Spigot 1.12.1 and Paper 1.12.1, latest builds as of submitting PR.

public class EssentialsServerListener implements Listener {
private final transient IEssentials ess;
private boolean errorLogged = false;
private Boolean isPaperSample;
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

primitive boolean

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Leftover of previous messy implementation, will change now

if (ess.getUser(player).isVanished()) {
iterator.remove();
if (isPaperSample) {
// ess.getLogger().info("Paper sample");
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

boop

@mdcfe
Copy link
Copy Markdown
Member Author

mdcfe commented Aug 3, 2017

@SupaHam Fixed

@SupaHam SupaHam merged commit ed0ad87 into EssentialsX:2.x Aug 4, 2017
@SupaHam SupaHam added the bug: confirmed Confirmed bugs in EssentialsX. label Aug 4, 2017
ressidell pushed a commit to ressidell/Essentials that referenced this pull request Apr 27, 2025
)

* Use Paper's new ServerListPingEvent methods if present
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug: confirmed Confirmed bugs in EssentialsX.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Vanish doesn't remove players from server list ping in Paper 1.12

2 participants