docs: rewrite Home as clean index with scope/use-case per page

2026-07-05 13:51:28 +08:00
parent af688659d1
commit d7518f5e56
+120 -24
@@ -1,35 +1,131 @@
# Tekton Dash Armageddon
Developer wiki for the Tekton Dash Armageddon project.
<a id="top"></a>
## Clone
Developer wiki for the Tekton Armageddon project -- Godot 4.7 multiplayer game with Nakama Lua backend, Gitea CI/CD, and hot-patching.
SSH is preferred:
---
```bash
git clone git@ssh.git.klud.top:danchie/tekton.git
```
## Architecture - Client
HTTPS also works:
**File:** `Architecture-Client`
**Scope:** Godot client codebase -- scenes, scripts, managers, player controllers
**Covers:**
- Core game flow (boot → auth → lobby → match → spawn)
- 70+ Autoload singletons (`scripts/managers/`) grouped by domain
- Player controller delegation pattern (`player.gd` + `PlayerMovementManager` + `PlayerInputManager`)
- UI component tree (`scenes/ui/`)
- Economy/gacha/skin management modules
- Dependency graph showing how managers connect
```bash
git clone https://git.klud.top/danchie/tekton.git
```
**Use when:** Understanding how the Godot client is structured, what manager handles what, or where to add a new game feature.
First-time SSH setup:
[Back to top](#top)
- [Linux](./SSH-Setup-Linux)
- [macOS](./SSH-Setup-macOS)
- [Windows](./SSH-Setup-Windows)
---
## Pages
## Architecture - Server
- [Architecture - Client](./Architecture-Client) — Core Godot game loop, Singletons, and Node dependencies.
- [Architecture - Server](./Architecture-Server) — Nakama Lua backend, Wallets, and CI/CD Build pipelines.
- [Skin Creation Workflow](./Skin-Creation-Workflow) — Authoring skin materials and registering them in the catalog.
- [Nakama Deployment](./Nakama-Deployment) — Pushing the shop/gacha backend to the Nakama VPS.
- [Patch Release Workflow](./Patch-Release-Workflow) — Building, versioning, and shipping patches to live clients.
- [Home](./Home) — Project overview (this page).
- [SSH Setup — Linux](./SSH-Setup-Linux) — Setup SSH key and clone on Linux.
- [SSH Setup — macOS](./SSH-Setup-macOS) — Setup SSH key and clone on macOS.
- [SSH Setup — Windows](./SSH-Setup-Windows) — Setup SSH key and clone on Windows.
**File:** `Architecture-Server`
**Scope:** Nakama Lua backend topology, authentication, wallet, admin hierarchy
**Covers:**
- Nine Lua module dependency tree (utils → economy/core/admin → daily/user/leaderboard/inbox/gacha)
- Authentication sequence: login → ban check → wallet init
- Wallet & economy flow: all currency changesets, IAP validation, item purchases
- Gacha flow: pity system (90 pull guarantee), drop rates (60% common → 1% real prize)
- Mail/inbox: global mail vs personal mail, reward claiming
- Admin role hierarchy (player → moderator → admin → owner)
- Storage collections overview (15 collections)
- Deployment topology diagram
- Quick reference table of all 48 registered RPCs
**Use when:** Understanding server-side architecture, auth flow, or browsing the module dependency graph.
[Back to top](#top)
---
## Nakama Server API
**File:** `Nakama-Server-API`
**Scope:** Complete per-function reference (1963 lines)
**Covers:**
- Every registered RPC (48 total) with full parameter table, return JSON schema, error strings
- Every after-hook with trigger event, auth context, side effects
- Every storage read/write per function
- Wallet changesets for every transaction
- All storage collections with schemas, keys, permission bits
- Error strings indexed by module (50+ unique errors)
- Role/guard function reference
**Use when:** Calling an RPC from the Godot client and need exact payload format, response shape, and error handling.
[Back to top](#top)
---
## Patch Release Workflow
**File:** `Patch-Release-Workflow`
**Scope:** CI/CD pipelines for hot patches and binary releases
**Covers:**
- Two pipeline comparison (deploy_patch.yml vs ci.yml)
- Infrastructure: Gitea instance, patch delivery via raw endpoint, release assets
- Hot patch CI: version bump → export-pack → force-push to patches branch → player auto-download
- Binary release CI: tag push → export all 3 platforms → zip → upload to Gitea release
- Cleanup: removing duplicate release assets, cancelling stale CI runs
- Agent-automated workflow (Hermes cron job pattern)
- Troubleshooting: every known CI failure (zip missing, export templates, gitea-pages token expiry)
**Use when:** Shipping a new version, fixing a CI failure, or understanding the patch delivery pipeline.
[Back to top](#top)
---
## Skin Creation Workflow
**File:** `Skin-Creation-Workflow`
**Scope:** End-to-end skin authoring, registration, and deployment
**Covers:**
- Material creation with Skin Shader Generator (.tres export)
- Client registration: `skin_manager.gd` SKIN_CATALOG entry format (slot modes: override/overlay, multi-mesh)
- 5 steps from material → catalog → deploy
- Server registration: `economy.lua` SHOP_CATALOG_DEFS with all 12 items and prices
- Existing catalog listing (4 hat, 4 pant, 4 glove items)
- Gacha prize registration: `gacha.lua` real_prize_catalog + pools
- Troubleshooting: outline shader preservation, material path issues, purchase errors
**Use when:** Adding a new cosmetic item, configuring shop prices, or setting up gacha-exclusive skins.
[Back to top](#top)
---
## Nakama Deployment
**File:** `Nakama-Deployment`
**Scope:** Pushing backend changes to the Nakama server
**Covers:**
- SSH into VPS
- Copy updated Lua files into Nakama container
- Restart or hot-reload Nakama
**Use when:** You've edited economy/shop/gacha Lua files and need them live on the server.
[Back to top](#top)
---
## SSH Setup
**Files:** `SSH-Setup-Linux`, `SSH-Setup-macOS`, `SSH-Setup-Windows`
**Scope:** One-time SSH key configuration per platform
**Covers:**
- Generating SSH key
- Adding public key to Gitea account
- Cloning with `git clone git@ssh.git.klud.top:danchie/tekton.git`
**Use when:** First-time project setup on a new machine.
[Back to top](#top)