Skip to content

fix: prevent infinite loading loop in Frostbite Caves (fixes #17) - #19

Open
Lordfckx wants to merge 2 commits into
Gzh0821:masterfrom
Lordfckx:fix/frostbite-caves-loading-loop-17
Open

fix: prevent infinite loading loop in Frostbite Caves (fixes #17)#19
Lordfckx wants to merge 2 commits into
Gzh0821:masterfrom
Lordfckx:fix/frostbite-caves-loading-loop-17

Conversation

@Lordfckx

Copy link
Copy Markdown

Summary

Root Cause

In worldMapScene.ts (switchWM method), the load callback generator had:

case 0: ... if(!p){i.next=18;break}return p.MapProps=h, ..., p.init();

The raw return exited the generator immediately, bypassing case 19 where flowerOff() is called. This left the loader flower visible indefinitely — appearing as an "infinite loading loop."

Fix

Removed return so execution falls through to subsequent cases:

Before: !p){i.next=18;break}return p.MapProps=h
After:  !p){i.next=18;break}p.MapProps=h

Now p.init()case 16case 19flowerOff() is always reached.

Testing

  • JavaScript syntax validated (no broken structure, all System.register / _RF.pop counts preserved)
  • Frostbite Caves level data (IceageWORLDMAP) confirmed valid — all 42 levels, no corrupted JSON
  • HTTP server starts without errors
  • The fix affects the shared switchWM code path, so it benefits all worlds, not just Frostbite Caves

Note

This is a patch to the compiled docs/assets/main/index.js. The original TypeScript source was not available, so the equivalent TS fix would be removing the return before this.currentWM = p; p.MapProps = h; ... p.init(); in worldMapScene.ts:switchWM.

@sourcery-ai sourcery-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry @Lordfckx, your pull request is larger than the review limit of 150000 diff characters

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Indefinite time while loading the map for the FrostBite Caves

1 participant