2D and 3D platformers. Tight jump physics with coyote time and buffering, level design that teaches (introduce, test, twist), tilemaps and hazards, checkpoints, collectibles, enemies and stomps, moving platforms, camera framing, difficulty, touch controls, and a starter plan built on the movement, physics, tilemap and camera modules. Covers 3D platformer specifics with three.js. Use for "make a...
Download skill (.zip) Files on GitHubPlatformer development
Core: run and jump with precise, forgiving controls through hand-designed levels.
Starter template
A playable starter for the game-scaffolding template is in assets/starter/. A one-level platformer: run with acceleration and friction, jump with coyote time, jump buffer and variable height, coins, spikes, pits, a goal flag, lives, and a look-ahead camera. The level is ASCII in config.js.
python3 <game-scaffolding>/scripts/scaffold.py my-game --title "My Game" --starter <this skill>/assets/starter
Controls: Arrows/WASD + Space. Touch: left/right and jump buttons (multi-touch). Esc pauses. All numbers to tune are in src/config.js; the gameplay is in src/scenes/play.js.
Walking, scrolling and pausing were tested in a browser, and the level layout is checked to fit the jump height.
Structure
Scenes: title → level select (optional) → play (level N) ⇄ pause → level complete → next. Play scene: tilemap, player, enemies, hazards, collectibles, checkpoints, camera, HUD.
Growing the starter (tested modules)
- player-movement
platformer()+ game-physicsmoveAndSlide(tile collisions with substeps). - tilemap-development: level from Tiled or ASCII;
solid,hurts,oneWaytile properties; spawn and checkpoint objects. - camera-system with a wide dead zone and bounds; parallax-backgrounds.
- sprite-animation state machine (idle, run, jump, fall, land).
- Enemies: patrol + stomp (land on top = kill + bounce
vy = -jumpSpeed * 0.6), side contact = hurt.
Level design
- Teach → test → twist: introduce a mechanic safely, require it, then combine it.
- One new idea per level; the end of each level is a small exam.
- Checkpoints every 30–60 s of play; respawn in < 1 s.
- Collectibles off the main path reward exploration; never required.
- Readable hazards (spikes look sharp, pits are dark), and no blind jumps.
Numbers
| Thing | Value |
|---|---|
| Jump height | 3–4 tiles · Run speed 6–9 tiles/s |
| Coyote / buffer | 0.08–0.12 s |
| Gravity on fall | 1.4–2× rise |
| Level length | 1–3 min for small games |
3D platformers
game-kit-3d / threejs-game-development, Rapier character controller or capsule collisions, a follow camera with wall avoidance, a blob shadow under the player (depth perception), and generous ledges.
Controls
Touch: floating stick (left) + big jump button (right), optional dash button (mobile-game-controls). Gamepad: stick/d-pad + A.
Pitfalls
Floaty jumps (raise gravity, cut jump on release), pixel-perfect jumps early, checkpoints too far apart, camera that hides landing spots, and collision snagging on tile seams (resolve per axis).