Page 1 of 1

Multiplayer - Bumping other ships - Slingshot + massive dam

Posted: Sun May 10, 2009 5:18 pm
by Thraka
I was playing co-op the other day, and while I like FF on (i don't know if you can turn it off, but i don't want to) the bumping into a friendly ship can be devistating. I was playing with two others when I saw one turn the cornor and run into the back of the other ship, who was not moving. The grinding sound was there then all of a sudden the ship was catipaulted back into the wall and exploded.

Another time, one ship and myself were in the coridoor waiting for the third. It looked like he had room to sqeeze by, but he sort of grinded into me and backed up. My shield went down from around 100 to 15 in that second of time.

I'm curious what everyone thinks bumping should be like in multiplayer. If you have a shield, I would think they should like bounce off eachother. Sort of the way current FPS do. Someone bumps you, and you move slightly out of the way.

However, I think there should still be a tiny bit of damage to the shield. But currently, it feels like they just get locked into eachother, almost like a magnet. And other times it doesn't seem to do any damage.

Posted: Sun May 10, 2009 6:50 pm
by pokeman7452
It does seem collision hanlding in D2X-XL has been degrading. Not surprising with all the hit detection adjustments.

Posted: Sun May 10, 2009 8:45 pm
by Kaizerwolf
I notice this happens with bosses as well in D2X-XL. You snag on to them, and you basically die instantly.

Posted: Sun May 10, 2009 8:59 pm
by karx11erx
That only happens with max. collision detection and is a problem I am trying to fix for years. Sometimes the resulting vector from collision is extremely big, and I don't know why. Integer overflow? The basic math seems correct. Maybe I should try to have that stuff computed using double instead of the fixed floating point format Descent 1 and 2 are using.

Edit:

The problem is that the collision force calculations in Descent 1 and 2 are complete rubbish. The original code produces some kickback on collisions. I have added something to compute a proper reflection angle when two objects collide, but didn't rewrite the other stuff into halfway useable collision physics.

The Descent 1 and 2 code is such a bullshit. Just as the Freespace code is.

Posted: Mon May 11, 2009 1:32 am
by Melacon
I'm no programmer (in the process of teaching myself), but couldn't a simple "if" conditional statement that checks the velocity component of the vector is greater than a certain value, and if it is, assigns the velocity component that maximum value?

Posted: Mon May 11, 2009 3:26 am
by Sirius
That is kind of a band-aid approach though... it doesn't fix the problem, it just limits how bad it can get if it happens. (Also, perhaps some things can legitimately be moving at that velocity...)

Posted: Mon May 11, 2009 4:03 am
by Melacon
I understand that it would be band aid approach - but until the physics is fixed up, would it not work if it were only applied to player objects?

Posted: Mon May 11, 2009 6:50 am
by Yokelassence
If the solution was that simple then Karx would have implemented it by now. I don't think the massive damage resulting from collision is the result of single large damage value that can be measured against a safeguard.

Instead I think it is because the damage dealt by collision is occurring hundreds times in a single second because the hitboxes of two objects are indefinitely jammed together and therefor is constantly triggering collision damage about as quickly as your CPU sends a clock cycle. Meanwhile the value that determines that damage is actually very small.

The proper fix would be to ensure that hitboxes can never enter the space of another hitbox through some way or anther.

Posted: Mon May 11, 2009 9:39 am
by karx11erx
As I wrote this is a classical case of rigid body collision. I just have to implement it. No need to implement ugly hacks to reduce computative errors produced by the current code to acceptable dimensions.

Posted: Mon May 11, 2009 9:45 am
by Melacon
karx11erx wrote:As I wrote this is a classical case of rigid body collision. I just have to implement it. No need to implement ugly hacks to reduce computative errors produced by the current code to acceptable dimensions.


lol - nice response :lol:

Posted: Mon May 11, 2009 10:44 am
by pokeman7452
So, are the shields or the actual ship models supposed to collide? I bet there are plenty of sphere-to-sphere collision scripts and guides online. (me starts imagining "pyro pinball")

Posted: Mon May 11, 2009 12:31 pm
by karx11erx
Spheres.