- Allow negative force for A_RadiusThrust.

SVN r4187 (trunk)
This commit is contained in:
Randy Heit 2013-03-20 02:41:59 +00:00
commit de20936b13
2 changed files with 6 additions and 6 deletions

View file

@ -838,8 +838,8 @@ DEFINE_ACTION_FUNCTION_PARAMS(AActor, A_RadiusThrust)
bool sourcenothrust = false;
if (force <= 0) force = 128;
if (distance <= 0) distance = force;
if (force == 0) force = 128;
if (distance <= 0) distance = abs(force);
// Temporarily negate MF2_NODMGTHRUST on the shooter, since it renders this function useless.
if (!(flags & RTF_NOTMISSILE) && self->target != NULL && self->target->flags2 & MF2_NODMGTHRUST)
@ -847,7 +847,6 @@ DEFINE_ACTION_FUNCTION_PARAMS(AActor, A_RadiusThrust)
sourcenothrust = true;
self->target->flags2 &= ~MF2_NODMGTHRUST;
}
int sourceflags2 = self->target != NULL ? self->target->flags2 : 0;
P_RadiusAttack (self, self->target, force, distance, self->DamageType, flags | RADF_NODAMAGE, fullthrustdistance);
P_CheckSplash(self, distance << FRACBITS);