AgentStack
Browse Sign in
Browse Why AgentStack Sell Docs
Sign in
SKILL verified MIT Self-run

Apply Conventions

skill-playcanvas-skills-apply-conventions · by playcanvas

Use when writing or reviewing PlayCanvas Engine code involving entity transforms, cameras, physics, materials, model orientation, bounds, or imports to apply the Engine's coordinate and API conventions.

No reviews yet
0 installs
25 views
0.0% view→install

Install

$ agentstack add skill-playcanvas-skills-apply-conventions

✓ scanned · ✓ verified, works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

View the full security report →

Verified badge

Passed review? Show it. Paste this badge into your README, it links to the public security report.

AgentStack Verified badge Links to your public security report.
[![AgentStack Verified](https://agentstack.voostack.com/badges/verified.svg)](https://agentstack.voostack.com/security/report/skill-playcanvas-skills-apply-conventions)

Reliability & compatibility

Security review passed
0 installs to date
no reviews yet
1mo ago

Declared compatibility

Claude CodeClaude Desktop

Compatibility is declared by the source manifest. End-to-end runtime verification is coming, see below.

Preview Execution monitoring

We're building live execution health for every listing: tool-call success rate, median latency, uptime, and last-checked timestamps, measured, not self-reported. It isn't live yet, so we don't show numbers we can't stand behind.

How agent discovery & health will work →
Are you the author of Apply Conventions? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

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.forward and the camera viewing direction as -Z; entity.right is +X and

entity.up is +Y. lookAt points -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 into setEulerAngles().

  • Interpolate periodic angles with math.lerpAngle() or rotations with Quat.slerp(), not scalar

lerp across the 0/360 seam.

Transforms and units

  • Use setPosition, setRotation, and setEulerAngles for 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.

  • Entities do not have an aabb. Union descendant meshInstance.aabb values after transforms have

synchronized.

  • Let Mesh.update() calculate local bounds. If passing false for updateBoundingBox, assign an

explicit mesh.aabb before 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.

Imports

Use named ESM imports from playcanvas. Import production scripts only from playcanvas/scripts/esm/**; legacy sibling script directories depend on a global Engine namespace.

Runtime confirmation

Offline measurements cannot prove facing, animated poses, or final placement. Confirm each one in the running application:

  • Start the project's own dev server or build; do not construct a separate harness.
  • Log the value from inside the Engine, using getPosition(), getEulerAngles(), a

meshInstance.aabb, or an anim component's active state, from a Script or an update callback.

  • For large or vertex-displaced meshes, inspect their runtime AABB and visibleThisFrame after a

rendered frame from at least two representative camera angles.

  • Confirm a directional model's visible front aligns with its semantic root's forward; a stored

yaw or runtime transform alone cannot prove mesh facing.

  • Read that logged value from the browser console. Screenshots judge composition and orientation;

numeric claims require logged values.

  • Record the confirmed value in application state or an asset tuning record, then remove the logging.

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet, be the first.

Versions

  • v0.1.0 Imported from the upstream source.