No description
  • GDScript 99.1%
  • Dockerfile 0.7%
  • GDShader 0.2%
Find a file
McNieps 5dffc43c66
All checks were successful
/ build (push) Successful in 34s
/ build-image (push) Successful in 3s
Regenerate catalog.json/keywords.json for the effect-algebra content migration
Every rune/weapon clause in data/ now uses Clause.effect (Sequence/Gated/
Spend) instead of the old effects list + Payment; describe() renders the
same tokens as before, so this export is expected to be a no-op diff except
where the underlying content also changed for the in-flight charge-speed
unification (haste/slow/charge_rate).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-07-26 12:16:22 +02:00
.forgejo/workflows Fix asset corruption and builder-image race from first export test 2026-07-18 17:06:23 +02:00
addons/script-tabs feat: equip scene with catalog grid, card sizing, and autoload scaffolding 2026-05-30 15:32:08 +02:00
assets Merge WeaponCard into one scene, expand TeamPanel into TeamCard 2026-07-23 22:41:16 +02:00
data Regenerate catalog.json/keywords.json for the effect-algebra content migration 2026-07-26 12:16:22 +02:00
docker/client-builder Self-contained export: vendor battle-engine + data, bundle luajit 2026-07-18 16:41:44 +02:00
scenes Merge WeaponCard into one scene, expand TeamPanel into TeamCard 2026-07-23 22:41:16 +02:00
scripts Merge WeaponCard into one scene, expand TeamPanel into TeamCard 2026-07-23 22:41:16 +02:00
vendor Fold engine fire_id into batch keys, closing #23's repeat-firing gap 2026-07-18 21:43:52 +02:00
.editorconfig Initial commit 2026-05-05 21:14:39 +02:00
.gitattributes Fix asset corruption and builder-image race from first export test 2026-07-18 17:06:23 +02:00
.gitignore Add Forgejo CI pipeline for Windows client builds 2026-06-10 10:31:37 +02:00
.gitmodules Self-contained export: vendor battle-engine + data, bundle luajit 2026-07-18 16:41:44 +02:00
battle_scene_design.md Battle legibility pass: team-clause ribbon reactions, poison bubble VFX; equip/socket rewrite 2026-07-17 22:56:42 +02:00
CLAUDE.md Fold engine fire_id into batch keys, closing #23's repeat-firing gap 2026-07-18 21:43:52 +02:00
default_bus_layout.tres Close the lab loop: results panel + SFX on hit/destroy/outcome 2026-07-08 23:07:05 +02:00
export_presets.cfg Add Forgejo CI pipeline for Windows client builds 2026-06-10 10:31:37 +02:00
icon.ico Add Forgejo CI pipeline for Windows client builds 2026-06-10 10:31:37 +02:00
icon.svg Initial commit 2026-05-05 21:14:39 +02:00
icon.svg.import Initial commit 2026-05-05 21:14:39 +02:00
project.godot Close the lab loop: results panel + SFX on hit/destroy/outcome 2026-07-08 23:07:05 +02:00
README.md Standardize clause rendering: consistent keywords, triggers, and values 2026-07-08 22:55:44 +02:00
screenshot.png Merge WeaponCard into one scene, expand TeamPanel into TeamCard 2026-07-23 22:41:16 +02:00
screenshot.png.import Implement equip scene: catalog grid, drag-and-drop, and item inspector 2026-06-10 10:31:45 +02:00
TODO.md Merge WeaponCard into one scene, expand TeamPanel into TeamCard 2026-07-23 22:41:16 +02:00

Autobattler — Godot Client

Godot 4.6 front-end for the autobattler project.


What it is

  • Replay viewer: reads a BattleLog JSON produced by the battle engine and animates it. No game logic in GDScript — all combat resolution happens in the engine.
  • Lab (Phase 1, in progress): freely build any team (weapons + runes), launch a battle against an invincible dummy, watch the replay.

How to run

Open project.godot in Godot 4.6 and press F5.


Phases

Phase Scope Status
0 Replay viewer — hardcoded BattleLog, health bars + text, no art done
1 Lab scene — team builder, catalog browser, launch battle 🔧 in progress
2 Shop — between-battle draft
3 Map — hex map, travel, pre-battle loadout
4 Desk — archivist office, embeds other scenes via SubViewport

Architecture

catalog.json / keyword_definitions.json
        │
        ▼
   Catalog (autoload) ──────────────────────────────┐
        │                                            │ engine_json blobs (dev only)
        ▼                                            ▼
   EquipScene                               BattleRunner (autoload)
   ┌────────────────────────────────┐            │ OS.execute() → luajit
   │  TeamPanel   │  CatalogPanel  │            │ (→ server call in production)
   │  (drop tgts) │  (drag sources)│            ▼
   └────────────────────────────────┘       battle_log.json
        │                                            │
        │ get_team_json()                            ▼
        └───────────────────────────────────► BattleViewer

Popup system — all item/keyword popups go through PopupManager (autoload). Two tiers: InspectorPopup (persistent, draggable, multiple) and KeywordTooltip (transient, one at a time, browser-style back/forward navigation). Both live in a CanvasLayer at layer 100 — never clipped.

Clause descriptions from catalog.json are rendered to BBCode by ClauseParser. Each [keyword:x] token becomes a hoverable, clickable link that opens a KeywordTooltip with the definition from keyword_definitions.json.


Key design decisions

Decision Rationale
No game logic in GDScript Engine is authoritative; client is a viewer
BattleRunner abstracts engine call Swap OS.execute() → HTTP without touching any UI
Catalog strips engine_json from display data UI code can never accidentally use engine blobs
PopupManager owns all popup lifecycle Single place for z-ordering, positioning, hover-bridge
Dev strings as i18n msgids en.po is the copy-editing layer; no polished text hardcoded in source
ClauseParser separates tokenize / render Template system for non-SVO languages slots in without changing existing code

Folder structure

client/
  scenes/
    equip/          — lab + future campaign prep (shared equip scene, mode="lab"|"campaign")
    battle/         — replay viewer
    shop/           — Phase 2
    map/            — Phase 3
    desk/           — Phase 4
    ui/             — InspectorPopup, KeywordTooltip
    main.tscn
  scripts/
    autoloads/      — Catalog, BattleRunner, PopupManager
    replay/         — BattleLog parser + replay controller
    models/         — display-only data classes (no game logic)
    ui/             — ClauseParser and other stateless utilities
  assets/
    fonts/ icons/ sprites/ sounds/
    locales/        — .po translation files
  data/
    catalog.json             — weapons + rune patterns (engine_json present in dev build only)
    keywords.json            — id roster by category; regen-tool owned, not for display text
    keyword_definitions.json — keyword id → dev-English definition (hand-authored)
    battles/                 — sample BattleLog JSON fixtures
  project.godot
  TODO.md           — implementation spec and build checklist

Localization

All display copy lives in .po files — including English. Source code and data files use developer English as msgids (clear intent, not polished copy). en.po provides the polished English strings; fr.po, etc. provide translations.

See CLAUDE.md for the full i18n strategy, tr() rules, and the word-order template system plan for non-SVO languages.