Clockwork

Clockwork is a TypeScript-first, modular game engine workspace focused on ECS-driven runtime systems and a WebGL2 renderer stack.

ECS Overview

ECS Overview

qti-clockwork-ecs provides entities, components, queries, resources, and deferred commands.

Primary Types

  • World
  • EntityManager
  • ComponentStore<T>
  • Query
  • CommandBuffer
  • ResourceMap / ResourceType

World Capabilities

  • spawn/destroy entities
  • add/remove/get components
  • query entities by component filters
  • insert/get/remove typed resources
  • deferred mutation through command buffers

Core Properties

  • generation-based entity safety
  • sparse component storage
  • sorted entity iteration for determinism
  • component change ticks for changed queries
Last updated: February 16, 2026