Gallery

From Kevin-Liu-01/CoTFly · View interactive version

Gallery is an AI agent skill from the GitHub repository Kevin-Liu-01/CoTFly. Build and verify the public Tank Gallery, its technical dossiers, diagnostic overlays, and exact-surface markup review packets.

How to use this skill

Skill file

claude-of-tanks / src/gallery

Purpose

<!-- agent-docs:fill:purpose -->

Present every playable first-party vehicle as a searchable live Three.js

specimen without duplicating the canonical fleet registry or combat metadata.

Mental model & key files

<!-- agent-docs:fill:model -->

catalog.ts derives read-only search, ratings, technical copy, and the versioned

copy-data record from vehicle specs. overlays.ts turns canonical armor plates,

module boxes, and crew boxes into disposable diagnostic geometry;

viewGlyphs.ts owns the exhaustive camera-view icon vocabulary.

surfaceMarkup.ts owns live triangle/patch selection, articulation ownership,

review annotations, JSON, and PNG capture. gallery.ts owns the separate-page

renderer, vehicle state, camera, articulation, URL, DOM, and browser automation

contract. gallery.html and gallery.css own the public surface;

docs/GALLERY.md owns its documented contract.

Patterns to follow / invariants

<!-- agent-docs:fill:patterns -->

never add a gallery-only roster or balance table.

playable game's boot-critical graph.

visible and copyable.

with the previous vehicle.

non-mutating, and clear every runtime highlight before disposing a vehicle.

visible focus, reduced-motion behavior, and the __TANK_GALLERY probe API.

Common tasks → first action

<!-- agent-docs:fill:tasks -->

node src/gallery/catalog.selftest.mjs.

verify hull- versus turret-local ownership, then select the live volume in a

browser.

test face/patch scope, additive selection, ownership, focus, JSON, and PNG in

the browser.

with agent-browser; test search, all five layers, selection, copy actions,

and URL restoration.

variants.

Gotchas

<!-- agent-docs:fill:gotchas -->

Importing tankFactory.ts registers the complete expansion fleet before the

browser reads ALL_TANK_IDS; tests must reproduce that import order. Armor

plates and internal volumes are diagnostic combat data, not visible-mesh

extractions or real-world engineering claims. Turret-local overlays must remain

children of rig_turret so live articulation cannot desynchronize them.

The legacy /surface-studio path is redirect-only; do not recreate a second

viewer or authoring state owner.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.