frengor / UltimateAdvancementAPI

A powerful API to create custom advancements for your Minecraft server.
https://modrinth.com/plugin/ultimateadvancementapi
GNU General Public License v3.0
74 stars 5 forks source link

java.lang.IllegalArgumentException: Invalid TeamProgression exception #35

Open Neptnium opened 1 year ago

Neptnium commented 1 year ago

Describe the bug Throws java.lang.IllegalArgumentException: Invalid TeamProgression on UltimateAdvancementAPI plugin on the connection to the server

To Reproduce Just use api.PlayerLoadingCompletedEvent

@EventHandler
public void onJoin(PlayerLoadingCompletedEvent e) {

}

System, Java, Server and Plugin Version System: Docker Java: Java 17 (https://github.com/pterodactyl/yolks/pkgs/container/yolks/61133219?tag=java_17) Server: Paper version git-Paper-91 (MC: 1.19.0) Plugin: UltimateAdvancementAPI (2.2.2)

Screenshots Image

EDIT Even with no plugin using the api the error is still there. I have the error with just the plugin and it justs does not let you connect.

EDIT 2 Might not be the plugin, might be bungee

EDIT 3 It is not the plugin, the plugin was generating an error because the bungee sent a packet that was wrong, sorry guys.

frengor commented 1 year ago

This happens because the player quits too early. This is definitely a bug of the API (the invalid packet only makes the player to quit).
Since the player has already quit when the the event object is created, the TeamProgression of the player is invalid and this is the reason of the error.

This is already fixed in the rework-team-loading branch (which will be part of the 3.0.0 release), although I do NOT recommend to try it since there are still bugs to solve.

Reopening since this will be closed on 3.0.0 release