The gap
Hand-tuned flight numbers break every time a hill changes size.
Game templates
The complete source of Leapcrest, a one-button ski jumping tour with a calibrated flight model, FIS-style scoring and nine rivals.
Coming soon
Not published on its store yet, so there is no buy or download link. PN Scripts does not take payment for it here.
The gap
Hand-tuned flight numbers break every time a hill changes size.
What it is
This template calibrates each hill: a bisection finds the take-off speed at which a solid jump lands on the K-point.
How you use it
Unzip, serve the folder and open index.html, then edit game.js; npm test plays it again in headless Chrome.
Source code of a real, playable game to reskin and learn from, with a smoke test whose bot plays it.
Use it when
Built for
A landing hill is a list of slope angles: a knoll that steepens to 36 degrees, a steep section and a transition to the flat. Heights and distances along the slope are integrated once in half-metre steps.
On the inrun the button jumps; in flight holding it leans forward and releasing sits back; in the last 0.6 seconds before touchdown, worked out from height and descent rate, a new press is the telemark.
Plain JavaScript and Canvas 2D; open index.html through any static server and edit game.js.
A headless Chrome test loads the game, checks the console, presses keys and taps, and lets the built-in bot play a run to its result screen.
1 of 3
| Platform or runtime | Supported versions | Tested up to |
|---|---|---|
| Node.js | 22.12 or newer | Not stated |
The template is finished and tested. It is not on sale yet; this page will say where to get it when it is.
Coming soon
Not published on its store yet, so there is no buy or download link. PN Scripts does not take payment for it here.