- fixed wrong display of Hexen AC for SBARINFO

Do not use BasicArmor's save percentage when no armor present
Applied change from 34c2c65bb6 to old status bar definitions
This commit is contained in:
alexey.lysiuk 2019-12-01 10:30:06 +02:00 committed by drfrag
parent d4a71e3d20
commit f463cf3e73

View file

@ -1420,7 +1420,7 @@ class CommandDrawNumber : public CommandDrawString
add = Slots[0] + Slots[1] + Slots[2] + Slots[3] + Slots[4];
}
//Hexen counts basic armor also so we should too.
if(statusBar->armor != NULL)
if(statusBar->armor != nullptr && statusBar->armor->IntVar(NAME_Amount) > 0)
{
add += statusBar->armor->FloatVar(NAME_SavePercent) * 100;
}