mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-11 07:12:16 +00:00
- fixed: When trying to calculate the damage for a blasted actor hitting another one, the velocity checks used the signed values, causing totally random damaging effects depending on the direction the objects were moving. This bug had been present in the original Hexen source as well.
This commit is contained in:
parent
6417c1a7a3
commit
2e99681ced
1 changed files with 1 additions and 1 deletions
|
@ -1256,7 +1256,7 @@ bool PIT_CheckThing(FMultiBlockThingsIterator &it, FMultiBlockThingsIterator::Ch
|
|||
{
|
||||
// ideally this should take the mass factor into account
|
||||
thing->Vel += tm.thing->Vel.XY();
|
||||
if ((thing->Vel.X + thing->Vel.Y) > 3.)
|
||||
if (fabs(thing->Vel.X) + fabs(thing->Vel.Y) > 3.)
|
||||
{
|
||||
int newdam;
|
||||
damage = (tm.thing->Mass / 100) + 1;
|
||||
|
|
Loading…
Reference in a new issue