Created attachment 3142[details]
bugfix for "CanDamage" function
Hi,
Here is another patch for a bug in (io)quake3:
-------------------------------------------------------------------------------
BUG: Sometimes inflictor causes no damage to a target!
In other words, sometimes rockets, grenades etc. doesn't damage players.
-------------------------------------------------------------------------------
TEST: You will notice this bug not often, but if it happens, you will notice it
because a victim will even survive a quad/bfg shot.
Search for walls with a height of ~ 40 units (q3dm1 windows, mpteam5)
or create a test map:
________
| |
| |
| |
| BBOX |
| | __x__ <--- Impact point on top of wall = No damage
| | | |
| | | | <--- Wall with a height of 32 - 48 units
______|______|_| |_______
Stay near to this wall, fire a rocket on the top plane of that wall!
Try to hit the center of that plane, you won't get damaged!
-------------------------------------------------------------------------------
(POSSIBLE) SOLUTION: see attached patch!
-------------------------------------------------------------------------------
NOTE: The id comment: // this should probably check in the plane of projection,
rather than in world coordinate, and also include Z
represents what I am talking about. I didn't delete it because maybe
there is a better solution for that bug. On planes with a hight of 48
units the bug still occurs, maybe alter the offset vectors.
-------------------------------------------------------------------------------
I'm not sure if this solution is the best, so please check it out before you use
it. And as always if I did something wrong, forget about the patch!
with best regards,
Tobias Kuehnhammer
Created attachment 3142 [details] bugfix for "CanDamage" function Hi, Here is another patch for a bug in (io)quake3: ------------------------------------------------------------------------------- BUG: Sometimes inflictor causes no damage to a target! In other words, sometimes rockets, grenades etc. doesn't damage players. ------------------------------------------------------------------------------- TEST: You will notice this bug not often, but if it happens, you will notice it because a victim will even survive a quad/bfg shot. Search for walls with a height of ~ 40 units (q3dm1 windows, mpteam5) or create a test map: ________ | | | | | | | BBOX | | | __x__ <--- Impact point on top of wall = No damage | | | | | | | | <--- Wall with a height of 32 - 48 units ______|______|_| |_______ Stay near to this wall, fire a rocket on the top plane of that wall! Try to hit the center of that plane, you won't get damaged! ------------------------------------------------------------------------------- (POSSIBLE) SOLUTION: see attached patch! ------------------------------------------------------------------------------- NOTE: The id comment: // this should probably check in the plane of projection, rather than in world coordinate, and also include Z represents what I am talking about. I didn't delete it because maybe there is a better solution for that bug. On planes with a hight of 48 units the bug still occurs, maybe alter the offset vectors. ------------------------------------------------------------------------------- I'm not sure if this solution is the best, so please check it out before you use it. And as always if I did something wrong, forget about the patch! with best regards, Tobias Kuehnhammer