@clockwork-engine/platform-memory

Headless memory platform layer for Clockwork Engine - ideal for testing and replay validation.
What's Included
- MemoryPlatformLayer - Headless platform implementation
- MemoryRenderingLayer - In-memory rendering (stores node state without visual output)
- MemoryAudioLayer - Mock audio layer
- MemoryInputLayer - Programmatic input simulation
Use Cases
- Unit and integration testing
- CI/CD pipelines (no browser required)
- Replay validation and determinism verification
- Server-side game state processing
Installation
bun add @clockwork-engine/core @clockwork-engine/platform-memory
Usage
import { GameCanvas } from '@clockwork-engine/core'
import { MemoryPlatformLayer } from '@clockwork-engine/platform-memory'
const platform = new MemoryPlatformLayer({
screenWidth: 800,
screenHeight: 600,
worldWidth: 800,
worldHeight: 600,
})
await platform.init()
const canvas = new MyGameCanvas(options, platform)
await canvas.initialize()
game.start()
Peer Dependencies
See the main README for full documentation.