id: eb11fe25706b47e1987b19e99634f685
parent_id: 
item_type: 1
item_id: 088737f31c514f1da21cc42c0ab6acc1
item_updated_time: 1781194669495
title_diff: "[{\"diffs\":[[1,\"Skara Brae — Project Plan\"]],\"start1\":0,\"start2\":0,\"length1\":0,\"length2\":25}]"
body_diff: "[{\"diffs\":[[1,\"# Skara Brae — Project Plan\\\n\\\n## Status: Concept Phase\\\n\\\n## Summary\\\n\\\nA fantasy-themed text-based MMORPG inspired by **Torn City**, with idle RPG elements from **Idle Fantasy** and a **RoleMaster-inspired critical hit system**. Set in the world of **The Bard's Tale I** and named after the ancient neolithic settlement on Orkney. The game transplants Torn's proven crime-economy-guild mechanics into a dark fantasy setting with real-time features expected in 2026+.\\\n\\\n---\\\n\\\n## Research Completed\\\n\\\n- Analyzed Torn City (torn.com): text-based crime MMORPG running since 2004, millions of users\\\n- Key Torn mechanics: crimes, PvP, factions, companies, properties, stock market, education, bounties, item market\\\n- Torn evolution: Crimes 2.0 (2023), real-time features, mobile apps, rich REST API with community tools\\\n- Analyzed Idle Fantasy (github.com/tristinbaker/IdleFantasy): open-source idle RPG, 23 skills, offline sessions, guild rank progression, pets, inn workers, blessings, slayer tasks\\\n- Designed hybrid combat system: Torn-scale exponential stat growth + RoleMaster-inspired open-ended d100 crit tables with level-difference caps\\\n\\\n---\\\n\\\n## Design Documents (Joplin Notes)\\\n\\\n| Note | ID | Content |\\\n|---|---|---|\\\n| [Game Concept Overview](joplin://fcd381c235694f29abf73665317a40f5) | `fcd381c235694f29abf73665317a40f5` | Torn-to-fantasy mechanic mapping, character system, core game loops, crafting deep dive, inn deep dive, pets, guilds, blessings, slayer, API design, monetization, MVP scope, roadmap |\\\n| [Combat System & Stat Scaling Design](joplin://5ff1fed180fa4b39b4cdb925f34c1008) | `5ff1fed180fa4b39b4cdb925f34c1008` | Hybrid RoleMaster + Torn City combat: exponential BIGINT stats, open-ended d100 crit tables, crit caps by level difference, crit status effects, combat formula draft |\\\n| [Idle Fantasy Inspirations](joplin://fea2d81f0414484fa4edf126f8ca17ed) | `fea2d81f0414484fa4edf126f8ca17ed` | Offline sessions, hireable NPC workers, pet buff system, guild rank progression, blessings/church, slayer tasks, quest diversity, 23-skill mapping |\\\n| [Lore & World Building](joplin://2c8e2a844da0497e8a93c820ec8901a1) | `2c8e2a844da0497e8a93c820ec8901a1` | 10 city districts, 8 key NPCs, 5-act storyline (Mangar the Dark), day/night cycle, calendar & seasonal events |\\\n| [Tech Stack & Architecture](joplin://980c3eb587294e4383474b94988f2f88) | `980c3eb587294e4383474b94988f2f88` | Rust workspace (Axum, SQLx, Redis, JWT), Vue 3 frontend, multi-repo structure, database schema, crate dependencies |\\\n| [Project Plan](joplin://088737f31c514f1da21cc42c0ab6acc1) | `088737f31c514f1da21cc42c0ab6acc1` | This document — roadmap, MVP scope, repository structure |\\\n\\\n---\\\n\\\n## Tech Stack Decision\\\n\\\n| Layer | Technology | Rationale |\\\n|---|---|---|\\\n| Backend | **Rust** + Axum + Tokio | Performance, type safety, fearless concurrency for game tick engine |\\\n| Database | PostgreSQL + SQLx + Redis | ACID for game state, Redis for cache/sessions/leaderboards |\\\n| Real-time | WebSocket (tokio-tungstenite) | Live combat, chat, notifications |\\\n| Auth | JWT + Argon2 | Stateless auth, API-friendly |\\\n| Frontend | **Vue 3** + Vite + Pinia | Reactive UI, composable patterns for game state |\\\n| Mobile | PWA via Vite plugin | Single codebase, native-like experience |\\\n| Infra | Docker + Caddy | Simple deployment, automatic HTTPS |\\\n\\\n---\\\n\\\n## Repository Structure\\\n\\\n### Decision: Multi-Repo with Common\\\n\\\nThree repositories — server, client, and a shared common library.\\\n\\\n```\\\ngithub.com/{org}/\\\n├── skara-brae-server/          # Rust backend (Axum)\\\n│   ├── crates/\\\n│   │   ├── sb-api/             # HTTP + WebSocket server\\\n│   │   ├── sb-core/            # Game engine (combat, crit tables, skills, pets, crafting)\\\n│   │   ├── sb-db/              # Database layer (SQLx + PostgreSQL)\\\n│   │   ├── sb-auth/            # JWT + Argon2 authentication\\\n│   │   └── sb-shared/          # Server-internal shared types, errors, constants\\\n│   ├── migrations/             # SQL migrations\\\n│   ├── Cargo.toml              # Workspace root\\\n│   └── docker-compose.yml\\\n│\\\n├── skara-brae-client/          # Vue 3 frontend\\\n│   ├── src/\\\n│   │   ├── views/              # Page components\\\n│   │   ├── components/         # Reusable UI components\\\n│   │   ├── stores/             # Pinia stores\\\n│   │   ├── composables/        # Vue composables\\\n│   │   └── styles/             # Dark fantasy theme\\\n│   ├── package.json\\\n│   └── vite.config.ts\\\n│\\\n└── skara-brae-common/          # Shared between client and server\\\n    ├── game-data/              # Adventure templates, item definitions, crit tables, recipes (JSON/TOML)\\\n    ├── api-types/              # Shared API request/response type definitions\\\n    └── constants/              # Game constants, formula parameters, stat caps\\\n```\\\n\\\n### Rationale\\\n\\\n- **Independent deployment**: Server deploys without rebuilding client. Client deploys to CDN independently.\\\n- **Separate CI/CD**: Rust compilation (slow) doesn't block Vue linting (fast).\\\n- **Common repo**: Both client and server need game data (item definitions, crit tables, adventure templates) and API types. One source of truth.\\\n- **Versioning**: Client pins to specific server API version. Common has its own versioning for content updates.\\\n- **Game data as content**: Non-programmers can update adventure templates, crit tables, item stats via PR on `skara-brae-common` without touching server or client code.\\\n\\\n### Dependency Flow\\\n\\\n```\\\nskara-brae-common\\\n        ↓ (git submodule or npm/crates.io dependency)\\\nskara-brae-server  ←→  skara-brae-client\\\n        ↓                      ↓\\\n   (REST + WS API)      (API types from common)\\\n```\\\n\\\n---\\\n\\\n## MVP Scope (Phase 1)\\\n\\\n1. User registration, authentication, character creation (race + class)\\\n2. Basic stat/skill system with training (BIGINT stats)\\\n3. Adventure system (5-10 adventures across difficulty tiers)\\\n4. Turn-based combat engine with RoleMaster-inspired crit tables\\\n5. Basic economy: inventory, bazaar (buy/sell), bank\\\n6. Guild creation and membership\\\n7. REST API + basic Vue.js frontend\\\n8. Real-time notifications via WebSocket\\\n9. Offline adventure rewards collection\\\n10. Basic crafting (2-3 professions: blacksmithing, alchemy, cooking)\\\n\\\n---\\\n\\\n## Roadmap\\\n\\\n- **Phase 2**: PvP arena, guild wars, properties, education system, pets, blessings\\\n- **Phase 3**: Full storyline/quests, dynamic world events, day/night cycle, inn workers, slayer tasks\\\n- **Phase 4**: Mobile app (Capacitor), merchant ventures (stock market), advanced crafting (all 12 professions), pet breeding\\\n- **Phase 5**: Community API, mod support, tournament system\\\n\\\n---\\\n\\\n## Open Questions\\\n\\\n- [ ] Art style / visual direction (text-only vs. illustrated UI elements)\\\n- [ ] Game clock speed (how many real hours per game day?)\\\n- [ ] Monetization specifics (patron tier pricing)\\\n- [ ] Hosting infrastructure (self-hosted vs. cloud)\\\n- [ ] Whether to use Nuxt (SSR) or plain Vue (SPA)\\\n- [ ] Offline session balance: how long should adventures continue while logged out? (1 hour like Idle Fantasy? Or based on remaining energy?)\\\n- [ ] Blessing tuning: duration ranges, effect scaling, cooldown between blessings\\\n- [ ] Worker pricing: gold-per-hour rates for hireable inn workers\\\n- [x] ~~Rebirth/prestige system~~ → **Deferred**: stats only go up for now, revisit with player base\\\n- [x] ~~Monorepo vs multi-repo~~ → **Multi-repo**: server, client, common\\\n- [x] ~~Game data location~~ → **skara-brae-common repo** (shared between client and server)\"]],\"start1\":0,\"start2\":0,\"length1\":0,\"length2\":7418}]"
metadata_diff: {"new":{"id":"088737f31c514f1da21cc42c0ab6acc1","parent_id":"d1892c7c531848f5a5a3ac5e1749f7cf","latitude":"0.00000000","longitude":"0.00000000","altitude":"0.0000","author":"","source_url":"","is_todo":0,"todo_due":0,"todo_completed":0,"source":"joplin-desktop","source_application":"net.cozic.joplin-desktop","application_data":"","order":1781185216157,"markup_language":1,"is_shared":0,"share_id":"","conflict_original_id":"","master_key_id":"","user_data":"","deleted_time":0},"deleted":[]}
encryption_cipher_text: 
encryption_applied: 0
updated_time: 2026-06-11T16:26:30.964Z
created_time: 2026-06-11T16:26:30.964Z
type_: 13