Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/phuonghx/aim-cli/web-gamesnpx skills add phuonghx/aim-cli --skill web-gamesgit clone --depth 1 https://github.com/phuonghx/aim-cliWhat it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00079 | $0.01078 |
| Opus 5 | $0.00039 | $0.00539 |
| Sonnet 5 | $0.00016 | $0.00216 |
| Haiku 4.5 | $0.00008 | $0.00108 |
Grade A, and why
web-games scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured yesterday.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 120 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Building Games for the Browser
Practical guidance for shipping games that run inside a web page, where the runtime is a sandbox you do not fully control.
Choosing a Rendering Stack
Start from the dimensionality of your game, then decide how much engine you actually need.
- 2D, batteries included — reach for Phaser when you want scenes, physics, input, and asset management handled for you.
- 2D, you drive — reach for PixiJS when you mainly need a fast renderer and full control over UI and the scene graph.
- 3D, full engine — reach for Babylon.js when you want physics, a scene system, and built-in XR support.
- 3D, lean renderer — reach for Three.js when the focus is drawing and visualization and you want a smaller footprint.
- Something bespoke — drop down to raw Canvas or WebGL when no engine fits the shape of what you are building.
| Library | Dimension | Sweet spot |
|---|---|---|
| Phaser 4 | 2D | Complete game toolkit |
| PixiJS 8 | 2D | Renderer-first, custom UI |
| Three.js | 3D | Lightweight scenes, dataviz |
| Babylon.js 7 | 3D | Full engine with XR |
WebGPU vs WebGL
WebGPU is the modern graphics API; WebGL remains the safe baseline. Roughly 73% of users now have WebGPU.
| Engine | Availability |
|---|---|
| Chrome | 113 and up |
| Edge | 113 and up |
| Firefox | 131 and up |
| Safari | 18.0 and up |
How to choose:
- Greenfield project — target WebGPU and degrade to WebGL when it is missing.
- Must support old devices — build on WebGL from the start.
- At runtime — branch on the presence of
navigator.gpurather than sniffing the user agent.
Living Within the Sandbox
The browser imposes limits that a native runtime does not. Plan around each one.
| Limitation | What to do |
|---|---|
| Cannot read the local disk | Ship assets in bundles or serve them from a CDN |
| Inactive tabs get throttled | Detect visibility changes and pause the loop |
| Users may be on metered data | Shrink assets aggressively |
| Sound will not autoplay | Wait for a tap or click before starting audio |
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- yesterday First seen · 120 lines · 79 tokens per session scan A df47a9c24043
web-games is a skill published in the GitHub repository phuonghx/aim-cli (1 stars, last pushed 2mo ago), licensed MIT. It adds 79 tokens to every session and 1,078 once invoked, about $0.0004 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
motion-system
Define motion tokens — durations, easing vocabulary, and reduced-motion handling — for consistency product-wide. Use when standardising motion across a system. For crafting one specific animation, use animation-principles (interaction-design).
icon-system
Specify an icon system — grid, sizing, stroke weight, naming, categories, and implementation. Use when standardising iconography. For broader illustration, use illustration-style (ui-design).
ai-provider-openai-sdk
Official OpenAI SDK patterns for TypeScript/Node.js — client setup, Chat Completions, Responses API, streaming, structured outputs, function calling, embeddings, vision, audio, and production best practices.
ai-infrastructure-huggingface-inference
Hugging Face Inference SDK patterns for TypeScript/Node.js — InferenceClient setup, chat completion, text generation, streaming, embeddings, image generation, audio transcription, translation, summarization, and Inference Endpoints.
ai-infrastructure-together-ai
Together AI SDK patterns for TypeScript — client setup, chat completions, streaming, structured output, function calling, embeddings, image generation, fine-tuning, and OpenAI-compatible endpoints.
ai-provider-elevenlabs
ElevenLabs voice AI SDK patterns for TypeScript/Node.js -- text-to-speech, streaming, voice cloning, speech-to-speech, pronunciation control, and conversational AI.