[GH-ISSUE #5337] [Feature]: Preserve World Maps draft options in reusable Game Mode setups #2951

Closed
opened 2026-10-21 05:58:17 +07:00 by bsakaguchi · 2 comments
Owner

Originally created by @thetopham on GitHub (Aug 20, 2026).
Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/5337

Originally assigned to: @SpicyMarinara on GitHub.

What problem does this solve?

Reusable Game Mode setup exports preserve spatialMapInstructions and gameWorldMapMode, but they do not preserve the rest of the initial Draft with AI World Maps choices:

  • Map size
  • Custom place target
  • Build from mode (Game setup, Strict lore, or Lore + AI)

Those values are forwarded to World Maps when a game is started, but they remain transient wizard state. Importing the exported setup currently resets them to Medium, 16 places, and Game setup, so the imported setup can create a materially different map without explaining the change.

Proposed solution

  • Extend the Engine-owned reusable Game Mode setup contract to round-trip the AI map draft size, exact place target, and grounding/build-from mode.
  • Treat the exact place target as authoritative when present and derive or validate the matching size preset so imported values cannot disagree.
  • Restore the saved values in New Game setup after import.
  • Continue using the setup's existing active-lorebook selections for lore-grounded map generation.
  • If the saved grounding mode requires lorebooks but none of the referenced lorebooks can be restored, fall back to Game setup and include a clear import warning.
  • Include the restored map options in the readable setup summary.
  • Keep the new fields optional so existing setup exports remain compatible.
  • Add focused validation and export/import regression coverage for preset sizes, a custom target, every grounding mode, invalid values, and the missing-lorebook fallback.

This should be implemented in Marinara Engine's Game setup types, serializer/parser, server validation, and wizard restoration path. World Maps already accepts these request values, so no Marinara-Agents package change or rebuild should be required.

Alternatives considered

  • Keep resetting to defaults after import. This makes a reusable setup silently differ from the setup that was exported.
  • Store these options in the World Maps package. The package consumes them, but the New Game wizard and reusable setup file are Engine-owned.
  • Preserve only the size preset. That would lose an exact custom target such as 10 places.

Additional context

  • Follow-up to #3767, which intentionally limited the earlier setup-export change to the creation prompt and combat style.
  • Related to #4783, which added the Engine-owned custom place target and forwards it to World Maps during New Game setup.
  • Reported by a user who relies on reusable Game Mode setup exports and noticed that the imported World Maps draft options do not match the exported setup.

Template check

Please uncheck (untick) the box below before submitting so we know you read the template. It is intentionally pre-checked:

  • I DID NOT read this template and provide the requested details.
Originally created by @thetopham on GitHub (Aug 20, 2026). Original GitHub issue: https://github.com/Pasta-Devs/Marinara-Engine/issues/5337 Originally assigned to: @SpicyMarinara on GitHub. ## What problem does this solve? Reusable Game Mode setup exports preserve `spatialMapInstructions` and `gameWorldMapMode`, but they do not preserve the rest of the initial **Draft with AI** World Maps choices: - Map size - Custom place target - **Build from** mode (`Game setup`, `Strict lore`, or `Lore + AI`) Those values are forwarded to World Maps when a game is started, but they remain transient wizard state. Importing the exported setup currently resets them to Medium, 16 places, and Game setup, so the imported setup can create a materially different map without explaining the change. ## Proposed solution - Extend the Engine-owned reusable Game Mode setup contract to round-trip the AI map draft size, exact place target, and grounding/build-from mode. - Treat the exact place target as authoritative when present and derive or validate the matching size preset so imported values cannot disagree. - Restore the saved values in New Game setup after import. - Continue using the setup's existing active-lorebook selections for lore-grounded map generation. - If the saved grounding mode requires lorebooks but none of the referenced lorebooks can be restored, fall back to **Game setup** and include a clear import warning. - Include the restored map options in the readable setup summary. - Keep the new fields optional so existing setup exports remain compatible. - Add focused validation and export/import regression coverage for preset sizes, a custom target, every grounding mode, invalid values, and the missing-lorebook fallback. This should be implemented in Marinara Engine's Game setup types, serializer/parser, server validation, and wizard restoration path. World Maps already accepts these request values, so no Marinara-Agents package change or rebuild should be required. ## Alternatives considered - Keep resetting to defaults after import. This makes a reusable setup silently differ from the setup that was exported. - Store these options in the World Maps package. The package consumes them, but the New Game wizard and reusable setup file are Engine-owned. - Preserve only the size preset. That would lose an exact custom target such as 10 places. ## Additional context - Follow-up to #3767, which intentionally limited the earlier setup-export change to the creation prompt and combat style. - Related to #4783, which added the Engine-owned custom place target and forwards it to World Maps during New Game setup. - Reported by a user who relies on reusable Game Mode setup exports and noticed that the imported World Maps draft options do not match the exported setup. ## Template check Please **uncheck (untick)** the box below before submitting so we know you read the template. It is intentionally pre-checked: - [ ] I DID NOT read this template and provide the requested details.
Author
Owner

@SpicyMarinara commented on GitHub (Aug 20, 2026):

Claiming this for the current staging issue sweep as @SpicyMarinara. I’ll keep the patch focused on the existing setup contract, validation, import restoration, and readable summary, with a draft PR linked as soon as the first implementation commit is available.

<!-- gh-comment-id:5361535055 --> @SpicyMarinara commented on GitHub (Aug 20, 2026): Claiming this for the current staging issue sweep as @SpicyMarinara. I’ll keep the patch focused on the existing setup contract, validation, import restoration, and readable summary, with a draft PR linked as soon as the first implementation commit is available.
Author
Owner

@SpicyMarinara commented on GitHub (Aug 20, 2026):

Resolved on staging by #5338.

<!-- gh-comment-id:5361776095 --> @SpicyMarinara commented on GitHub (Aug 20, 2026): Resolved on staging by #5338.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Pasta-Devs/Marinara-Engine#2951
No description provided.