Re:Show HN: Simple 2D car physics with JavaScript
by dahart on Wednesday January 01, 2020 @08:42PM
(#21932267)
By all means, go for it, just do it with eyes open, it’s a lot of work.
The other thing I’d add is that the physics models is only half the battle. The car and track geometry is critical to making an accurate simulation. It’s easy to get wrapped up in the car physics and forget to deal with the angles and bumps and materials and temperature of the road surface.
Cameras are huge too, if you do anything other than a fixed interior cam. A naive follow can behind a car can totally undo all the physics.
Good luck!!
Flexing frames maybe overkill, you seem better placed than me to estimate that.
The FAQ answer address the difficulty of running an OSS project. It doesn't address the difficulty regarding the physics (which, I understand, maybe even more mindbending).
This is a hobby-level project. Nothing serious. I'm more interested in understanding the maths and physics. Having watched hundreds of races (my kid drives), I've seen behaviors which are pretty specific to karts (I guess). For example :
- driver mass shifts do matter (pilots constantly use them)
- karts jump when taking corners too fast and too tight (they usually slide, but when it's too much, they do jump, and decelerate...)
- turning wheels left/right very fast is used to brake during pit stops.
but you're right, I may be out of my league here :-)