- added MF7_ALWAYSTELEFRAG flag that causes an actor to be telefragged by everything that teleports into the same place.

This commit is contained in:
Christoph Oelckers 2013-08-13 21:01:14 +02:00
parent 9ebf345fec
commit 7a87e08107
3 changed files with 4 additions and 1 deletions

View file

@ -338,6 +338,7 @@ enum
MF7_NEVERTARGET = 0x00000001, // can not be targetted at all, even if monster friendliness is considered.
MF7_NOTELESTOMP = 0x00000002, // cannot telefrag under any circumstances (even when set by MAPINFO)
MF7_ALWAYSTELEFRAG = 0x00000004, // will unconditionally be telefragged when in the way. Overrides all other settings.
// --- mobj.renderflags ---

View file

@ -382,7 +382,8 @@ bool P_TeleportMove (AActor *thing, fixed_t x, fixed_t y, fixed_t z, bool telefr
// monsters don't stomp things except on boss level
// [RH] Some Heretic/Hexen monsters can telestomp
if (StompAlwaysFrags && !(th->flags6 & MF6_NOTELEFRAG))
// ... and some items can never be telefragged while others will be telefragged by everything that teleports upon them.
if ((StompAlwaysFrags && !(th->flags6 & MF6_NOTELEFRAG)) || (th->flags7 & MF7_ALWAYSTELEFRAG))
{
P_DamageMobj (th, thing, thing, TELEFRAG_DAMAGE, NAME_Telefrag, DMG_THRUSTLESS);
continue;

View file

@ -239,6 +239,7 @@ static FFlagDef ActorFlags[]=
DEFINE_FLAG(MF7, NEVERTARGET, AActor, flags7),
DEFINE_FLAG(MF7, NOTELESTOMP, AActor, flags7),
DEFINE_FLAG(MF7, ALWAYSTELEFRAG, AActor, flags7),
// Effect flags
DEFINE_FLAG(FX, VISIBILITYPULSE, AActor, effects),