zwitschi a37eb14ba5 feat: add level schema and tilemap tests
- Introduced a JSON schema for game levels to validate level data structure.
- Added comprehensive tests for tilemap functionalities including collision resolution, tile type retrieval, and level loading.
- Enhanced the SyncSystem to manage remote state synchronization and interpolation for smoother gameplay.
- Implemented an AudioSystem with tests to ensure audio loading and playback functionality.
- Updated NetworkClient to support dynamic WebSocket URLs from environment variables.
- Added integration tests for matchmaking and network communication between clients.
- Improved RenderSystem to correctly render player nicknames above sprites.

Co-authored-by: Copilot <copilot@github.com>
2026-05-02 18:48:46 +02:00

ZAMNY Client

Vite + TypeScript + Canvas 2D + ECS game client for Zombies Ate My Neighbors browser edition.

Quick Start

npm install
npm run dev          # http://localhost:5173
npm test             # vitest (ECS tests)
npm run build

Structure

src/
  engine/
    ecs.ts           # World, Entity, Component, System base
    ecs.test.ts      # 6 unit tests (green)
  systems/
    InputSystem.ts   # keyboard/touch stub
    RenderSystem.ts  # Canvas 2D stub
    PhysicsSystem.ts # movement/collision stub
  main.ts            # 60 FPS game loop + system orchestration

Key Points

  • ECS core: createEntity, addComponent, query, destroyEntity
  • Systems extend System and implement update(world, dt)
  • Target: 60 FPS, offline single-player works without server
  • Nickname UI, NetworkClient, sprite rendering: TODO

Testing

  • Vitest + jsdom
  • npm test runs ecs.test.ts
  • Coverage target: 70% (documented in ARCHITECTURE.md §10)

See root README.md and ARCHITECTURE.md for full design.

S
Description
No description provided
Readme 120 KiB
Languages
TypeScript 90.9%
CSS 8.5%
HTML 0.6%