Mirror von
https://github.com/ViaVersion/ViaVersion.git
synchronisiert 2024-12-27 08:30:09 +01:00
Fix late registration of join listener (#3360)
Dieser Commit ist enthalten in:
Ursprung
a817746edc
Commit
e32933ada9
@ -103,6 +103,12 @@ public class ViaVersionPlugin extends JavaPlugin implements ViaPlatform<Player>
|
|||||||
manager.init();
|
manager.init();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (Via.getConfig().shouldRegisterUserConnectionOnJoin()) {
|
||||||
|
// When event priority ties, registration order is used.
|
||||||
|
// Must register without delay to ensure other plugins on lowest get the fix applied.
|
||||||
|
getServer().getPluginManager().registerEvents(new JoinListener(), this);
|
||||||
|
}
|
||||||
|
|
||||||
if (FOLIA) {
|
if (FOLIA) {
|
||||||
// Use Folia's RegionizedServerInitEvent to run code after the server has loaded
|
// Use Folia's RegionizedServerInitEvent to run code after the server has loaded
|
||||||
final Class<? extends Event> serverInitEventClass;
|
final Class<? extends Event> serverInitEventClass;
|
||||||
|
@ -79,10 +79,6 @@ public class BukkitViaLoader implements ViaPlatformLoader {
|
|||||||
public void load() {
|
public void load() {
|
||||||
registerListener(new UpdateListener());
|
registerListener(new UpdateListener());
|
||||||
|
|
||||||
if (Via.getConfig().shouldRegisterUserConnectionOnJoin()) {
|
|
||||||
registerListener(new JoinListener());
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Base Protocol */
|
/* Base Protocol */
|
||||||
final ViaVersionPlugin plugin = (ViaVersionPlugin) Bukkit.getPluginManager().getPlugin("ViaVersion");
|
final ViaVersionPlugin plugin = (ViaVersionPlugin) Bukkit.getPluginManager().getPlugin("ViaVersion");
|
||||||
|
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren