Skip to content

Commit 86c4e83

Browse files
committed
remove clutter
1 parent 9aca152 commit 86c4e83

115 files changed

Lines changed: 221 additions & 12016 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.

‎.gitignore‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,9 +35,6 @@ __pycache__/
3535
# Playwright MCP inspection captures
3636
.playwright-mcp/
3737

38-
# Offline Source 2 NAV decoder build output
39-
scripts/cs2-mapdata/bin/
40-
scripts/cs2-mapdata/obj/
4138
.vitest/
4239

4340
# Monorepo task cache and generated asset compression

‎AGENTS.md‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ Install browser binaries when needed with `bun run --bun playwright install chro
4646
- `packages/assets/manifest.json`: checked-in SHA-256 release manifest; regenerate with `bun run assets:prepare` after asset changes.
4747
- `apps/game/`: Vite app workspace and Vercel project root.
4848
- `turbo.json`: task inputs, cache outputs, and environment configuration.
49-
- `scripts/`: asset conversion/import utilities.
49+
- `scripts/`: maintained build/cache tools and gameplay-data importers; see docs/assets.md for the tool list and recovery of retired converters.
5050
- `apps/game/tests/game.spec.ts`: browser integration checks. Unit tests live beside source files.
5151

5252
## Gameplay and performance
@@ -64,9 +64,9 @@ Install browser binaries when needed with `bun run --bun playwright install chro
6464

6565
Read `README.md` and `packages/assets/public/audio/source/manifest.json` before modifying imported assets. Weapon OBJs and the first sound pack came from user-supplied Downloads folders. Those original source files are external inputs; leave them intact and keep converted runtime assets in `packages/assets/public/`.
6666

67-
The additional sound library comes from `sourcesounds/csgo`; its importer pins a repository commit. Kill-feed icons come from the user's Killfeed Generator reference. Keep attribution and regeneration instructions accurate, and retain local assets for development/offline play; production may use the pinned R2 CDN and optional Steam API.
67+
The additional historical sound library comes from pinned `sourcesounds/csgo` inputs. Kill-feed icons come from the user's Killfeed Generator reference. Provenance and licenses remain beside runtime assets; docs/assets.md covers maintained tools and historical converter recovery. Keep attribution and regeneration instructions accurate, and retain local assets for development/offline play; production may use the pinned R2 CDN and optional Steam API.
6868

69-
The supplied OBJs are static meshes. Current draw/reload/walk animations are authored reconstructions, not exact Valve animation clips. Ballistic and economy attributes use the documented current pinned shipped-data snapshot, while body thickness and map surfaces are simplified. Distinguish verified source values from approximations when changing or describing behavior.
69+
The supplied OBJs are static meshes. Runtime combines imported native clips with reconstructed playback, retargeting and procedural behavior; imported samples do not establish complete native animation-graph parity. Ballistic and economy attributes use the documented pinned shipped-data snapshot, while body thickness and collision behavior retain approximations. Distinguish verified source values from approximations when changing or describing behavior.
7070

7171
## Validation and delivery
7272

‎docs/agents.md‎

Lines changed: 0 additions & 25 deletions
This file was deleted.

‎docs/asset-loading.md‎

Lines changed: 0 additions & 79 deletions
This file was deleted.

‎docs/assets.md‎

