CleverRaven/Cataclysm-DDA — pull request #6873 by vidarsk (2014-03-23 23:15:44+00:00)
Title: [WIP] Rewrite vehicle

Collisions disabled. Spin needs work. Needs code cleanup.

Assign mass to trees and other object when colliding with them.
For gameplay purposes, vehicle physics consider each game turn to be 1 second long.
Size is also warped, each tile is considered 3 meters long.
This is neccessary to prevent you from constantly plowing into trees etc at high speeds.
100mph speed limitation removed, you can now move more than 10 tiles in a turn.
Old system: 10 total moves. Move every car that needs it 1 tile (up to 10 cars)
Any moves left over are used to move the fastest cars one more tile per move.
New system: 15 total moves. Move every car that needs it 1/5 of their movement, minimum one tile.
Can move as many tiles as needed. Screen is not redrawn for every tile,
just at the end of the move.
Result: Game runs faster when driving normally, only needs 5 redraws instead of 10.
Can handle 3 fast cars perfectly, or 1 fast car and 10 slow ones.
Collisions are an exception and require more screen refreshes and thus more moves,
so time might slow down during multi-car collisions (ie 1 turn will suddenly
only handle 1/3 game turn worth of vehicle physics).
Safe speed/top speed system removed, replaced with actual physics.
Status screen shows acceleration time 0-60mph or 0-100km/h instead of top speed.
Status screen shows current and best (fueled and fully repaired) values for some stats.
Top speed now depends on engine power, wheel grip (depends on surface), and air resistance.
Braking depends on wheel grip and surface and honors proper physics.
Don't expect to stop anytime soon if you drive at 300mph over rubble.
Fumble chances, skidding, and skill gain systems updated.
You can drive safely at * 20 mph, any faster and you might fumble.
Grabbed vehicles reuse the same move code, and now sink in water/trigger traps the same way.