The online racing simulator
Collision Physics: Speed / Direction Factor Smoothing MP Contacts
In my 1st week of LFS lagging made me crazy.  So I wonder if it is possible to change the physics a bit to make it better.

I know that lag-crashing has been a big problem for long and can't be solved completely in a short time. But maybe this idea will help a little.


Now, when 2 LFS cars overlap each other in an MP race, the force between the 2 car bodies will suddenly increase to an unbelieveable level, resulting a lag crash. My idea is to take relative speed as an important factor in MP car-to-car force calculation. Overlapping will still result in more force than usual, but if the relative speed of the 2 cars is slow when the lateset postion refresh info came, you will not get a big hit even if you're totelly overlapping the other car. Force is reduced by low relative speed and the two cars will separate slowly.

In this way, hitting into a lag car will become a progress just like hitting a wall (a moveable & weighted one, of course) - like you moving at the relative speed of the two cars towards a not-moving wall. The slower you move, the lighter the hit will be. If the relative speed is near zero, there will be almost no force. No matter how hard you hit the wall, you'll only be (relatively) STOPPED, not THROWN AWAY.

This doesn't have to mean there will be a lot of ghost cars on the track. It's still not allowed to pass through the body of another car. Direction can taken in to consideration. For example, Car A is overlapping Car B, the center of Car A is in front of that of Car B, and A is going slower - so it tends to overlap more part of B. In this case, high force will be formed to stop A from going back (movement relative to B). This kind of force will push A towards front quickly so it will soon catch up with the speed of B (B is quickly slowing down on the same computer at the same time). When A begin to move forward (relative to B), direction of the relative movement is reversed, and force between the 2 cars will drop to a much lower level. So, a upcoming laggy car will be STOPED suddenly as well as what happens in today's LFS and then PUSHED AWAY, instead of THROWN AWAY like a rock (if not a rockET).

The speed / direction factor can function as a multipler, a limiter or something more complex. No matter what it is, please push the overlapping car away softly & smoothly.


Sorry if I missed something important.

Very sorry if I'm talking about something completely foolish.


BTW, one suggestion:
Give up some details in MP. If a lag can make a car travel 0.5m instantly (I would really love it if someone can limit lagging below that level), calculation for something sized 0.05m (like a piece of the tyre rubber) is simply a waste of CPU. Just calculate your own car with accuracy.
One problem : if the central point of 2 cars are too close, the direction may change sharply. In this case please reduce force to minimum. Even ghost passing is better than multi-car crashing.

FGED GREDG RDFGDR GSFDG