diff --git a/src/thingdef/thingdef_codeptr.cpp b/src/thingdef/thingdef_codeptr.cpp index 2ba5fa01a4..69dd89cd0d 100644 --- a/src/thingdef/thingdef_codeptr.cpp +++ b/src/thingdef/thingdef_codeptr.cpp @@ -1857,6 +1857,9 @@ enum SIX_Flags SIXF_ORIGINATOR = 0x00800000, SIXF_TRANSFERSPRITEFRAME = 0x01000000, SIXF_TRANSFERROLL = 0x02000000, + SIXF_ISTARGET = 0x04000000, + SIXF_ISMASTER = 0x08000000, + SIXF_ISTRACER = 0x10000000, }; static bool InitSpawnedItem(AActor *self, AActor *mo, int flags) @@ -2014,6 +2017,18 @@ static bool InitSpawnedItem(AActor *self, AActor *mo, int flags) mo->roll = self->roll; } + if (flags & SIXF_ISTARGET) + { + self->target = mo; + } + if (flags & SIXF_ISMASTER) + { + self->master = mo; + } + if (flags & SIXF_ISTRACER) + { + self->tracer = mo; + } return true; } diff --git a/wadsrc/static/actors/constants.txt b/wadsrc/static/actors/constants.txt index 1ee6c96c92..96877a2664 100644 --- a/wadsrc/static/actors/constants.txt +++ b/wadsrc/static/actors/constants.txt @@ -74,6 +74,9 @@ const int SXF_NOPOINTERS = 1 << 22; const int SXF_ORIGINATOR = 1 << 23; const int SXF_TRANSFERSPRITEFRAME = 1 << 24; const int SXF_TRANSFERROLL = 1 << 25; +const int SXF_ISTARGET = 1 << 26, +const int SXF_ISMASTER = 1 << 27, +const int SXF_ISTRACER = 1 << 28, // Flags for A_Chase const int CHF_FASTCHASE = 1;