escape/assets
Brian Fertig 724d4fd1e8 feat: data-driven content with JSON configs, textured walls, and editor overhaul
- Move walls, overlays, items, enemies, and campaigns to JSON registries in
  src/config/ (with offline fallbacks baked into registry.js)
- Upgrade level format to v2: add `overlays` and `items` arrays; migrate
  v1 `"enemy"` types to the default from enemies.json
- Raycaster: full texture mapping via baked canvas textures, overlay compositing,
  and distance/side shading
- SpriteRenderer: texture-based billboards for enemies, pickups, and decorative
  items with per-def scale and flash textures
- Editor: palette with dropdowns populated from config JSONs (wall/overlay/item/
  enemy/start/pickup/erase); paint overlays on walls, items on floors; show
  overlay triangles, item squares, enemy circles in the grid
- GameMap: overlay tracking, blocking-item collision via isBlocked, overlayAt/
  setOverlay helpers
- Player: use isBlocked so blocking items stop movement like walls
- Add MenuScene for campaign selection from campaigns.json; victory screen
  gains "Return to Menu" button
- Bump RENDER_* to 960×600 (1:1 with display canvas)
- Update levels to v2 format with specific enemy types, overlays, and items
2026-07-01 22:14:37 -06:00
..
textures feat: data-driven content with JSON configs, textured walls, and editor overhaul 2026-07-01 22:14:37 -06:00
RAW-Gun.png feat: data-driven content with JSON configs, textured walls, and editor overhaul 2026-07-01 22:14:37 -06:00
README.md feat: data-driven content with JSON configs, textured walls, and editor overhaul 2026-07-01 22:14:37 -06:00
gun1.png feat: data-driven content with JSON configs, textured walls, and editor overhaul 2026-07-01 22:14:37 -06:00
gun2.png feat: data-driven content with JSON configs, textured walls, and editor overhaul 2026-07-01 22:14:37 -06:00
gun3.png feat: data-driven content with JSON configs, textured walls, and editor overhaul 2026-07-01 22:14:37 -06:00
gun4.png feat: data-driven content with JSON configs, textured walls, and editor overhaul 2026-07-01 22:14:37 -06:00
gun5.png feat: data-driven content with JSON configs, textured walls, and editor overhaul 2026-07-01 22:14:37 -06:00

README.md

Spritesheets

Full art brief — every sheet with dimensions, frame maps, and drawing notes — lives in sprites.md at the project root.

Art is optional: any sheet that is missing (or too small for a requested frame) gets a procedurally generated placeholder baked in its entry's color from the config JSON, so the game always runs.

Layout

Every sheet is a horizontal strip of square frames, left to right. The frame field in the config JSON is the 0-based index into the strip. Frames are 192×192 (walls can override via textureSize in walls.json; baked output is always 192×192).

Expected files (paths are what src/config/*.json references — change them there if you prefer a different arrangement):

File Used by Notes
assets/textures/walls.png walls.json Opaque. Frame per wall id (frame 0 = Gray Brick, …)
assets/textures/overlays.png overlays.json Transparent PNG — composited over wall textures
assets/sprites/items.png items.json Transparent PNG — billboard props (plant, lamp, …)
assets/sprites/enemies.png enemies.json Transparent PNG — one frame per enemy type for now

A 5-frame walls sheet is therefore 960×192; a 3-frame enemies sheet 576×192.

You can also point different entries at different files — each unique texture path is loaded once and shared.