mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-10 23:02:08 +00:00
- fixed: P_RadiusAttack should not call P_DamageMobj for a damage value of 0.
This could happen if the damage calculations resulted in a value between 0 and 1, which for the actual check was multiplied with the damage parameter of P_RadiusAttack which inflated the fractional value to something that looked like actual damage but was later truncated.
This commit is contained in:
parent
6d441e25db
commit
1011e26eb9
1 changed files with 1 additions and 1 deletions
|
@ -5363,7 +5363,7 @@ void P_RadiusAttack(AActor *bombspot, AActor *bombsource, int bombdamage, int bo
|
|||
points *= thing->GetClass()->RDFactor / (float)FRACUNIT;
|
||||
|
||||
// points and bombdamage should be the same sign
|
||||
if (((points * bombdamage) > 0) && P_CheckSight(thing, bombspot, SF_IGNOREVISIBILITY | SF_IGNOREWATERBOUNDARY))
|
||||
if (((int(points) * bombdamage) > 0) && P_CheckSight(thing, bombspot, SF_IGNOREVISIBILITY | SF_IGNOREWATERBOUNDARY))
|
||||
{ // OK to damage; target is in direct path
|
||||
double vz;
|
||||
double thrust;
|
||||
|
|
Loading…
Reference in a new issue