A_Explode now returns the number of actors damaged and can be used in expressions.
- Enemies that do not take damage in any way are not counted.
This commit is contained in:
parent
ee7d933ed6
commit
ec14dd94a7
5 changed files with 29 additions and 18 deletions
|
|
@ -1414,13 +1414,13 @@ DEFINE_ACTION_FUNCTION_PARAMS(AActor, A_Explode)
|
|||
}
|
||||
}
|
||||
|
||||
P_RadiusAttack (self, self->target, damage, distance, self->DamageType, flags, fulldmgdistance);
|
||||
int count = P_RadiusAttack (self, self->target, damage, distance, self->DamageType, flags, fulldmgdistance);
|
||||
P_CheckSplash(self, distance);
|
||||
if (alert && self->target != NULL && self->target->player != NULL)
|
||||
{
|
||||
P_NoiseAlert(self->target, self);
|
||||
}
|
||||
return 0;
|
||||
ACTION_RETURN_INT(count);
|
||||
}
|
||||
|
||||
//==========================================================================
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue