The online racing simulator
Another Colisions Thread
(11 posts, started )
Another Colisions Thread
Of course the age old suggestion in all online racing games is, "Fix the lag collisions!" However, I want to propose an idea that might work, but I don't have any clue as to the feasibility of the actual programing of said idea.

The Problem: Cars shoot off from impossible collisions when nudged fairly hard while online.

A Solution: Void extremely high collision force values, then recalculate based on the closing speed at or near the instant before contact.

As the collision detection stands now, there is already a delay from the moment of impact to the resulting reaction; which, I think, can only be fixed with the brute force method, high CPU clock.

What is the feasibility of this solution, and could the calculation delay be a reasonably short time? Considering the net code makes position predictions, would calculating the collision ahead of time be possible?
Quote from legoflamb :Of course the age old suggestion in all online racing games is, "Fix the lag collisions!" However, I want to propose an idea that might work, but I don't have any clue as to the feasibility of the actual programing of said idea.

The Problem: Cars shoot off from impossible collisions when nudged fairly hard while online.

A Solution: Void extremely high collision force values, then recalculate based on the closing speed at or near the instant before contact.

As the collision detection stands now, there is already a delay from the moment of impact to the resulting reaction; which, I think, can only be fixed with the brute force method, high CPU clock.

What is the feasibility of this solution, and could the calculation delay be a reasonably short time? Considering the net code makes position predictions, would calculating the collision ahead of time be possible?

I never have that lag everyone is talking about "Moment of impact" CPU's can do vast array's. You're talking about ping, that makes that "Freeze" Not lag. I average 200 fps.

The solution wouldn't work, As it uses prediction, Which means you would most likely have to calculate where a car is going to go. That is going to include lag, Which means heavy teleporting.. I think.

Just a thought.
Your thoughts are welcome. That is the reason for posting.
I shouldn't speak as I probably have no grasp on this. However I'm going to say what I have in mind anyways. When there is lag, there is glitches in the collisions. This causes the total amount of kinetic energy to be different before and after the crash. So I was thinking: In the event of a collision between two cars. Something that could work is that the momentum of each car, is registered right from that cars local computer. So if two cars were to crash into each other. The variables used from each car would be taken straight from each cars drivers computer. This way lag wouldn't affect the total kinetic energy after the crash.
Quote from pärtan :I shouldn't speak as I probably have no grasp on this. However I'm going to say what I have in mind anyways. When there is lag, there is glitches in the collisions. This causes the total amount of kinetic energy to be different before and after the crash. So I was thinking: In the event of a collision between two cars. Something that could work is that the momentum of each car, is registered right from that cars local computer. So if two cars were to crash into each other. The variables used from each car would be taken straight from each cars drivers computer. This way lag wouldn't affect the total kinetic energy after the crash.

I think you're hugely oversimplifying the problem. It's not as simple as determining the total kinetic energy of the vehicles involved and dividing it evenly. Momentum, like velocity, has both a vector and amplitude. Also like velocity, momentum is relative. A head-on collision is going to have a much greater energy transfer than a T-bone, even if both vehicles are traveling at the same speed and have the same momentum. Under the same conditions, a rear hit is going to have almost no transfer of energy.
Came up with the same idea myself 2 years ago. (but got no reply that time)

If you're calculating collisions between solid balls controlled by different players, this method will definitely work. Actually, I've applied this method to a very simple JavaScript-based web game (single-player, but runs at a low freq).

However, cars are more complicated. When you calculate collisions using speed instead of position, it'll be really difficult to treat different parts of the car (bodyframe, attached parts, suspensions & wheels, etc) differently. It may get worse when the physical model of our game car becomes more detailed.

I'll be happy if the devs use this method as an alternative when ridiculous forces are generated by the primary method. When the collision force becomes holy huge, you know it's wrong, so why not stop using the wrong result and turn to another not-so-realistic but more reasonable formula ?

BTW, the most ridiculous lag disaster I have seen was a crash happened on AS1. An unlucky XFG somehow lagged, rocketed up and flew across HALF of the circuit, eventually landing exactly on another unlucky XFG ! The XFG missile would definitely not launch itself if this method was applied.
This is all theory, and forbin is right, that the collisions cannot be over simplified if we want something remotely realistic; however, as stated by Keling, the current car "car rocket" model is no where near realistic either.

And so, like the rest of these suggestions, the decision is up to Scavier whether they would consider making these changes. I just wanted to get the thought out there even if it has already been thought about. At least the re-mentioning of the idea might insight consideration for a temporary fix.

@Keling

sorry I stole your thunder
#8 - CSU1
Quote from legoflamb :

A Solution: Void extremely high collision force values, then recalculate based on the closing speed at or near the instant before contact.

keeping this data in code and memory for every instance all of the (lag) time would add considerable overhead to the collision code I imagine. They just need to iron out some global bug's...

It rarely has happened to me over the last four years either...

stop downloading pr0n whilst you drive =)
But I must have my Pr0n

The lag, on my end, comes from the fact I am racing people from continents not connected to my own. Not many good pickup racing/drifting at 8 pm PST.

The collisions can't be written off just as poor connections, so limiting downloads while racing is not necessarily a fix.
Both the connection and the time zone problem gets much more severe if you live in West China (GMT+6).

I know many people here hate this, but I miss the GMotor way of multiplayer positioning. Have been twin drifting under 1000ms+ ping. The opponent was moving in a weird way, but there were no car rockets !
The small collisions don't have to be car rockets to end bad especially at SO. Sometimes a small scrape ends up being a heavy shunt, though the cars barely bumped each other. I my experience on LFS, while drifting, the cars rarely gets as close as while racing. Sometimes in a heated battle my opponent or I will attempt to maintain contact throughout at bend, and sometimes it doesn't end bad, but more often then not it does.

Another Colisions Thread
(11 posts, started )
FGED GREDG RDFGDR GSFDG