mirror of
https://github.com/ZDoom/qzdoom.git
synced 2024-11-28 06:53:58 +00:00
- Added Gez's patch for removing MF4_FIRERESIST.
SVN r1177 (trunk)
This commit is contained in:
parent
371d4704b8
commit
30685c3a74
9 changed files with 20 additions and 23 deletions
|
@ -1,3 +1,6 @@
|
|||
August 19, 2008 (Changes by Graf Zahl)
|
||||
- Added Gez's patch for removing MF4_FIRERESIST.
|
||||
|
||||
August 18, 2008 (SBARINFO patch)
|
||||
- Fixed: DrawBar would not show.
|
||||
- Fixed: IsSelected took string constants instead of identifiers.
|
||||
|
|
|
@ -265,7 +265,6 @@ enum
|
|||
MF4_LOOKALLAROUND = 0x00010000, // Monster has eyes in the back of its head
|
||||
MF4_STANDSTILL = 0x00020000, // Monster should not chase targets unless attacked?
|
||||
MF4_SPECTRAL = 0x00040000,
|
||||
MF4_FIRERESIST = 0x00080000, // Actor takes half damage from fire
|
||||
MF4_NOSPLASHALERT = 0x00100000, // Splashes don't alert this monster
|
||||
MF4_SYNCHRONIZED = 0x00200000, // For actors spawned at load-time only: Do not randomize tics
|
||||
MF4_NOTARGETSWITCH = 0x00400000, // monster never switches target until current one is dead
|
||||
|
|
|
@ -951,23 +951,14 @@ void P_DamageMobj (AActor *target, AActor *inflictor, AActor *source, int damage
|
|||
if (olddam != damage && damage <= 0) return;
|
||||
}
|
||||
|
||||
// to be removed and replaced by an actual damage factor
|
||||
// once the actors using it are converted to DECORATE.
|
||||
if (mod == NAME_Fire && target->flags4 & MF4_FIRERESIST)
|
||||
DmgFactors * df = target->GetClass()->ActorInfo->DamageFactors;
|
||||
if (df != NULL)
|
||||
{
|
||||
damage /= 2;
|
||||
}
|
||||
else
|
||||
{
|
||||
DmgFactors * df = target->GetClass()->ActorInfo->DamageFactors;
|
||||
if (df != NULL)
|
||||
fixed_t * pdf = df->CheckKey(mod);
|
||||
if (pdf != NULL)
|
||||
{
|
||||
fixed_t * pdf = df->CheckKey(mod);
|
||||
if (pdf != NULL)
|
||||
{
|
||||
damage = FixedMul(damage, *pdf);
|
||||
if (damage <= 0) return;
|
||||
}
|
||||
damage = FixedMul(damage, *pdf);
|
||||
if (damage <= 0) return;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -100,6 +100,7 @@ enum
|
|||
DEPF_SHORTMISSILERANGE,
|
||||
DEPF_PICKUPFLASH,
|
||||
DEPF_QUARTERGRAVITY,
|
||||
DEPF_FIRERESIST,
|
||||
};
|
||||
|
||||
static flagdef ActorFlags[]=
|
||||
|
@ -208,7 +209,6 @@ static flagdef ActorFlags[]=
|
|||
DEFINE_FLAG(MF4, LOOKALLAROUND, AActor, flags4),
|
||||
DEFINE_FLAG(MF4, STANDSTILL, AActor, flags4),
|
||||
DEFINE_FLAG(MF4, SPECTRAL, AActor, flags4),
|
||||
DEFINE_FLAG(MF4, FIRERESIST, AActor, flags4),
|
||||
DEFINE_FLAG(MF4, NOSPLASHALERT, AActor, flags4),
|
||||
DEFINE_FLAG(MF4, SYNCHRONIZED, AActor, flags4),
|
||||
DEFINE_FLAG(MF4, NOTARGETSWITCH, AActor, flags4),
|
||||
|
@ -264,6 +264,7 @@ static flagdef ActorFlags[]=
|
|||
DEFINE_DEPRECATED_FLAG(SHORTMISSILERANGE),
|
||||
DEFINE_DEPRECATED_FLAG(LONGMELEERANGE),
|
||||
DEFINE_DEPRECATED_FLAG(QUARTERGRAVITY),
|
||||
DEFINE_DEPRECATED_FLAG(FIRERESIST),
|
||||
DEFINE_DUMMY_FLAG(NONETID),
|
||||
DEFINE_DUMMY_FLAG(ALLOWCLIENTSPAWN),
|
||||
};
|
||||
|
@ -434,6 +435,9 @@ static void HandleDeprecatedFlags(AActor *defaults, bool set, int index)
|
|||
case DEPF_QUARTERGRAVITY:
|
||||
defaults->gravity = set? FRACUNIT/4 : FRACUNIT;
|
||||
break;
|
||||
case DEPF_FIRERESIST:
|
||||
if (set) defaults->GetClass()->ActorInfo->DamageFactors->Insert("Fire", 0.5);
|
||||
else defaults->GetClass()->ActorInfo->DamageFactors->Remove("Fire");
|
||||
case DEPF_PICKUPFLASH:
|
||||
if (set)
|
||||
{
|
||||
|
|
|
@ -19,8 +19,8 @@ ACTOR Loremaster 12
|
|||
+NOBLOCKMONST
|
||||
+INCOMBAT
|
||||
+LOOKALLAROUND
|
||||
+FIRERESIST
|
||||
+NOICEDEATH
|
||||
DamageFactor "Fire", 0.5
|
||||
MinMissileChance 150
|
||||
Tag "PRIEST"
|
||||
SeeSound "loremaster/sight"
|
||||
|
|
|
@ -13,10 +13,10 @@ ACTOR Macil1 64 native
|
|||
Monster
|
||||
-COUNTKILL
|
||||
+NOTDMATCH
|
||||
+FIRERESIST
|
||||
+NOICEDEATH
|
||||
+NOSPLASHALERT
|
||||
+NODAMAGE
|
||||
DamageFactor "Fire", 0.5
|
||||
MinMissileChance 150
|
||||
SeeSound "macil/sight"
|
||||
PainSound "macil/pain"
|
||||
|
|
|
@ -10,7 +10,7 @@ ACTOR Oracle 199 native
|
|||
Height 56
|
||||
Monster
|
||||
+NOTDMATCH
|
||||
+FIRERESIST
|
||||
DamageFactor "Fire", 0.5
|
||||
MaxDropoffHeight 32
|
||||
Tag "Oracle"
|
||||
DropItem "Meat"
|
||||
|
@ -31,4 +31,4 @@ ACTOR Oracle 199 native
|
|||
ORCL Q -1
|
||||
Stop
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -21,9 +21,9 @@ ACTOR Programmer 71
|
|||
+DONTMORPH
|
||||
+NOBLOCKMONST
|
||||
+LOOKALLAROUND
|
||||
+FIRERESIST
|
||||
+NOICEDEATH
|
||||
+NOTARGETSWITCH
|
||||
DamageFactor "Fire", 0.5
|
||||
MinMissileChance 150
|
||||
AttackSound "programmer/attack"
|
||||
PainSound "programmer/pain"
|
||||
|
|
|
@ -16,8 +16,8 @@ ACTOR StrifeBishop 187
|
|||
+NOTDMATCH
|
||||
+FLOORCLIP
|
||||
+INCOMBAT
|
||||
+FIRERESIST
|
||||
+NOICEDEATH
|
||||
DamageFactor "Fire", 0.5
|
||||
MinMissileChance 150
|
||||
MaxDropoffHeight 32
|
||||
SeeSound "bishop/sight"
|
||||
|
|
Loading…
Reference in a new issue