- Fixed: S_StopSound may not assume that after stopping a sound channel
its link to the next item in the list is still valid. - Fixed typo in src/CMakeLists.txt. - Fixed: Armor only worked for players. SVN r1489 (trunk)
This commit is contained in:
parent
ca454bfeb3
commit
18b4577bbd
4 changed files with 37 additions and 6 deletions
|
|
@ -1155,6 +1155,18 @@ void P_DamageMobj (AActor *target, AActor *inflictor, AActor *source, int damage
|
|||
}
|
||||
else
|
||||
{
|
||||
// Armor for monsters.
|
||||
if (!(flags & DMG_NO_ARMOR) && target->Inventory != NULL)
|
||||
{
|
||||
int newdam = damage;
|
||||
target->Inventory->AbsorbDamage (damage, mod, newdam);
|
||||
damage = newdam;
|
||||
if (damage <= 0)
|
||||
{
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
target->health -= damage;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue