AstralOrdana / Spelunkery

The Spelunkery mod for Minecraft
GNU Lesser General Public License v3.0
42 stars 20 forks source link

[Forge 1.20.1] Crash during startup with Spectrum (via Sinytra Connector) #179

Closed unilock closed 5 months ago

unilock commented 5 months ago

Describe the bug: The game crashes during startup when Spelunkery is installed alongside Spectrum using Sinytra Connector.

Versions: Minecraft version: 1.20.1 Spelunkery version: 0.3.5 Moonlight Lib version: 2.9.7 NeoForge version: 47.1.99

Other mods:

Logs: crash-2024-02-08_17.24.33-client.txt
debug.log

To Reproduce:

  1. Install NeoForge (or Forge 47.1.3) + Sinytra Connector + Spectrum + Spelunkery + dependencies
  2. Start the game
  3. The game crashes during startup

Expected behavior: The game starts.

Screenshots: N/A

Additional info: The issue seems to be caused by this mixin: https://github.com/AstralOrdana/Spelunkery/blob/73a8b0421de91cd624883b46195c1439b5c82b79/common/src/main/java/com/ordana/spelunkery/mixins/NetherPortalSoundMixin.java#L21-L27

During Spectrum's block registration, it calls Block#getSoundType. This fires Spelunkery's mixin, which tries to access Spelunkery's config, which then fails to initialize itself due to Forge not having finalized its mod list yet.

I expect this would happen with any mod that calls Block#getSoundType during mod initialization, so I don't think this is a Connector / Spectrum-specific issue.

AstralOrdana commented 5 months ago

will be fixed for 0.3.6