melonjs-performance SKILL.md skillA
melonjs-performance from melonjs/melonjs is an agent skill: a SKILL.md folder an AI agent loads when a task calls for it.
mdr add melonjs/melonjs/melonjs-performance@git:20261028.73bca6fPins git:20261028.73bca6f in mdr.lock. Pin the fingerprint instead.
- Audit grade
- A, 17 of 17 checks passed
- Kind
- SKILL.md skill
- Repository
- melonjs/melonjs
- Path
packages/melonjs/skills/melonjs-performance/SKILL.md- Versions recorded
- 6
- Latest version
- git:20261028.73bca6f, committed Oct 28, 2026
- First version recorded
- Oct 9, 2026
- Size
- 19,442 bytes
- Repository stars
- 6,441
- License
- MIT
Use this skill when a melonJS game drops frames, allocates heavily, or needs to scale to many objects. Covers object pooling, draw-call batching, atlases, baking with CanvasRenderTarget, instancing, culling and alwaysUpdate, the debug plugin, and where the real costs are. Triggers on: performance, slow, frame rate, fps, lag, pool, pool.register, pool.pull, batching, draw calls, InstancedMesh, culling, alwaysUpdate, inViewport, CanvasRenderTarget, optimise, profiling, debug plugin, memory…
Collected from public GitHub. Every version is saved exactly as it was and never changes. Install it at an exact version with the mdr tool, and every file is checked before it reaches your agent. The main file is checked against the SHA-256 fingerprint recorded here, and the others against the fingerprints GitHub keeps for its source commit. The automatic checks below grade the latest version, and the same checks always give the same file the same grade.
What the file says
# Performance
## Measure first
Register the debug plugin and read the numbers before changing anything:
```js
import { plugin } from "melonjs";
import { DebugPanelPlugin } from "@melonjs/debug-plugin";
await app.init();
plugin.register(DebugPanelPlugin, "debugPanel");
```
It reports frame time, draw calls, object counts, and can overlay collision
shapes and bounds. **Draw calls** is usually the number that matters.
## Batching: the biggest lever
Both GPU backends batch **across textures**, not just within one: the quad
batcher assigns each source image a texture unit and embeds the unit in the
vertex data, so several different images still flush as a single draw. The pool
is finite — the WebGL batcher gets `renderer.maxTextures` units (the
`maxTextures` application setting, `"auto"` = the device limit capped at 32), the
WebGPU batcher eight per segment. Overflow the pool and the batch flushes.
So the goal is not "one image" but "few state changes". What actually ends a
batch:
- **Overflowing the texture-unit pool** — pack sprites into a `TextureAtlas` and
prefer one large tileset over several small ones, so a screenful of sprites
…Read the whole file at its exact version.
How to install
mdr add melonjs/melonjs/melonjs-performance@sha256:5ce36e1bcaf571f5The line at the top of this page pins the label git:20261028.73bca6f, which is what most people want. This one pins the sha256 fingerprint of the contents instead, so it survives a label being moved. Either way the exact version is written to mdr.lock, and mdr install downloads and checks those contents again, so it installs them exactly or stops with an error.
[](https://markdownregistry.com/a/art_fbjglilhkd3o2usb)
1 badge image fetches in 30 days. What the badge shows.
Versions
The registry has recorded 6 versions of this file, between Oct 9, 2026 and Oct 28, 2026, about one every 4 days.
| version | committed | commit | size | audit | |
|---|---|---|---|---|---|
| git:20261028.73bca6f latest | 2026-10-28 | 73bca6f | 19,442 B | A | view · diff |
| git:20261025.d9abca5 | 2026-10-25 | d9abca5 | 19,274 B | A | view · diff |
| git:20261021.ce5ddcd | 2026-10-21 | ce5ddcd | 19,079 B | A | view · diff |
| git:20261019.b31051f | 2026-10-19 | b31051f | 18,806 B | A | view · diff |
| git:20261011.ea10090 | 2026-10-11 | ea10090 | 18,323 B | A | view · diff |
| git:20261009.e9d134f | 2026-10-09 | e9d134f | 17,822 B | A | view |
Audit of the latest version
- pass: Frontmatter block present
- pass: Frontmatter declares a name
- pass: Frontmatter declares a description
- pass: Size between 200 bytes and 200 KB (19442 bytes)
- pass: No zero-width or bidi control characters
- pass: No instruction hidden inside an HTML comment
- pass: No link to an exfiltration or paste host
- pass: No credential-shaped string
- pass: No instruction to send local credentials anywhere
- pass: No text hidden with inline styles
- pass: No prompt-injection phrasing
- pass: No curl or wget piped into a shell
- pass: No recursive delete of root, home or parent
- pass: No instruction to read or print local credentials
- pass: No base64 blob over 200 characters
- pass: No link to a raw IP address
- pass: No script tag
Source
melonjs/melonjs · 6,441 stars · license MIT · pushed 2026-11-06 · branch master
API
GET https://markdownregistry.com/api/v1/artifacts/art_fbjglilhkd3o2usb GET https://markdownregistry.com/api/v1/resolve?ref=melonjs/melonjs/melonjs-performance GET https://markdownregistry.com/api/v1/blob/5ce36e1bcaf571f56b6954aa1d9fcf41eda2d6e5e158c128c30771d626b837e3
Your AI assistant does the legwork. You hear about the deals worth your word. Hand yours the standing instructions at modelranch.com and it joins the network that reads files like this one.
Guides: the SKILL.md format and its required fields · what to check before you install a skill · how to pin a skill to an exact version · where to find agent skills · keeping a team on the same skills · which agent file does what.