Skip to content

Commit 6e1ad6d

Browse files
author
DavidQ
committed
Level 09.03 — standardize asset taxonomy to type-first buckets and reserve nested platform grouping only where needed & Level 09.04 — simplify asset structure by removing redundant data/platform containers
1 parent 5c16a80 commit 6e1ad6d

411 files changed

Lines changed: 755 additions & 704 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

docs/dev/CODEX_COMMANDS.md

Lines changed: 28 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,30 @@
1-
MODEL: GPT-5.4
1+
MODEL: GPT-5.4
22
REASONING: high
33

4-
COMMAND GOAL:
5-
Create BUILD_PR_LEVEL_09_02_ASSET_OWNERSHIP_NORMALIZATION as a docs-first, repo-structured bundle
6-
that corrects owner-specific asset placement across games, samples, and tools.
4+
GOAL:
5+
Simplify asset structure by removing redundant container layers.
6+
7+
RULES:
8+
- eliminate data/ if it is just a wrapper
9+
- eliminate platform/ as default container
10+
- keep only type-first folders under assets/
11+
- allow nested grouping only when needed
12+
13+
TARGET STRUCTURE:
14+
assets/
15+
palettes/
16+
sprites/
17+
tilemaps/
18+
19+
OPTIONAL:
20+
assets/sprites/platform/
21+
assets/tilemaps/platform/
22+
23+
CONSTRAINTS:
24+
- preserve files
25+
- update references
26+
- do not touch runtime code
27+
- one PR scope only
28+
29+
OUTPUT:
30+
ZIP to <project folder>/tmp/

docs/dev/COMMIT_COMMENT.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
build(assets): normalize owner-specific platform asset placement under owner assets roots
1+
Level 09.04 — simplify asset structure by removing redundant data/platform containers

docs/dev/NEXT_COMMAND.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
1-
PLAN_PR_LEVEL_11_2_RECONCILIATION_LAYER_FOUNDATION
1+
# Validate BUILD_PR_LEVEL_09_03_ASSET_BUCKET_TAXONOMY_STANDARD
2+
rg -n ""assets/platform/"" games samples tools src tests --glob '!start_of_day/**'
3+
node tests/tools/VectorAssetSystem.test.mjs
Lines changed: 1 addition & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1 @@
1-
BUILD_PR_LEVEL_09_02_ASSET_OWNERSHIP_NORMALIZATION
2-
3-
Moved owner-specific asset payloads
4-
games/Asteroids/platform/assets/palettes/asteroids-hud.palette.json => games/Asteroids/assets/platform/palettes/asteroids-hud.palette.json
5-
games/Asteroids/platform/assets/parallax/asteroids-overlay.parallax.json => games/Asteroids/assets/platform/parallax/asteroids-overlay.parallax.json
6-
games/Asteroids/platform/assets/parallax/asteroids-title.parallax.json => games/Asteroids/assets/platform/parallax/asteroids-title.parallax.json
7-
games/Asteroids/platform/assets/sprites/asteroids-demo.sprite.json => games/Asteroids/assets/platform/sprites/asteroids-demo.sprite.json
8-
games/Asteroids/platform/assets/tilemaps/asteroids-stage.tilemap.json => games/Asteroids/assets/platform/tilemaps/asteroids-stage.tilemap.json
9-
games/Asteroids/platform/assets/tilesets/asteroids-ui.tileset.json => games/Asteroids/assets/platform/tilesets/asteroids-ui.tileset.json
10-
games/Asteroids/platform/assets/vectors/asteroids-asteroid-large.vector.json => games/Asteroids/assets/platform/vectors/asteroids-asteroid-large.vector.json
11-
games/Asteroids/platform/assets/vectors/asteroids-asteroid-medium.vector.json => games/Asteroids/assets/platform/vectors/asteroids-asteroid-medium.vector.json
12-
games/Asteroids/platform/assets/vectors/asteroids-asteroid-small.vector.json => games/Asteroids/assets/platform/vectors/asteroids-asteroid-small.vector.json
13-
games/Asteroids/platform/assets/vectors/asteroids-ship.vector.json => games/Asteroids/assets/platform/vectors/asteroids-ship.vector.json
14-
games/Asteroids/platform/assets/vectors/asteroids-title.vector.json => games/Asteroids/assets/platform/vectors/asteroids-title.vector.json
15-
16-
Updated references in active surfaces
17-
- tools/Asset Browser/main.js
18-
- tools/shared/asteroidsPlatformDemo.js
19-
- tools/shared/vectorAssetSystem.js
20-
- tools/templates/starter-project-template/README.md
21-
- tools/templates/starter-project-template/config/starter.project.json
22-
- tests/tools/VectorAssetSystem.test.mjs
23-
- docs/specs/asset_usage_contract.md
24-
25-
Classification result
26-
- Game-owned moved: Asteroids platform asset payloads
27-
- Sample-owned moved: none found
28-
- Tool-owned moved: none found
29-
- Truly shared assets requiring retention outside owner roots: none found in scanned owner scopes
30-
31-
Out-of-scope preserved
32-
- no platform/runtime code moved
33-
- no engine abstractions moved
34-
- no shared infrastructure code moved
1+
Removes redundant asset container layers (data/platform) and standardizes to type-first structure.

