Dynmap-Forge/Fabric

Dynmap-Forge/Fabric

888k Downloads

Dynmap crashes server when launched with cardboard mod

Killakilla2 opened this issue ยท 7 comments

commented

Issue Description: Dynmap crashes server when launched with cardboard mod at same timeCardboard or Dynmap each launch individually without issue.

  • Dynmap Version: Dynmap-3.2-beta-3-fabric-1.17.1
  • Server Version: Fabric 1.17.1
  • Pastebin of Configuration.txt: https://pastebin.com/HbXfQbzu
  • Server Host (if applicable): Self Hosted
  • Pastebin of crashlogs or other relevant logs: https://pastebin.com/7gRWinsF
  • Other Relevant Data/Screenshots: NA
  • Steps to Replicate: add cardboard mod (CardboardMod-1.17) with Fabric API and DynMap in a Fabric 1.17.1 and it crashes server. Cardboard or Dynmap each launch individually without issue

[x ] I have looked at all other issues and this is not a duplicate
[x ] I have been able to replicate this

commented

Cardboard is terrible codewise, so for your own sanity don't use it.

commented

There are a whole bunch of warning and errors in your logs to unpack. Unfortunately I don't think its fair on the one dev to support "Cardboard is still in development and may not support every plugin". He supports Paper, Spigot, etc, but not hybrid setups.

Maybe submit to the Cardboard issue tracker as a test case to solve as it is kinda popular with some online servers.

commented

The issue is on Cardboard side, they're overwriting an entire vanilla method instead of injecting:

https://github.com/CardboardPowered/cardboard/blob/dev/src/main/java/org/cardboardpowered/mixin/network/MixinServerPlayNetworkHandler_ChatEvent.java
https://github.com/webbukkit/dynmap/blob/v3.0/fabric-1.17.1/src/main/java/org/dynmap/fabric_1_17_1/mixin/ServerPlayNetworkHandlerMixin.java

You can do a quick fix by opening dynmap.mixins.json inside the JAR and removing ServerPlayNetworkHandlerMixin from there. Chat functionality will not work but at least it should load:

https://github.com/webbukkit/dynmap/blob/v3.0/fabric-1.17.1/src/main/resources/dynmap.mixins.json

commented

There is a mixin collision - that is, a necessary mod injection into vanilla by dynmap that is colliding with one of the dozens of such injections done by Cardboard. The span of these injections by Cardboard, while possibly needed on their part, is likely why there are a lot of other such issues with Cardboard and other Fabric mods. The current Dynmap Fabric mod depends on this injection for reflecting server chat messages to the web, so it is not optional - but, as I didn't do the mixins for Fabric here, I'll defer to the folks that work on the Fabric port ....

commented

The above gist summarizes it perfectly:

Cardboards approach is more or less taking bukkit code and hitting it with a hammer until it barely works.

On my side it's a Won't Fix, simply because I consider it a net negative for the community to try to support such a fundamentally broken mod.

commented

Is this something we can 'support' for Cardboard, or detect at startup, or cant fix? Is this something we could mention on their github?

On their github I see a few references to Cardboard and Dynmap not happily working together, so it might not be something entirely new

commented

https://gist.github.com/Patbox/e44844294c358b614d347d369b0fc3bf

Supporting cardboard cardboard is waste of time, as it doesn't really give any advantages over using fabric mods or just plugins (it doesn't work great with other mods or plugins really and causes more issue than it helps).