ZionGames Docs

Home / Zion Modules / Zion Console Menu

๐ŸŽฎ Zion Console Menu

Version 1.1.0 โ€” a complete, controller-ready UI Toolkit menu foundation for Unity 6.

Save-System Integration

Version 1.1.0 ships Save Game and Load Game user interfaces plus an asynchronous provider contract. Zion Console Menu remains standalone and does not define a production save format.

Architecture

The package owns presentation, focus, confirmation and operation feedback. Your provider owns persistence, slot validity, serialization, scene selection and data restoration.

Layer Responsibility
Zion Console Menu Save and Load screens, slot presentation, focus, confirmation dialogs and disabled states
IZionSaveSlotProvider Slot metadata, capability checks and asynchronous Save, Load and Delete calls
Project save system Files or cloud records, serialization, validation, migration and restored gameplay state
ZionGameFlowBridge Optional scene transitions, loading-overlay hooks and transition failures

Provider Contract

Implement IZionSaveSlotProvider in your save-system or optional integration assembly. Version 1.1.0 uses this contract:

IReadOnlyList<ZionSaveSlotInfo> GetSlots();
bool CanSave(string slotId);
bool CanLoad(string slotId);
bool CanDelete(string slotId);
Task<ZionSaveOperationResult> SaveAsync(string slotId);
Task<ZionSaveOperationResult> LoadAsync(string slotId);
Task<ZionSaveOperationResult> DeleteAsync(string slotId);

Keep slot identifiers stable. The UI passes SlotId back to the provider; it does not infer filenames, indexes or storage paths.

Slot Metadata

Return one ZionSaveSlotInfo item for each visible slot. Version 1.1.0 can display:

Field Meaning
SlotId Stable provider identifier used by all operations
DisplayName Player-facing slot label such as Slot 1
HasData Whether the slot contains valid loadable data
SceneName Player-facing location or scene label
Timestamp Formatted save time supplied by the provider
PlayTime Formatted elapsed time supplied by the provider

Production Provider Setup

  1. Create a MonoBehaviour in your save-system or optional integration assembly.
  2. Implement IZionSaveSlotProvider and return the slots the menus should show.
  3. Make CanSave, CanLoad and CanDelete reflect current data validity and project rules.
  4. Return a clear success or failure ZionSaveOperationResult from every asynchronous operation.
  5. Assign the same provider component to Provider Source on SaveMenu and LoadMenu.
  6. Run Full Validation and resolve any missing-provider diagnostic.
A production provider can wrap local files, an existing framework, console platform storage or a cloud service. Keep platform-specific persistence outside the Zion Console Menu core assembly.

Save Flow

  1. SaveMenu requests the current slot list.
  2. The player selects a slot for which CanSave returns true.
  3. An occupied slot opens an overwrite confirmation.
  4. After confirmation, the screen calls SaveAsync with the selected slot identifier.
  5. After success, the screen refreshes metadata and Continue availability.

Load Flow

  1. LoadMenu displays all slots but enables only slots allowed by CanLoad.
  2. The selected slot identifier is passed to LoadAsync.
  3. The provider validates the stored data before applying it.
  4. The provider owns or coordinates the required scene transition.
  5. Failures return a clear result and leave the menu usable.

Delete Flow

  1. Delete is shown or enabled only when CanDelete returns true.
  2. The menu opens a Destructive confirmation with Cancel focused.
  3. After confirmation, DeleteAsync removes only the selected slot.
  4. The screen refreshes slot metadata and Continue availability.

Continue Availability

Continue remains decoupled through IZionContinueAvailabilityProvider. A save integration may implement both provider contracts on one component or coordinate separate components.

The Continue provider exposes:

  • HasContinueData
  • ContinueAvailabilityChanged

After Save or Delete, notify the Continue path so the Main Menu updates without requiring a scene reload.

Confirmation Integration

Use the included confirmation overlay for overwrite and delete. Keep the Confirmation Dialog UIDocument at sort order 90 and the virtual cursor at 100. Delete uses the Destructive type so Cancel receives initial focus.

Demonstration Provider

ZionDemoSaveAvailability is a small PlayerPrefs-based demonstration. When available, the Setup Wizard can create Demo Save Provider (Demo Only) and assign it to both slot menus.

  • It exposes three test slots.
  • It demonstrates empty and occupied slot states.
  • It supports Save, Load and Delete for menu testing.
  • It can drive Continue availability in the demo.
Do not use the demo provider for production progress. Replace it with a provider owned by your project or save-system integration.

Provider Checklist

  • GetSlots returns stable identifiers and predictable ordering.
  • HasData agrees with CanLoad and CanDelete.
  • All asynchronous operations complete exactly once.
  • Failure results contain a useful player-facing or diagnostic message.
  • Save over occupied data is confirmed before writing.
  • Delete removes only the selected slot.
  • Slot metadata and Continue availability refresh after state changes.
  • Load coordinates scene readiness before applying gameplay data.
  • Cancellation never invokes the provider operation.
For setup problems, continue to Troubleshooting .