docs/dev/reports/file_tree.txt

Lines changed: 10 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,10 @@
1-
Asset Ownership Normalization - File Tree (Changed)
2-
3-
games/Asteroids/assets/platform/
4-
palettes/asteroids-hud.palette.json
5-
parallax/asteroids-overlay.parallax.json
6-
parallax/asteroids-title.parallax.json
7-
sprites/asteroids-demo.sprite.json
8-
tilemaps/asteroids-stage.tilemap.json
9-
tilesets/asteroids-ui.tileset.json
10-
vectors/asteroids-asteroid-large.vector.json
11-
vectors/asteroids-asteroid-medium.vector.json
12-
vectors/asteroids-asteroid-small.vector.json
13-
vectors/asteroids-ship.vector.json
14-
vectors/asteroids-title.vector.json
15-
16-
Reference updates
17-
- tools/Asset Browser/main.js
18-
- tools/shared/asteroidsPlatformDemo.js
19-
- tools/shared/vectorAssetSystem.js
20-
- tools/templates/starter-project-template/README.md
21-
- tools/templates/starter-project-template/config/starter.project.json
22-
- tests/tools/VectorAssetSystem.test.mjs
23-
- docs/specs/asset_usage_contract.md
1+
docs/
2+
dev/
3+
codex_commands.md
4+
commit_comment.txt
5+
reports/
6+
change_summary.txt
7+
file_tree.txt
8+
validation_checklist.txt
9+
pr/
10+
BUILD_PR_LEVEL_09_04_ASSET_STRUCTURE_SIMPLIFICATION.md
Lines changed: 5 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,5 @@
1-
BUILD_PR_LEVEL_09_02_ASSET_OWNERSHIP_NORMALIZATION - Validation Checklist
2-
3-
Scope
4-
- [x] one PR purpose only
5-
- [x] no engine modifications
6-
- [x] no launcher/bootstrap changes
7-
- [x] no config migration as a separate lane
8-
- [x] no start_of_day modifications
9-
10-
Required work
11-
1. scan repo for owner-specific assets outside owner assets/
12-
- [x] scanned games/, samples/, tools/ for */platform/assets payloads
13-
14-
2. classify by owner
15-
- [x] game-owned: Asteroids payloads found
16-
- [x] sample-owned: none found
17-
- [x] tool-owned: none found
18-
- [x] truly shared: none found in scanned owner scopes
19-
20-
3. move only asset payloads
21-
- [x] 11 asset payload files moved from games/Asteroids/platform/assets/* to games/Asteroids/assets/platform/*
22-
23-
4. update references
24-
- [x] updated active path references to games/Asteroids/assets/platform/
25-
26-
5. remove old asset locations when safe
27-
- [x] moved payload files out of old location
28-
- [x] no owner payload files remain under games/Asteroids/platform/assets
29-
30-
6. preserve exact assets / avoid code moves
31-
- [x] payload files preserved (move only)
32-
- [x] no runtime/platform code moved
33-
34-
Command evidence
35-
- rg scan for old active paths (tools/tests/docs/specs): no stale games/Asteroids/platform/assets refs remain
36-
- node --check tools/Asset Browser/main.js : PASS
37-
- node --check tools/shared/asteroidsPlatformDemo.js : PASS
38-
- node --check tools/shared/vectorAssetSystem.js : PASS
39-
- node tests/runtime/LaunchSmokeAllEntries.test.mjs : PASS
40-
- tests/tools/VectorAssetSystem.test.mjs : blocked by existing baseline env/module resolution issue (C:/src/engine/assets/AssetRegistry.js)
41-
42-
Result
43-
- PASS (with noted baseline test-environment blocker unrelated to this move)
1+
Validation:
2+
- no data/platform nesting remains
3+
- top-level assets folders are type-only
4+
- plural naming enforced
5+
- references updated
Lines changed: 143 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,143 @@
1+
# BUILD_PR — LEVEL 09.03 ASSET BUCKET TAXONOMY STANDARD
2+
3+
## Purpose
4+
Standardize asset folder taxonomy across games, samples, and tools so ownership is clear and asset
5+
types are easy to find, package, and evolve.
6+
7+
## Decision
8+
Use **type-first buckets under each owner `assets/` folder**.
9+
10+
### Recommended pattern
11+
- `games/<GameName>/assets/`
12+
- `samples/<SampleName>/assets/`
13+
- `tools/<ToolName>/assets/`
14+
15+
Inside each owner `assets/`, use the following standard buckets:
16+
17+
- `images/`
18+
- `sprites/`
19+
- `tiles/`
20+
- `backgrounds/`
21+
- `icons/`
22+
- `audio/`
23+
- `music/`
24+
- `midi/`
25+
- `fonts/`
26+
- `data/`
27+
- `shaders/`
28+
- `ui/`
29+
- `video/`
30+
31+
## Key decision on `platform/`
32+
**Do not keep `platform/` as a default asset bucket.**
33+
34+
Reason:
35+
- `platform` describes theme/source/context, not type
36+
- it becomes a junk-drawer bucket
37+
- it overlaps with true asset types like images, audio, icons, fonts, and data
38+
- it will age poorly once MIDI/player/editor work expands the media surface
39+
40+
## What to do instead
41+
Move contents of any existing `platform/assets` into the correct type buckets under the owning scope.
42+
43+
Examples:
44+
- platform PNG/SVG art -> `assets/images/` or `assets/icons/`
45+
- platform sprite sheets -> `assets/sprites/`
46+
- platform tile maps / payload JSON -> `assets/data/` or `assets/tiles/`
47+
- platform audio FX -> `assets/audio/`
48+
- platform music tracks -> `assets/music/`
49+
- future MIDI songs / patterns -> `assets/midi/`
50+
- platform fonts -> `assets/fonts/`
51+
52+
## Allowed exception
53+
A theme/domain subfolder may exist **inside** a type bucket when needed.
54+
55+
Examples:
56+
- `assets/images/platform/`
57+
- `assets/audio/platform/`
58+
- `assets/midi/platform/`
59+
60+
This preserves theme grouping without losing type clarity.
61+
62+
## Why this is the best long-term choice
63+
This approach gives:
64+
- clear ownership
65+
- clear type grouping
66+
- easy packaging/export
67+
- easy tooling
68+
- easy future MIDI/editor support
69+
- less ambiguity than `platform/assets`
70+
71+
## Naming guidance
72+
Use plural, lowercase bucket names:
73+
- good: `images`, `icons`, `fonts`, `audio`
74+
- avoid: `img`, `snd`, `fontFiles`, `platformAssets`
75+
76+
## Classification rules
77+
### `images/`
78+
Raster and general image payloads not better classified elsewhere.
79+
80+
### `sprites/`
81+
Sprite sheets, frame atlases, sprite-specific PNG/JSON pairs.
82+
83+
### `tiles/`
84+
Tile sheets, tile atlases, tile metadata tied to tile rendering.
85+
86+
### `backgrounds/`
87+
Parallax layers, static scene backdrops, panorama payloads.
88+
89+
### `icons/`
90+
Small symbolic UI/app/tool icons.
91+
92+
### `audio/`
93+
Short sound effects and non-musical audio cues.
94+
95+
### `music/`
96+
Rendered music tracks (mp3, ogg, wav, etc).
97+
98+
### `midi/`
99+
MIDI files, patterns, sequences, and future editor/player assets.
100+
101+
### `fonts/`
102+
Font payloads and font metadata.
103+
104+
### `data/`
105+
JSON, TMX-like payloads, level data, tuning payloads, manifests.
106+
107+
### `shaders/`
108+
Shader source/assets if present.
109+
110+
### `ui/`
111+
UI skin assets not already better classified as icons/images/fonts.
112+
113+
### `video/`
114+
Video payloads.
115+
116+
## Scope
117+
Docs-first standard only.
118+
Apply to:
119+
- games
120+
- samples
121+
- tools
122+
123+
## Migration rule
124+
1. owner-specific assets stay under the owner
125+
2. remove default `platform/` asset bucket
126+
3. preserve exact payloads
127+
4. update references
128+
5. if theme grouping is needed, nest `platform/` under the correct type bucket
129+
6. do not move runtime/platform code
130+
131+
## Acceptance criteria
132+
1. owner asset folders use standard type buckets
133+
2. `platform/` is not used as a top-level default asset bucket
134+
3. assets are classified by type first
135+
4. references are updated
136+
5. future MIDI assets have a defined home: `assets/midi/`
137+
6. no runtime/platform code moved
138+
139+
## Out of scope
140+
- engine/runtime refactors
141+
- media conversion
142+
- audio pipeline redesign
143+
- MIDI engine/editor implementation
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
# BUILD_PR — LEVEL 09.04 ASSET STRUCTURE SIMPLIFICATION
2+
3+
## Problem
4+
Current structure introduces unnecessary nesting:
5+
6+
- data/platform/palettes
7+
- data/platform/sprites
8+
- data/platform/tilemap
9+
10+
Both `data/` and `platform/` are acting as containers, which creates redundancy.
11+
12+
## Decision (Simplify)
13+
Use **type-first buckets directly under assets/** with NO extra wrapper layers.
14+
15+
### Final Structure
16+
assets/
17+
palettes/
18+
sprites/
19+
tilemaps/
20+
21+
Optional grouping ONLY when needed:
22+
assets/sprites/platform/
23+
assets/tilemaps/platform/
24+
25+
## Rules
26+
1. REMOVE `data/` when it only acts as a container
27+
2. REMOVE `platform/` as a default container
28+
3. KEEP only TYPE folders at the top level
29+
4. USE nested grouping only when necessary
30+
31+
## Examples
32+
33+
### ❌ Over-engineered
34+
assets/data/platform/palettes/
35+
assets/data/platform/sprites/
36+
assets/data/platform/tilemap/
37+
38+
### ✅ Correct
39+
assets/palettes/
40+
assets/sprites/
41+
assets/tilemaps/
42+
43+
### ✅ With grouping (only if needed)
44+
assets/sprites/platform/
45+
assets/tilemaps/platform/
46+
47+
## Naming adjustments
48+
- tilemap → tilemaps (plural standard)
49+
- palette → palettes
50+
51+
## Why this is better
52+
- eliminates double-container problem
53+
- faster navigation
54+
- cleaner mental model
55+
- consistent with tooling expectations
56+
- avoids future refactor when MIDI/tools expand
57+
58+
## Scope
59+
Applies to:
60+
- games
61+
- samples
62+
- tools
63+
64+
## Acceptance Criteria
65+
- no `data/platform` chains
66+
- top-level folders are TYPE buckets only
67+
- plural naming enforced
68+
- optional grouping only when justified

docs/specs/asset_usage_contract.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Asset Usage Contract
1+
# Asset Usage Contract
22

33
## Purpose
44
Define the shared asset and shared palette handoff contract for first-class tools under `tools/`.
@@ -58,7 +58,7 @@ Normalized shape:
5858
{
5959
"assetId": "asset-vector-player",
6060
"assetType": "vector",
61-
"sourcePath": "../../games/Asteroids/assets/platform/vectors/asteroids-ship.vector.json",
61+
"sourcePath": "../../games/Asteroids/assets/vectors/asteroids-ship.vector.json",
6262
"displayName": "Asteroids Ship Vector",
6363
"tags": ["Vector Assets"],
6464
"metadata": {
File renamed without changes.

0 commit comments

Comments
 (0)