configure-physics-collision

Installation
SKILL.md

Configure Physics Collision

Configure and optimize 2D and 3D physics simulation pipelines, collision matrices, Continuous Collision Detection (CCD), and spatial query routines for deterministic, jitter-free gameplay.

Core Rules

  • Fixed Timestep & Substepping Discipline: Lock physics solver ticks to a deterministic interval ($60\text{Hz}$ or $120\text{Hz}$) with bounded kinematic substepping. Render frames must interpolate visual transforms between previous and current physics ticks rather than advancing physics on variable delta times.
  • Sparse Collision Matrix Layering: Explicitly assign bitmask layers (e.g. Player, Enemy, WorldStatic, Projectile, Trigger, Hitbox) and disable non-interacting layer pairs in the broadphase matrix to minimize sweep-and-prune overhead.
  • CCD for High-Velocity Bodies: Enable swept-sphere or speculative Continuous Collision Detection (CCD) on projectiles and high-speed actors whose per-tick displacement exceeds half their collider radius.
  • Contract Adherence: Emit contracts/schemas/implementation-result.json upon completing physics and collision configurations.

Suggested Process

1. Timestep, Solver Iterations & Substepping Setup

Configure the physics world tick rate ($\Delta t_{\text{fixed}} = 16.66\text{ms}$ or $8.33\text{ms}$), velocity/position solver iteration counts, and maximum allowed substeps per frame to prevent spiral-of-death freezes during CPU spikes.

2. Broadphase Collision Matrix & Collider Topology

Define named collision layers and masks in version-controlled project settings. Replace complex concave triangle meshes on dynamic bodies with compound primitive colliders (capsules, boxes, spheres, or convex hulls) to guarantee stable manifold generation.

Installs
4
GitHub Stars
5
First Seen
Oct 26, 2026