diff --git a/src/actor.h b/src/actor.h index 9c326fdc68a..71295794af5 100644 --- a/src/actor.h +++ b/src/actor.h @@ -403,6 +403,7 @@ enum ActorFlag8 MF8_INSCROLLSEC = 0x00000002, // actor is partially inside a scrolling sector MF8_BLOCKASPLAYER = 0x00000004, // actor is blocked by player-blocking lines even if not a player MF8_DONTFACETALKER = 0x00000008, // don't alter the angle to face the player in conversations + MF8_HITOWNER = 0x00000010, // projectile can hit the actor that fired it }; // --- mobj.renderflags --- diff --git a/src/p_map.cpp b/src/p_map.cpp index 2e3e246518e..c43a739d426 100644 --- a/src/p_map.cpp +++ b/src/p_map.cpp @@ -1554,8 +1554,8 @@ bool PIT_CheckThing(FMultiBlockThingsIterator &it, FMultiBlockThingsIterator::Ch if (tm.thing->target != NULL) { - if (thing == tm.thing->target) - { // Don't missile self + if (thing == tm.thing->target && !(tm.thing->flags8 & MF8_HITOWNER)) + { // Don't missile self -- [MK] unless explicitly allowed return true; } diff --git a/src/scripting/thingdef_data.cpp b/src/scripting/thingdef_data.cpp index c0ef05e2398..ca6bee2a440 100644 --- a/src/scripting/thingdef_data.cpp +++ b/src/scripting/thingdef_data.cpp @@ -318,6 +318,7 @@ static FFlagDef ActorFlagDefs[]= DEFINE_FLAG(MF8, FRIGHTENING, AActor, flags8), DEFINE_FLAG(MF8, BLOCKASPLAYER, AActor, flags8), DEFINE_FLAG(MF8, DONTFACETALKER, AActor, flags8), + DEFINE_FLAG(MF8, HITOWNER, AActor, flags8), // Effect flags DEFINE_FLAG(FX, VISIBILITYPULSE, AActor, effects),