@nanogram/ng-game-starter-templates
v0.1.0
Published
Ready-to-edit **TypeScript** game starters. Copy one, edit the gameplay, and let your project compile it together with the engine packages — the compile-based counterpart to the single-file HTML scaffolds in [`scaffold/`](../../scaffold/scaffold.md).
Readme
starter-templates
Ready-to-edit TypeScript game starters. Copy one, edit the gameplay, and let your project
compile it together with the engine packages — the compile-based counterpart to the single-file
HTML scaffolds in scaffold/.
- Compiles as TS. These are real modules that
importfrom the engine packages; nothing is pre-bundled. The project using the codebase compiles the whole tree (esbuild / vite / tsc). - Peer deps:
ng-game-core+ the flavor's adapter (+threefor 3D).
Starters (src/)
| File | Flavor | Import |
|---|---|---|
| three-starter.ts | 3D (three.js) | @nanogram/ng-game-starter-templates/three |
| canvas2d-starter.ts | 2D pixel-art | @nanogram/ng-game-starter-templates/canvas2d |
| pixi-starter.ts | 2D sprite (Pixi.js) | @nanogram/ng-game-starter-templates/pixi |
Each is a complete, boring, playable game — boots → demo → takeover → play → game-over →
restart, the same contract as the HTML templates, so a zero-edit copy runs. Edit MANIFEST
and the loop to make your game. Interface reference for every symbol used:
ng-game-core/docs, ng-game-three/docs,
ng-game-canvas2d/docs.
Relationship to scaffold/
Same starter games, two delivery modes. scaffold/*_template.html inline the engine for a
standalone no-build page (what ng-gamegen embeds); these .ts starters keep the import
graph for a project that compiles.
