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/playcanvas/create-playcanvas/apply-conventionsnpx skills add playcanvas/create-playcanvas --skill apply-conventionsgit clone --depth 1 https://github.com/playcanvas/create-playcanvasWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/playcanvas/create-playcanvas/apply-conventions)<a href="https://agentmods.dev/skills/playcanvas/create-playcanvas/apply-conventions"><img src="https://agentmods.dev/badge/skills/playcanvas/create-playcanvas/apply-conventions.svg" alt="Measured on agentmods" height="20"></a>What 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.1 | $0.00040 | $0.00954 |
| Opus 5 | $0.00020 | $0.00477 |
| Sonnet 5 | $0.00008 | $0.00191 |
| Haiku 4.5 | $0.00004 | $0.00095 |
Grade A, and why
apply-conventions 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 6d ago.
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.
Copies of this mod
1 near-identical copy found in the catalogue:
- apply-conventions — 100% identical, 4 lines differ
How it starts
The opening of the file, as written. The whole thing — 76 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Engine conventions
Read package.json and the installed playcanvas source before relying on version-sensitive API
details. Apply these stable conventions throughout the project.
Coordinates and angles
- Use the right-handed coordinate system: +Y is up and the gameplay ground plane is XZ.
- Treat
entity.forwardand the camera viewing direction as -Z;entity.rightis +X andentity.upis +Y.lookAtpoints -Z at the target. - Expect glTF models authored toward +Z to need a yaw correction. Inspect and calibrate each directional model instead of applying one global correction.
- Pass degrees in XYZ order to high-level angle APIs.
- Keep pitch, yaw, and roll as application state. Do not repeatedly read
getEulerAngles()and feed its decomposition back intosetEulerAngles(). - Interpolate periodic angles with
math.lerpAngle()or rotations withQuat.slerp(), not scalar lerp across the 0/360 seam.
Transforms and units
- Use
setPosition,setRotation, andsetEulerAnglesfor world transforms. - Use the
setLocal*variants below a parent. - Treat units as metres. Physics gravity defaults to
(0, -9.81, 0). - Keep gameplay transforms on a semantic root and asset-authoring corrections on a child.
- Do not scale rigid-body roots or skinned bones.
Cameras, materials, and bounds
- Perspective camera FOV is vertical and defaults to 45 degrees.
- Smooth an orbit camera's focus, yaw, pitch, and distance, then derive its position. Do not
Vec3.lerp()between orbit positions on opposite sides of the focus; the chord crosses the subject. - Before writing custom camera input, inspect the installed controller script and its matching Engine example. Preserve their gesture mapping and damping unless the product explicitly asks for different behavior; do not derive signs from memory.
- Define the input contract in screen space, then verify positive and negative movement on both axes with real input after a rendered frame. Judge the camera basis or a projected fixed landmark, not world-space camera coordinates or internal angle signs; both can approve inverted behavior.
- Materials cull back faces by default; counter-clockwise winding defines the front face.
- Clone a material before per-instance tinting or edits, and assign the clone; never mutate one shared by other instances, including default and asset-imported materials.
setParameteruploads raw values; author colours in sRGB and convert withColor#linear()before upload — do not hand-roll gamma.- Entities do not have an
aabb. Union descendantmeshInstance.aabbvalues after transforms have synchronized. - Let
Mesh.update()calculate local bounds. If passingfalseforupdateBoundingBox, assign an explicitmesh.aabbbefore the mesh can be culled. - Expand custom-mesh bounds by the maximum vertex-shader displacement; CPU bounds do not observe shader deformation.
- Treat offline skinned-mesh bounds as bind-pose estimates and confirm animated poses at runtime.
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.
- 6d ago First seen · 76 lines · 40 tokens per session scan A df464d24380a
apply-conventions is a skill published in the GitHub repository playcanvas/create-playcanvas (53 stars, last pushed yesterday), licensed MIT. It adds 40 tokens to every session and 954 once invoked, about $0.0002 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-30.
Other skills, from other repositories
gameobject-component-destroy
Destroy one or more Components from a target GameObject. Missing (null) components are skipped — they cannot be destroyed. Use 'gameobject-find' and 'gameobject-component-get' to identify the components first.
unity-version-split
Split a C# file into Unity 6.5+ and pre-Unity 6.5 variants. Use when a file needs different implementations for different Unity versions due to API changes (e.g., EntityId vs int, GetEntityId vs GetInstanceID).
unity-addressables
Manage Addressables groups, entries, profiles and content builds (com.unity.addressables, reflection-based).
playtest-report
Generates a structured playtest report template or analyzes existing playtest notes into a structured format. Use this to standardize playtest feedback collection and analysis.
unity-manual-component
Manually add, configure, reorder, and copy components on GameObjects using Unity Editor UI. For one-off Inspector workflows that do not need REST automation.
motion
How an agent turns a character mesh into a usable animated FBX — and how to judge whether the result is shippable.