apply-conventions
Installation
SKILL.md
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.