Torque Valley: Driving, Drift and Crash Sandbox
README.md
driveProgress.score
The driver progression scoring core as pure functions (no entities, no UI). Score.new(style) makes
a state; Score.step(state, sample, dt) takes one driving sample (kmh, speed, slip,
airborne, impactCount, impactSpeed, damage) and returns the events earned that frame —
speed milestones, drift chains (slides chained into a multiplying combo, dropped by a hard crash in
some styles), air time on landing, crashes, distance, challenge completions and level-ups — each
with its XP and toast text in the style's wording. Also levelInfo, xpForLevel, addChallenge,
removeChallenge, challenges, complete, bonus, live, setStyle (keeps XP), reset, log.
Called by the DriverProgress and ProgressGallery components, and usable for a HUD or server of your own.