mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-10 23:02:08 +00:00
Fixed applying of multiple damage factors
https://mantis.zdoom.org/view.php?id=586
This commit is contained in:
parent
0ebf4958b9
commit
490fd8f3a0
1 changed files with 5 additions and 2 deletions
|
@ -513,8 +513,11 @@ void PClassActor::SetDamageFactor(FName type, double factor)
|
|||
{
|
||||
for (auto & p : ActorInfo()->DamageFactors)
|
||||
{
|
||||
if (p.first == type) p.second = factor;
|
||||
return;
|
||||
if (p.first == type)
|
||||
{
|
||||
p.second = factor;
|
||||
return;
|
||||
}
|
||||
}
|
||||
ActorInfo()->DamageFactors.Push({ type, factor });
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue