Skip to content

Save System

Last Updated: 2025-01-16
Primary Source: docs/project_status.md
Status: ❌ Not Implemented (Client Vision Exists)


Overview

The Save System enables players to save their game progress with personality-specific save slots, allowing them to experience different relationship paths with the same character through different personalities.


Client Vision

Personality-Based Save Slots

Concept: Each personality (Rational, Emotional, Rebellious) has its own save slots, allowing players to:

  • Switch between personalities
  • Experience different story paths
  • Maintain separate progress per personality
  • Share some memories across personalities (optional)

Save Interface Design

Features:

  • Personality Compass (switching between personalities)
  • Save slot grid (multiple saves per personality)
  • Visual themes per personality:
    • Rational: Mint green
    • Emotional: Light pink
    • Rebellious: Yellow
  • Save metadata (timestamp, progress, thumbnail)

Implementation Requirements

Database Schema

New Tables Needed:

game_saves table

sql
CREATE TABLE game_saves (
  id UUID PRIMARY KEY,
  user_id INTEGER NOT NULL,
  personality_type VARCHAR(50) NOT NULL, -- 'rational', 'emotional', 'rebellious'
  slot_number INTEGER NOT NULL,
  save_name VARCHAR(255),
  save_data JSONB, -- Game state, progress, etc.
  created_at TIMESTAMP,
  updated_at TIMESTAMP,
  UNIQUE(user_id, personality_type, slot_number)
);

Save Data Structure

Format:

json
{
  "questProgress": {
    "questId": 123,
    "status": "in_progress",
    "progress": {}
  },
  "inventory": {
    "items": [...],
    "currency": 150
  },
  "relationshipFlags": {
    "milestone": true
  },
  "timelinePosition": "2025-01-16T10:30:00Z",
  "conversationHistory": [...]
}

API Endpoints (Planned)

Save Management

  • GET /api/saves - Get all saves for user
  • GET /api/saves/:personality - Get saves for specific personality
  • POST /api/saves - Create new save
  • PUT /api/saves/:id - Update save
  • DELETE /api/saves/:id - Delete save
  • POST /api/saves/:id/load - Load save

Integration Points

Personality System

  • Saves linked to personality type
  • Personality switching loads appropriate saves
  • Cross-personality memory sharing (optional)

Game State

  • Quest progress
  • Inventory state
  • Relationship flags
  • Timeline position
  • Conversation history

Implementation Roadmap

Phase 1: Database & Backend

  1. Create game_saves table
  2. Implement save/load service
  3. Create API endpoints
  4. Link to personality system

Phase 2: Frontend UI

  1. Build save interface (based on HTML mockup)
  2. Personality switching UI
  3. Save slot management
  4. Load save functionality

Phase 3: Integration

  1. Integrate with quest system
  2. Integrate with inventory system
  3. Integrate with relationship system
  4. Add save/load to game flow

Source Files

Primary Sources:

  • docs/project_status.md - System status

Related Files:

  • backend/src/services/personaOverlay.service.ts - Persona system
  • backend/src/models/gameSession.model.ts - Game session model (if exists)

ASO Universal Consciousness System Documentation