Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ResourcePackStatusEvent is never called. #3744

Closed
avaruus1 opened this issue Aug 18, 2022 · 1 comment · Fixed by #3759
Closed

ResourcePackStatusEvent is never called. #3744

avaruus1 opened this issue Aug 18, 2022 · 1 comment · Fixed by #3759
Labels
status: needs triage This label is automatically applied to new issues and pull requests to indicate they require triage type: bug Something isn't working

Comments

@avaruus1
Copy link
Contributor

Affected Product(s)

SpongeVanilla

Version

1.16.5-8.1.0-RC1173

Operating System

Linux archlinux 5.19.1-zen1-1-zen

Java Version

18.0.2

Plugins/Mods

-

Describe the bug

ResourcePackStatusEvent never seems to be called. Listening to ServerboundResourcePackPacket manually works.

Link to logs

No response

@avaruus1 avaruus1 added status: needs triage This label is automatically applied to new issues and pull requests to indicate they require triage type: bug Something isn't working labels Aug 18, 2022
@avaruus1
Copy link
Contributor Author

After doing some digging, it seems like the only reason the server doesn't crash is because handleResourcePackResponse(...) in ServerGamePacketListenerImpl does not call PacketUtils.ensureRunningOnSameThread(...). Adding the call manually using mixin results in the server crashing with the following stacktrace: https://gist.github.com/avaruus1/3137ec794340040f7dd4fc477c6253ef

Notably present:
java.lang.AbstractMethodError: Receiver class net.minecraft.server.network.ServerGamePacketListenerImpl does not define or inherit an implementation of the resolved method 'abstract org.spongepowered.api.resourcepack.ResourcePack bridge$popReceivedResourcePack(boolean)' of interface org.spongepowered.common.bridge.server.network.ServerGamePacketListenerImplBridge.

While I have no idea whether just adding the call to ensureRunningOnSameThread & implementing the method(s) in the bridge would fix the issue, I hope that this information helps someone who knows something about Sponge internals to fix it 😃

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: needs triage This label is automatically applied to new issues and pull requests to indicate they require triage type: bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant