Convergence.Game
GridGame.Unity
Convergence: Fall of Somnolith, a portrait-mobile tactics RPG in Unity 6: Terra Battle pincer combat on a Grandia II-style timeline that only moves when you act, plus a Final Fantasy-style camp, all on a deterministic engine-free battle core.
https://img.shields.io/badge/status-in%20development-orange.svg
There is no public build or store listing yet. Build it from source with the Quick start below.
Scope
SPEC.md is the complete product on paper: every epic, feature and story, built or not, the release sequence (1.0 on Google Play, 1.1 the whole world, 1.2 iOS and cloud save, 1.3 the finished game) and what is never in the game. RELEASE.md is the current finish line, milestone MS-27: Convergence 1.0 on Google Play.
Why
- Position is the only weapon: movement never deals damage, so every drop asks whether it finishes a line.
- Thinking time is free. The clock advances only when you commit an action, so a battle plays the same on a five-minute bus ride or an all-night session.
- Every battle is reproducible: the rules are pure, seeded C# with no
UnityEngine, so a bot can soak-test every stage in seconds. - Content changes are data edits, not code: classes, abilities, items, recipes, stages and the campaign are JSON validated at load.
- Nothing hides in the Unity Editor: one empty scene, and the whole game is built in code.
Features
Battle
- A 6 by 8 grid. Drag a hero one tile at a time, cardinal only; anyone in the way slides into the tile you just left, friend or foe.
- Pincers: trap enemies in an unbroken, ally-free straight line between two heroes to strike, with chains, supporters and 2 by 2 bosses that need a width-wide pincer.
- An act-advanced timeline. Enemy icons load toward the act line, hits in the pushback zone shove their turns back, and spell casts ride a second lane below it where hits stagger and cancel them.
- A shared, capped bank of mana orbs that pincers, crits, steals and interrupts refill, spent on a per-hero ability bar of spells, skills and items.
- Elements and status effects (Frozen, Wet, Steam, Shock, Sleep, Silence and more), traps, knockback, physical blocks, movable tiles, Power Amplifier tiles and board pickups such as Heart Tonic and Mana Shard.
- Weapon and armor wear: weapons shatter with a visible warning, and a backup weapon swaps in automatically.
- Optional Auto mode where the built-in bot plays the battle for you.
Camp and campaign
- Ten themes and 25 hand-built stages (five themes, then five postgame themes), each theme opening with a skippable story crawl.
- A Final Fantasy-style Camp menu: Adventure, Items, Status, Equip, Abilities, Party, Merchant, Blacksmith (forge, upgrade, salvage, repair, Masterwork crafting), Alchemist (brew, enchant, heal), Inn, Caravan upgrades, Summon Circle, Bounties, Bestiary, Settings and Save and Quit.
- Shipped content: 64 hero and 114 enemy classes, 197 abilities, 243 items, 154 recipes, 37 drop tables, 6 skill trees, 13 buffs, 7 traps and 5 bounties.
- Original synthesized sound effects for every event, five music tracks, and pixel-art icons.
Quick start
Prerequisites:
- Unity 6000.4.3f1 (the Editor must be closed for any batchmode build)
- .NET SDK 10 for the rules tests
- Python 3 for the harness and checks
- Node.js only for the WebGL check
Clone, test and build the Windows development player:
git clone https://github.com/mindattic/GridGame.Unity.git cd GridGame.Unity pwsh tools/test.ps1 pwsh tools/build.ps1 .\Build\Windows\Convergence.exe
You should see the title screen. Choose New Game, pick a slot and you land at the Camp menu; Adventure starts the first stage. The window letterboxes to portrait and never stretches. Mouse acts as your finger, and Esc is back or pause.
To publish a Release build to C:\Apps\Convergence instead, run run.bat (what the Desktop shortcut runs). It asks first: 1) Deploy & Run rebuilds, publishes and launches it; 2) Run launches the build already published. Unattended, run tools\run.ps1 (add -Launch to start it afterwards, -Force to rebuild even when up to date).
Commands
pwsh tools/test.ps1 # rules + meta tests, bot soak over every stage, glyph and asset checks pwsh tools/test.ps1 -Compile # + Unity batchmode compile check (Editor must be closed) pwsh tools/test.ps1 -Ui # + build the player and run tools/uicheck.py against it pwsh tools/build.ps1 # Windows development player -> Build/Windows pwsh tools/build.ps1 -Release # Windows Release player pwsh tools/build.ps1 -Target Android # APK -> Build/Android pwsh tools/build.ps1 -Target WebGL; node tools/webcheck.mjs # browser build + Playwright check run.bat # menu: 1) Deploy & Run (rebuild Release, publish to C:\Apps\Convergence, launch) 2) Run pwsh tools/run.ps1 [-Launch] [-Force] # the same deploy, no menu tools\launch.bat # deploy, then pick Normal Play or Demo + Capture (muted by default) pwsh tools/make-desktop-shortcut.ps1 # Desktop shortcut to run.bat (the menu)
Harness and checks (they launch the development player with its automation endpoint):
All of these launch muted by default (see Audio mute below).
python tools/harness.py smoke # title -> new game -> camp -> battle on Auto -> results
python tools/harness.py sweep # screenshot + layout-audit every Camp screen
python tools/harness.py campaign [N] # play N consecutive stages (default 6)
python tools/harness.py clips [N] # N random-stage battle clips (needs -capture-config to record)
python tools/harness.py durability # weapon-wear badge and shatter-warning check
python tools/harness.py bestiary # bestiary drop check
python tools/harness.py stress [HOURS] # unattended soak (default 4h)
python tools/harness.py shot NAME # screenshot the running player
python tools/harness.py call PATH k=v # raw endpoint call, e.g. call state
python tools/uicheck.py # behavioral UI assertions against the running player
python tools/androidcheck.py # play a session on a device or emulator
python tools/records.py [dir] # balance picture from JSON battle records
python tools/telemetry_report.py RUN # endless-run telemetry report (win rates, heatmaps, outliers + repro seeds)
# -> artifacts/endless/RUN/report.md + report.html
Each worktree's harness gets its own port derived from its path; set CONVERGENCE_PORT to override. (The old GRIDGAME_PORT and other GRIDGAME_* names still work.) Screenshots land in artifacts/<run>/.
Content and art tools: the art, audio and content authoring scripts (portraits, icons, tiles, sound effects, music, lesson images, the weapon and counter-item generators, vendor tiers, lorem placeholders, the Midjourney male-variant batch) live in the sibling GridGame.Studio repo's tools/ with the Studio app (GG-T579, GGS-T9); they find this checkout by themselves. The build gates stay here.
python ../GridGame.Studio/tools/make_sfx.py # regenerate the original sound effects python ../GridGame.Studio/tools/import_art.py # regenerate art and audio from the GridGame2026 reference project python ../GridGame.Studio/tools/make_icons.py # regenerate the pixel-art icons python tools/check_assets.py # verify every referenced asset exists python tools/check_glyphs.py # verify every UI glyph exists in the bundled fonts python tools/check_kit_icons.py # verify no hero kit has two abilities with the same icon
Player flags
| Flag | Effect |
|---|---|
-automation PORT
|
Start the development-build HTTP control endpoint (tap, drag, state, screenshot, layout audit) |
-artifacts DIR
|
Where automation screenshots and battle records go |
-demo
|
Boot into an unattended self-play loop: random party, autoplayed battles, auto-advance |
-autobattle
|
Start every battle on Auto |
-start SCREEN
|
Open directly on a named screen |
-skill N
|
Bot skill level for autoplay |
-records DIR
|
Write JSON battle records to this folder |
-telemetry
|
Enable bot telemetry |
-saveRoot DIR
|
Keep every profile under DIR/Profiles instead of the real ones (the harness passes its run folder)
|
-profile NAME
|
Play as this player profile, creating it if missing (-demo/-testmode use a throwaway profile)
|
-profiles-root DIR
|
Unity.Shared's override for the Profiles folder itself; MINDATTIC_PROFILES_ROOT does the same
|
-noDiagonalSlip
|
Turn off diagonal slip |
-capture-config PATH
|
Load MindAttic.Media.Capture trigger rules from this file |
-muted
|
Mute all audio for this session only (see Audio mute below); MINDATTIC_CLI_MUTED=1 does the same
|
How it works
Resources/Content/*.json --ContentLoader.Validate--> ContentDb
|
player input / bot --> command --> BattleEngine.Apply --+--> events
(Core, pure C#, |
seeded, deterministic) v
BattleScreen plays events back as animations + sound
|
Meta (pure C#): SaveData + camp services <--- results --+
| Layer | Where | What |
|---|---|---|
| Simulation | Assets/Convergence/Core
|
Pure C# with no UnityEngine. BattleEngine.Apply(command) returns events. Deterministic and seeded. Tuning numbers live in Core/Battle/BattleConfig.cs.
|
| Bot | Assets/Convergence/Core/Bot
|
HeroBot drives soak tests, Auto mode, hints and -demo.
|
| Meta | Assets/Convergence/Meta
|
Pure C# save model and camp services (shop, craft, repair, inn, equip, learn, party, summon, bounties); CampRoutine is the bot camp manager.
|
| Content | Assets/Convergence/Resources/Content
|
15 JSON files: every class, ability, buff, item, recipe, drop table, stage, campaign theme, trap and caravan upgrade. |
| App | Assets/Convergence/App
|
Unity presentation. One empty scene; GameApp builds everything in code with UI Toolkit and Theme.uss.
|
| Automation | Assets/Convergence/App/Automation
|
Development-build HTTP endpoint for scripted play, input injection, screenshots and layout audits. |
| Build | Assets/Convergence/Editor/ConvergenceBuild.cs
|
Batchmode build and compile-check entry points used by tools/unity.ps1.
|
No prefabs, no hand-built scenes, no Inspector wiring.
Testing
pwsh tools/test.ps1 runs the Tests/Core.Tests suite (880 tests on .NET 10, about three minutes): board rules, timeline and abilities, every catalog entry through the real engine, content validation, a bot soak over every stage with invariants checked after each command, deterministic replay, the full camp loop and a balance report. It then runs the glyph and asset checks. -Ui adds the player-level UI gate, and tools/webcheck.mjs and tools/androidcheck.py cover the WebGL and Android builds.
Capture
Convergence records itself with MindAttic.Media.Capture, through its Unity package com.mindattic.media.capture (MindAttic.Media.Capture.Unity, referenced from Packages/manifest.json as file:../../MindAttic.Media.Capture/unity/com.mindattic.media.capture). It auto-starts in Editor Play sessions and development builds. Its own README covers the engine, the rule format and the capture agent; this section is what Convergence does with it.
Prerequisites: the capture agent installed by MindAttic.Media.Capture's run.ps1 (%LOCALAPPDATA%\MindAttic\Capture\bin\capture.exe; MINDATTIC_CAPTURE_AGENT points elsewhere) and ffmpeg. Recording needs a GPU, so none of this works with --headless.
Player flags. -capture video hq records the whole session (campaign() documents -capture video screen 5 for recording a soak). -capture-config PATH loads trigger rules; Assets/StreamingAssets/capture.json (one clip from battle-start to battle-end) is never auto-loaded just because it exists, and it ships with "enabled": false.
Where files land. Recordings go to the session folder under R:\MindAttic\Media\Capture\GridGame.Unity\<session>\; harness screenshots stay in artifacts/<run>/. Preview sets go under R:\MindAttic\Media\Preview\GridGame.Unity\.
Recorded harness runs: --record. Anywhere in a harness command's args, --record adds -capture video hq to every launch and loads tools/harness.capture.json: a 30 s replay buffer, a harness-fail rule that saves the last 25 s plus 2 s after as a fail replay, and a harness-step rule that turns each step into a chapter marker (sweep, storyarc and coach raise them). When a command fails, by exception or exit 1 on a check, the harness raises harness-fail, takes a fail-COMMAND screenshot and waits for the replay before exiting. endless and clips keep their own configs.
python tools/harness.py sweep --record # session video with a chapter per step; a fail replay .mp4 if a check fails
Preview sets: --preview [TICKET]. When the command ends, pass or fail, the PNGs it wrote under artifacts/<run>/ (captioned with their file names), any failure replay and screenshot, and with --record the session video become one preview set (capture set new/add/show), opened in MindAttic.Media.Viewer. A ticket ID files the set under that ticket. Without the agent the run only warns.
python tools/harness.py coach --record --preview GG-T1008
Per-battle clips. endless N --capture writes an enabled copy of capture.json into the run folder and passes it with -capture-config, so every encounter becomes its own clip; the summary lists the clip folders. clips [N] uses the built player's capture.json, which needs "enabled": true to record.
python tools/harness.py endless 20 --capture --seed 7
The automation endpoint. While a development player records, each automation screenshot drops a chapter marker named after its PNG, and tap, click and drag add one when called with mark=1. The capture endpoint drives the engine with op=:
| Op | Parameters | Does |
|---|---|---|
marker
|
name, extra k=v as data
|
Chapter marker |
raise
|
event, extra k=v as data
|
Fires a rule event, e.g. harness-fail
|
screenshot
|
tag
|
Screenshot into the session folder |
save-replay
|
tag
|
Saves the replay buffer |
clip
|
before, after (seconds), tag
|
Saves before seconds of buffer plus after seconds more
|
status
|
Enabled, recording, session id and folder (the default op) |
Each answers {ok, error?, folder?} (and file/files for saved media); with capture off it answers {ok:false, error:"capture off"} at once.
python tools/harness.py call capture op=clip before=10 after=2 tag=combo
Audio mute
tools/launch.ps1 (and tools/launch.bat) and tools/harness.py's launch() launch muted by default: Unity.Shared's shared session mute (GG-T205), set either with the -muted command-line switch or the MINDATTIC_CLI_MUTED=1 environment variable, read once by Unity.Shared.ProfilesBootstrap before the first scene loads. Assets/Convergence/App/Services/SessionAudio.cs then zeroes AudioListener.volume for that run; nothing is written to this game's own save data, so a normal launch still has sound. Pass -Sound to tools/launch.ps1 to opt back into audio for manual play; the two switches work on their own against a built exe too:
.\Build\Windows\Convergence.exe -muted $env:MINDATTIC_CLI_MUTED = '1'; .\Build\Windows\Convergence.exe
Convergence's own music/SFX volume (Assets/Convergence/App/Services/Audio.cs, driven by Meta.SettingsSave) does not yet read from Unity.Shared profiles (that migration is the separate, larger GG-T99); this mute is a session-only override independent of it, reaching only AudioListener.volume.
Limitations
- Story crawl text is lorem ipsum placeholder until the caravan story lands.
- No public build yet; Windows, Android and WebGL are built locally.
- Several systems are built but not yet covered by a targeted test (boss phases, snake chains, enemy pincers and AI weights, Clutch, time bank and more); the bible's verified-state section tracks which.
- Not real-time, not a roguelike, not a gacha and not multiplayer, by design.
Documentation
- docs/BIBLE.md — the design bible and verified state
- docs/AMENDMENTS.md — recorded deviations from the bible
- docs/USER_STORIES.md — the story backlog and status, generated from the workflow database
- docs/PLAYTEST.md — a fifteen-minute play-test checklist
- docs/RELEASE_CHECKLIST.md — release-candidate gates, owner-only steps and night-only runs
- docs/PIXEL_ICONS.md — the pixel-art icon pipeline
- AGENTS.md — instructions and laws for coding agents working in this repo
License
No LICENSE file: all rights reserved. Third-party music, fonts and icon sources and their licenses are listed in Credits.txt: music by Kevin MacLeod (CC BY 4.0), fonts under the SIL Open Font License 1.1, and icons derived from game-icons.net (CC BY 3.0).
Part of MindAttic — see more projects at github.com/mindattic. Related: GridGame2026, the design reference this is rebuilt from, and MindAttic.Media.Capture.
Pages in this repository
- Midjourney batch (GG-T492) — Generated by python -I tools/art_batch.py from docs/ART_GAPS.md; do not hand-edit. Paste each prompt as is. Characters use --niji 5;…
- Art gap audit (GG-T491, refreshed 2026-11-23 by GG-T753) — Every missing, placeholder or reused asset that ships, ordered by how much a player sees it, with a ready-to-paste Midjourney prompt for…
- Attack-type hit sounds (GG-T556) — A landed physical hit sounds like whatever dealt it: a sword slashes, a hammer thuds, a wolf bites, a scorpion stings. Ten attack types…
- Convergence — Project Bible — A tactical grid RPG where movement deals zero damage — you drag heroes one tile at a time across a 6×8 grid, sliding displaced actors…
- Code style: file size and layout (GG-T1998) — These rules keep files small enough that two agents working on different features rarely touch the same file. python tools/polish_lint.py…
- Copy and label style (GG-T2045) — How Convergence's interface words are written: who speaks, how they are cased, which verb a button uses, which one name each concept has,…
- design/skill-hexagon/DECISIONS-2 — This brief lets the owner settle three questions in one pass. GG-T1025 already settled the SP economy, Luck, stat growth, the healing stat…
- design/skill-hexagon/GAPS — The board (Assets/Convergence/Resources/Content/skillhex.json) has 271 ability slots: 249 hold an ability and 22 are Open. Every Open slot…
- design/skill-hexagon/PLAN — Owner sign-off 2026-11-24: "this is it, perfect". The skill hexagon replaces classes-as-jobs, role trees and family trees. Heroes are…
- design/skill-hexagon/SIGNATURES — Every placed hero's Signature was checked against abilities.json and classes.json: all 65 are unique to their class, and every signature…
- design/ui-audit/BASELINE — Every screen tools/uiaudit.py walks (41: the StartScreens ids, the two results screens and the seven scenario spots), captured on one…
- design/ux-review/REVIEW — Reviewer: UI/UX (mobile games). Date: 2026-11-28. Build reviewed: main at 1231e5e0, the GG-T1857 recapture.
- Convergence design system (GG-T2044) — The one place a screen's look and behaviour is decided. It is written down from what already ships (App/UI/Tokens.cs,…
- devices/DEVICES — The phones Convergence is laid out, tuned and tested for, and the numbers each tool should use for them. The data lives in…
- Fresh-player run (GG-T494, 2026-11-20) — A brand-new profile played through the real UI for about the first hour (49 minutes of recorded play, 0:47 on the save's clock): title →…
- Icons: one style, every concept — GG-T2046 (part of GG-T1999, "Design system written down"). GG-T2050 generates the set from this inventory. The design page is…
- legal/age-ratings — Expected outcome: roughly PEGI 7 / ESRB Everyone 10+ / USK 6, with the "In-Game Purchases (Includes Random Items)" descriptor because of…
- legal/app-privacy-labels — Do you or your third-party partners collect data from this app? Answer Yes, conservatively, only if the Unity IAP check below says…
- legal/play-data-safety — Does your app collect or share any of the required user data types? Answer Yes: the Play Games cloud save sends save data and the player…
- legal/privacy-policy — Effective date: [date of first release] Developer: MindAttic ("we", "us") Contact: [privacy contact email, owner decision GG-T1558] Policy…
- legal/terms — Effective date: [date of first release] Developer: MindAttic, [legal entity name, address, country] Contact: [support email, owner…
- Music (GG-T456) — (Sound effects: SFX.md.)
- Pixel art: every game icon — The enemy pixel-art timeline sprites (Resources/Pixel, tools/make_pixel_icons.py and its eye-annotation tools) were deleted on 2026-11-03…
- plans/enchanting-and-gems — Status: plan, parked for after release (owner 2026-11-19, GG-T436). Nothing here is started.
- Play-test #1 — checklist (≈15 minutes) — Build: pwsh tools/build.ps1, then run Build/Windows/Convergence.exe (resize the window as you like — the game letterboxes to portrait and…
- The Polish Standard — Convergence's official definition of polish, its measurable rules, and the pass that runs each test cycle. Bible law: GG-LAW-14. Tickets:…
- Convergence and Prose: the story conduit (GG-T355) — Owner, 2026-11-07: "the Game handles gameplay, and Prose handles narrative"; "all dialog/conversations, descriptions, screen crawls,…
- GridGame.Unity — Release charter — A portrait-mobile tactics RPG (Terra Battle pincers on a Grandia II-style timeline, plus an FF-style Camp) for phone players, built in…
- release/Localization — What localising Convergence would take, measured on main on 2026-11-27. The counts are regex heuristics (a string with a space and three…
- release/Offline — Read-only audit by code; no device run. Paths are under Assets/Convergence/App/.
- release/SLICE_ACCEPTANCE — GG-T2106, under GG-T1992 (Complete-product acceptance) and epic GG-T1941. Each owner ask, the beat in docs/STORY_SLICE.md that delivers…
- release/StoreReadiness — What still stands between main and Google Play and the App Store: one row per item, with the status found in the repo on 2026-11-27. The…
- Release builds (GG-T478, GG-T479) — How to produce the store builds. Everything runs from the command line through tools/build.ps1, which drives Unity in batchmode through…
- Release checklist (GG-T1118) — What "release candidate" means for Convergence and where each gate lives. A candidate is ready when every gate in section 1 holds. Section…
- Release scope (GG-T392, 2026-11-16) — Owner, 2026-11-16: "we are aiming for a polished, releasable game once the story has been established; enough development of more and more…
- Skill map topology: research spike (GG-T83) — GG-T50/GG-T74 shipped six separate archetype trees in skilltrees.json, one per Role (Guardian, Warrior, Ranger, Mage, Cleric, Alchemist).…
- research/AbilityUsage — Owner: "the Abilities need to be utilized in the gameplay demos, to see if they are useful or not."
- research/EndlessStability — Same command, detached from Claude Code via WMI so the memory reaper could not kill it. The run finished, but it does not pass the…
- research/MobileGameAccessibility — GG-T1835, 2026-11-27. Owner: "need to go through the UI on every screen and review it for efficiency and correct placement; not sure if…
- research/sprite-recolor — Owner ask: colorize enemy art so a "Red" or "Albino" or rarer breed looks like a real reskin, not a hue/saturation swap. Eyes, claws,…
- research/TimelineTuning — Measured with Tests/Core.Tests/TimelineTuningSoak.cs: the first 15 campaign stages, 4 battles per stage per bot, smart (HeroBot,…
- research/TurnModes — How the modes are compared, and what each metric means: TURN_MODES.md. This file only holds the tables tools/turn_modes.py prints.
- research/VfxAssetPacks — Owner (2026-11-05): "need to find more asset packages for effects; free or otherwise as long as they fit into the paradigm of a premade…
- Sound effects: coverage audit (GG-T465) — Bible §12.0: every event gets a sound. This is the map from every event the player sees to the cue it plays, made 2026-11-20 by reading…
- Somnolith visual spec (shared: Convergence.Unity and SpaceGod) — One spec for the Somnolith / Midnight Geode satellite, so Convergence (Unity, GG-T679) and SpaceGod (Unreal, US-T458) draw the same thing.…
- Convergence (GridGame.Unity) — Product specification — In docs/ECOSYSTEM.md terms, Convergence is one of the studio's games: it owns no platform concern and builds on the platform repos in §6.
- store/README — Every image the Google Play and App Store listings need, where it lives and how to rebuild it. The listing copy (name, descriptions,…
- Store listing copy (GG-T489, launch update GG-T1523, 2026-11-27) — Launch copy for the Google Play and App Store listings (GG-T1256 slices: Commander story, front door and onboarding, Summon). It describes…
- Convergence: story (a pointer, not a source) — The story lives in Prose, not in this repo (GG-T355, owner 2026-11-07: "all dialog/conversations, descriptions, screen crawls, everything…
- Convergence: story outline (GG-T2203, was GG-T1319 and GG-T386) — What this is. The beat outline for the writer: the chapters as legs of the engine-to-engine road, which Ward-Engine each one wakes and…
- Story questions for the owner (prep for GG-T498) — Status: prepared by an agent; the owner discussion has NOT happened. GG-T498 stays open until the owner answers and the answers are…
- The Story Slice: Prologue Beat Sheet and Slice Arc — GG-T2065, under GG-T2010 (Prologue story and script) and epic GG-T1941; re-cut 2026-11-29 for the Convergence premise and the Ward-Engines…
- Gameplay trailer plan (GG-T488) — Target: one 45 s portrait (9:16, 1080x1920) cut, hard ceiling 60 s, built from -capture video hq footage of the real player and the…
- Turn modes: how they are compared — Owner, 2026-11-23: "… tested headlessly and figure out which works better for what and why and report back to me which is the most fun, I…