Lines changed: 72 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,72 @@
1+
# Assets and maintenance tools
2+
3+
Runtime assets are checked in under `packages/assets/public/`. Development and ordinary local builds use those files; production can use an immutable R2 release. No conversion tool or installed CS2 copy is needed to run or build the checked-in game. Keep original supplied files and installed game files read-only.
4+
5+
## Provenance
6+
7+
Hashes, source URLs, depot/tool versions and processing notes live beside their outputs in `source.json`, `*-source.json` and `source-manifest.json`. The release-wide SHA-256 index is `packages/assets/manifest.json`. Preserve these and all bundled licenses when changing assets.
8+
9+
| Asset family | Provenance location under `packages/assets/public/` |
10+
| ---------------------------------------------- | --------------------------------------------------------------------------------------- |
11+
| Dust II, collision, lighting and baked C4 | `models/maps/` and `models/maps/lighting/` |
12+
| Agents, first-person hands and optional roster | `models/agents/` and `models/agents/roster/` |
13+
| Weapon models, actions, skins and suppressors | `models/viewmodels/`, `models/animations/` and `skins/` |
14+
| Knives | `models/animations/knives/`, `models/animations/bayonet/`, `models/bayonet.source.json` |
15+
| Audio, event mappings and startup bank | `audio/` and `audio/source/manifest.json` |
16+
| Menu media, icons, fonts and tracers | `ui/`, `icons/`, `fonts/cs2/` and `effects/` |
17+
18+
Original weapon OBJs and initial WAVs came from supplied Downloads folders. Additional historical sounds came from pinned `sourcesounds/csgo`; native CS2 sound manifests supersede selected recordings. Weapon viewers supply pinned mesh/animation exports. Native Steam/Windows extractions supply map, agent, pose, interface and audio resources. Kill-feed silhouettes use the supplied Killfeed Generator reference. Exact inputs remain recorded in the corresponding manifests.
19+
20+
Imported geometry and clip samples do not reproduce the complete Source 2 renderer or evaluated animation graphs. Three.js materials, lighting, retargeting, procedural constraints, sound mixing and effects retain documented approximations. The old IDF uses Source 1 proportions. New knife imports provide vanilla finishes; skin compatibility is catalog-dependent.
21+
22+
## Maintained scripts
23+
24+
Run scripts from the repository root. Python tools use Python 3; check each tool's docstring/arguments for external inputs.
25+
26+
| Scripts | Purpose and requirements |
27+
| ------------------------------------------------------------------------------------------------------ | ----------------------------------------------------------------------------------------------------------- |
28+
| `build-assets.mjs`, `service-worker.js` | Vite asset integration and production cache worker; required by builds/tests |
29+
| `check-asset-cache.mjs`, `check-cache-update.mjs`, `benchmark-loading.mjs` | Chromium production cache/update checks and local loading measurements; use `CACHE_URL` for the preview URL |
30+
| `pack-audio.py` | Repack existing encoded clips into the startup bank, without re-encoding |
31+
| `import-weapon-stats.py`, `import-accuracy-data.py`, `import-recoil-data.py`, `import-utility-data.py` | Pinned shipped gameplay inputs; Python and curl |
32+
| `import-weapon-action-data.py`, `import-world-ball-origin.py` | Derive small simulation metadata from local GLBs |
33+
| `import-bomb-damage.py`, `import-buy-zones.py`, `import-world-ball.py` | Extract pinned map/physics inputs with Source2Viewer and matching cached VPKs |
34+
| `import-sound-ranges.py` | Extract distance curves from matching compiled/decoded weapon sound events |
35+
| `import-all-knives.py` | Import nineteen additional knife models/icons from the pinned viewer; Bun, curl, Pillow and NumPy |
36+
| `extract-knife-timings.py`, `import-knife-timings.py` | Audit installed native clips and bind their timings to bundled GLBs |
37+
38+
`scripts/cs2-weapon-audio.json` remains the input for audio packing, range extraction and source-integrity tests. Do not discard it as an old report.
39+
40+
One-off model/map/audio converters, patches and investigation reports were retired in this cleanup. Their generator names in asset manifests are historical provenance, not promises of a currently installed command. To rerun one, restore the required script and its helper chain from the last pre-cleanup revision:
41+
42+
```sh
43+
git restore --source=9aca152cb6f8e3fefd15b1beaacefb19bc0f74a4 -- scripts/<file>
44+
```
45+
46+
The same revision contains the detailed extraction notes under `docs/`. No duplicate archive is kept in the working tree.
47+
48+
## Updating assets
49+
50+
Run the relevant maintained tool, review changed outputs/provenance, then:
51+
52+
```sh
53+
bun run assets:prepare
54+
bun run assets:verify
55+
bun run test:tools
56+
```
57+
58+
Include changed assets, provenance and release manifest together. Do not regenerate unrelated assets just for a code change. R2 publication and rollback behavior are covered in [deployment.md](deployment.md).
59+
60+
## Knife timing
61+
62+
Stable IDs and the complete 22-model roster live in `packages/protocol/src/armory.ts`; append new IDs rather than renumbering old skins. All knives are equipped through Inventory.
63+
64+
The Windows audit used build 26144732 / patch 1.41.9.2 and Source2Viewer 20.1.7467. `packages/simulation/src/data/knife-animations.json` binds 225 bundled actions to native hashes and GLB fingerprints. Eight old Bayonet clips used duration/frames instead of duration/(frames−1); runtime restores the correct interval once, preserving optimized trailing holds. Bayonet draw/slash/stab clips last 1.1667 seconds and inspect lasts 6.2 seconds. Knife base playback is 1.0; visual duration is independent of melee recovery and the 1.0-second deploy readiness.
65+
66+
```sh
67+
python3 scripts/import-all-knives.py
68+
python3 scripts/extract-knife-timings.py --game /path/to/game/csgo --tool /path/to/Source2Viewer-CLI --vendor /path/to/srctools --out artifacts/native-knife-timing
69+
python3 scripts/import-knife-timings.py artifacts/native-knife-timing/timing-roster.json
70+
```
71+
72+
Timing extraction needs scratch-local srctools 2.7.0 and the matching CLI. The importer verifies native resource hashes and GLB time grids. A viewer refresh requires explicit `--refresh` and review; rerun timing binding after model regeneration. Native rare branches, inspect looping, conditional blends and live `weapon_action_speedscale` values are not fully reproduced.

0 commit comments

Comments
 (0)