Skip to content

v0.9.11 — the model-swap crash is gone

Choose a tag to compare

@Frostn1 Frostn1 released this 08 Aug 07:30
· 19 commits to main since this release
4a11efd

Update to this build if you use MXB App's model swaps. v0.9.9 could crash MX Bikes to desktop, and the crash landed later than the thing that caused it.

Fixed

The game no longer crashes to desktop after a model swap. v0.9.9's instant model refresh replayed the game's bike-apply call using the arguments of an earlier call, so a swapped model would appear without the class-switch away-and-back. It crashed the game — but not at the swap. The crash landed on the next bike you selected by hand, which is why it read as "picking a bike crashes MX Bikes" rather than as anything to do with swapping a model.

The replay is removed. It couldn't be made safe by checking harder:

  • The descriptor is a caller temporary FrostMod doesn't own. The liveness test — is the captured bike name still in its bytes — passes for a stack frame that has returned but not yet been overwritten, which is exactly the case it existed to catch.
  • The object the call writes its result into was never checked at all.
  • The content reload rebuilds the very arrays the loader indexes, so after a swap the capture describes a world that no longer exists — and the replay waited for that reload to finish, then went ahead regardless.
  • The exception guard around the call made it worse: a fault inside a half-finished machine swap was swallowed and the game carried on with the wreckage, turning an immediate crash into a delayed one.

Both swap paths — the F8 model swap and MXB App's command channel — now say "model swapped — re-select the bike to see it" and leave the running game alone. Re-selecting the bike in the garage loads the new model.

Changed

The bike-apply hook is opt-in again (frostmod_bikecap.flag), as it was before v0.9.9. Shipping it to everyone put a detour — and its speculative scan of the descriptor — in the path of every bike selection in every player's game, purely to feed a refresh that no longer exists.

Why the version skips 0.9.10

A v0.9.10-rc1 pre-release was published from a different branch that still contains the replay, and its version file also reads 0.9.10. MXB App decides whether it's safe to ask for a live model refresh by comparing the recorded version numerically, so a 0.9.10 floor would have read that pre-release as new enough and asked it for the very thing that crashes it. Taking the next number excludes it cleanly. If you are on v0.9.10-rc1, update — it still has the crash.

Pairing with MXB App

MXB App v0.7.1 and up withhold the live-refresh request from any FrostMod below v0.9.11, so the app protects its own swaps even before you update. This release is what also covers FrostMod's own F8 swap, which the app can't reach.

Still open

Making a swapped model appear without the re-select needs the descriptor's layout pinned down first, so the apply can be driven from one FrostMod builds rather than one it borrowed. Until then, the re-select is the step.