mirror of
https://github.com/ZDoom/gzdoom.git
synced 2024-11-12 23:54:17 +00:00
- Added SXF_TRANSFERSPECIAL and SXF_CLEARCALLERSPECIAL flags for A_SpawnItemEx.
SVN r4199 (trunk)
This commit is contained in:
parent
044616a86f
commit
c54ea7f6b7
2 changed files with 14 additions and 0 deletions
|
@ -1736,6 +1736,8 @@ enum SIX_Flags
|
||||||
SIXF_CLEARCALLERTID = 1 << 12,
|
SIXF_CLEARCALLERTID = 1 << 12,
|
||||||
SIXF_MULTIPLYSPEED = 1 << 13,
|
SIXF_MULTIPLYSPEED = 1 << 13,
|
||||||
SIXF_TRANSFERSCALE = 1 << 14,
|
SIXF_TRANSFERSCALE = 1 << 14,
|
||||||
|
SIXF_TRANSFERSPECIAL = 1 << 15,
|
||||||
|
SIXF_CLEARCALLERSPECIAL = 1 << 16,
|
||||||
};
|
};
|
||||||
|
|
||||||
static bool InitSpawnedItem(AActor *self, AActor *mo, int flags)
|
static bool InitSpawnedItem(AActor *self, AActor *mo, int flags)
|
||||||
|
@ -1838,6 +1840,16 @@ static bool InitSpawnedItem(AActor *self, AActor *mo, int flags)
|
||||||
self->RemoveFromHash();
|
self->RemoveFromHash();
|
||||||
self->tid = 0;
|
self->tid = 0;
|
||||||
}
|
}
|
||||||
|
if (flags & SIXF_TRANSFERSPECIAL)
|
||||||
|
{
|
||||||
|
mo->special = self->special;
|
||||||
|
memcpy(mo->args, self->args, sizeof(self->args));
|
||||||
|
}
|
||||||
|
if (flags & SIXF_CLEARCALLERSPECIAL)
|
||||||
|
{
|
||||||
|
self->special = 0;
|
||||||
|
memset(self->args, 0, sizeof(self->args));
|
||||||
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -57,6 +57,8 @@ const int SXF_USEBLOODCOLOR = 2048;
|
||||||
const int SXF_CLEARCALLERTID = 4096;
|
const int SXF_CLEARCALLERTID = 4096;
|
||||||
const int SXF_MULTIPLYSPEED = 8192;
|
const int SXF_MULTIPLYSPEED = 8192;
|
||||||
const int SXF_TRANSFERSCALE = 16384;
|
const int SXF_TRANSFERSCALE = 16384;
|
||||||
|
const int SXF_TRANSFERSPECIAL = 32768;
|
||||||
|
const int SXF_CLEARCALLERSPECIAL = 65536;
|
||||||
|
|
||||||
// Flags for A_Chase
|
// Flags for A_Chase
|
||||||
const int CHF_FASTCHASE = 1;
|
const int CHF_FASTCHASE = 1;
|
||||||
|
|
Loading…
Reference in a new issue