mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-25 11:10:47 +00:00
Use engine's cstat defines
# Conflicts: # source/blood/src/mapedit.cpp
This commit is contained in:
parent
9c5cbd6308
commit
ce43103ae9
5 changed files with 14 additions and 36 deletions
|
@ -2542,8 +2542,8 @@ void actInit(void)
|
||||||
case 80: // Random ammo
|
case 80: // Random ammo
|
||||||
|
|
||||||
// Make sprites invisible and non-blocking
|
// Make sprites invisible and non-blocking
|
||||||
pSprite->cstat &= ~kSprBlock;
|
pSprite->cstat &= ~CSTAT_SPRITE_BLOCK;
|
||||||
pSprite->cstat |= kSprInvisible;
|
pSprite->cstat |= CSTAT_SPRITE_INVISIBLE;
|
||||||
|
|
||||||
if (pSprite->extra > 0 && xsprite[pSprite->extra].state == 1)
|
if (pSprite->extra > 0 && xsprite[pSprite->extra].state == 1)
|
||||||
trTriggerSprite(nSprite, &xsprite[pSprite->extra], COMMAND_ID_0);
|
trTriggerSprite(nSprite, &xsprite[pSprite->extra], COMMAND_ID_0);
|
||||||
|
@ -3073,7 +3073,7 @@ void actKillDude(int a1, spritetype *pSprite, DAMAGE_TYPE a3, int a4)
|
||||||
sfxPlayGDXGenDudeSound(pSprite, 10, pXSprite->data3);
|
sfxPlayGDXGenDudeSound(pSprite, 10, pXSprite->data3);
|
||||||
spritetype* pEffect = gFX.fxSpawn((FX_ID)52, pSprite->sectnum, pSprite->x, pSprite->y, pSprite->z, pSprite->ang);
|
spritetype* pEffect = gFX.fxSpawn((FX_ID)52, pSprite->sectnum, pSprite->x, pSprite->y, pSprite->z, pSprite->ang);
|
||||||
if (pEffect != NULL) {
|
if (pEffect != NULL) {
|
||||||
pEffect->cstat = kSprFace;
|
pEffect->cstat = CSTAT_SPRITE_ALIGNMENT_FACING;
|
||||||
pEffect->pal = 6;
|
pEffect->pal = 6;
|
||||||
pEffect->xrepeat = pSprite->xrepeat;
|
pEffect->xrepeat = pSprite->xrepeat;
|
||||||
pEffect->yrepeat = pSprite->yrepeat;
|
pEffect->yrepeat = pSprite->yrepeat;
|
||||||
|
|
|
@ -1762,7 +1762,7 @@ void aiInitSprite(spritetype *pSprite)
|
||||||
case 224:
|
case 224:
|
||||||
case 225:
|
case 225:
|
||||||
case 226:
|
case 226:
|
||||||
if ((pSprite->cstat & kSprFlipY) != 0) {
|
if ((pSprite->cstat & CSTAT_SPRITE_YFLIP) != 0) {
|
||||||
if (!(pSprite->hitag & kHitagExtBit)) // don't add autoaim for player if hitag 1 specified in editor.
|
if (!(pSprite->hitag & kHitagExtBit)) // don't add autoaim for player if hitag 1 specified in editor.
|
||||||
pSprite->hitag = kHitagAutoAim;
|
pSprite->hitag = kHitagAutoAim;
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -1111,7 +1111,7 @@ void removeLeech(spritetype* pLeech, bool delSprite) {
|
||||||
if (pLeech != NULL) {
|
if (pLeech != NULL) {
|
||||||
spritetype* pEffect = gFX.fxSpawn((FX_ID)52,pLeech->sectnum,pLeech->x,pLeech->y,pLeech->z,pLeech->ang);
|
spritetype* pEffect = gFX.fxSpawn((FX_ID)52,pLeech->sectnum,pLeech->x,pLeech->y,pLeech->z,pLeech->ang);
|
||||||
if (pEffect != NULL) {
|
if (pEffect != NULL) {
|
||||||
pEffect->cstat = kSprFace;
|
pEffect->cstat = CSTAT_SPRITE_ALIGNMENT_FLOOR;
|
||||||
pEffect->pal = 6;
|
pEffect->pal = 6;
|
||||||
int repeat = 64 + Random(50);
|
int repeat = 64 + Random(50);
|
||||||
pEffect->xrepeat = repeat;
|
pEffect->xrepeat = repeat;
|
||||||
|
@ -1259,7 +1259,7 @@ bool doExplosion(spritetype* pSprite, int nType) {
|
||||||
pExplosion->yrepeat = pExpl->at0;
|
pExplosion->yrepeat = pExpl->at0;
|
||||||
pExplosion->xrepeat = pExpl->at0;
|
pExplosion->xrepeat = pExpl->at0;
|
||||||
pExplosion->lotag = nType;
|
pExplosion->lotag = nType;
|
||||||
pExplosion->cstat |= kSprInvisible | kSprOriginAlign;
|
pExplosion->cstat |= CSTAT_SPRITE_INVISIBLE | CSTAT_SPRITE_YCENTER;
|
||||||
pExplosion->owner = pSprite->xvel;
|
pExplosion->owner = pSprite->xvel;
|
||||||
|
|
||||||
if (pExplosion->extra >= 0) {
|
if (pExplosion->extra >= 0) {
|
||||||
|
|
|
@ -120,28 +120,6 @@ void QuitGame(void);
|
||||||
#define kMarkerLowGoo 14
|
#define kMarkerLowGoo 14
|
||||||
#define kMarkerPath 15
|
#define kMarkerPath 15
|
||||||
|
|
||||||
// sprite cstat
|
|
||||||
#define kSprBlock 0x0001
|
|
||||||
#define kSprTrans 0x0002
|
|
||||||
#define kSprFlipX 0x0004
|
|
||||||
#define kSprFlipY 0x0008
|
|
||||||
#define kSprFace 0x0000
|
|
||||||
#define kSprWall 0x0010
|
|
||||||
#define kSprFloor 0x0020
|
|
||||||
#define kSprSpin 0x0030
|
|
||||||
#define kSprRMask 0x0030
|
|
||||||
#define kSprOneSided 0x0040
|
|
||||||
#define kSprOriginAlign 0x0080
|
|
||||||
#define kSprHitscan 0x0100
|
|
||||||
#define kSprTransR 0x0200
|
|
||||||
#define kSprPushable 0x1000
|
|
||||||
#define kSprMoveMask 0x6000
|
|
||||||
#define kSprMoveNone 0x0000
|
|
||||||
#define kSprMoveForward 0x2000
|
|
||||||
#define kSprMoveFloor 0x2000
|
|
||||||
#define kSprMoveReverse 0x4000
|
|
||||||
#define kSprMoveCeiling 0x4000
|
|
||||||
#define kSprInvisible 0x8000
|
|
||||||
|
|
||||||
// sprite attributes
|
// sprite attributes
|
||||||
#define kHitagMovePhys 0x0001 // affected by movement physics
|
#define kHitagMovePhys 0x0001 // affected by movement physics
|
||||||
|
|
|
@ -2979,7 +2979,7 @@ void pastePropertiesInObj(int type, int nDest, EVENT event) {
|
||||||
|
|
||||||
sprite[nDest].xrepeat = 4;
|
sprite[nDest].xrepeat = 4;
|
||||||
sprite[nDest].yrepeat = 4;
|
sprite[nDest].yrepeat = 4;
|
||||||
sprite[nDest].cstat |= kSprInvisible;
|
sprite[nDest].cstat |= CSTAT_SPRITE_INVISIBLE;
|
||||||
|
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
@ -3139,7 +3139,7 @@ void pastePropertiesInObj(int type, int nDest, EVENT event) {
|
||||||
sprite[nDest].hitag = pXSource->data3;
|
sprite[nDest].hitag = pXSource->data3;
|
||||||
|
|
||||||
if (valueIsBetween(pXSource->data4, -1, 65535)) {
|
if (valueIsBetween(pXSource->data4, -1, 65535)) {
|
||||||
pXSource->data4 |= kSprOriginAlign;
|
pXSource->data4 |= CSTAT_SPRITE_YCENTER;
|
||||||
sprite[nDest].cstat = pXSource->data4;
|
sprite[nDest].cstat = pXSource->data4;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
@ -3850,8 +3850,8 @@ void InitGenerator(int nSprite)
|
||||||
{
|
{
|
||||||
// By NoOne: intialize GDX generators
|
// By NoOne: intialize GDX generators
|
||||||
case kGDXDudeTargetChanger:
|
case kGDXDudeTargetChanger:
|
||||||
pSprite->cstat &= ~kSprBlock;
|
pSprite->cstat &= ~CSTAT_SPRITE_BLOCK;
|
||||||
pSprite->cstat |= kSprInvisible;
|
pSprite->cstat |= CSTAT_SPRITE_INVISIBLE;
|
||||||
if (pXSprite->busyTime <= 0) pXSprite->busyTime = 5;
|
if (pXSprite->busyTime <= 0) pXSprite->busyTime = 5;
|
||||||
if (pXSprite->state != pXSprite->restState)
|
if (pXSprite->state != pXSprite->restState)
|
||||||
evPost(nSprite, 3, 0, COMMAND_ID_21);
|
evPost(nSprite, 3, 0, COMMAND_ID_21);
|
||||||
|
@ -3859,14 +3859,14 @@ void InitGenerator(int nSprite)
|
||||||
case kGDXObjDataAccumulator:
|
case kGDXObjDataAccumulator:
|
||||||
case kGDXSeqSpawner:
|
case kGDXSeqSpawner:
|
||||||
case kGDXEffectSpawner:
|
case kGDXEffectSpawner:
|
||||||
pSprite->cstat &= ~kSprBlock;
|
pSprite->cstat &= ~CSTAT_SPRITE_BLOCK;
|
||||||
pSprite->cstat |= kSprInvisible;
|
pSprite->cstat |= CSTAT_SPRITE_INVISIBLE;
|
||||||
if (pXSprite->state != pXSprite->restState)
|
if (pXSprite->state != pXSprite->restState)
|
||||||
evPost(nSprite, 3, 0, COMMAND_ID_21);
|
evPost(nSprite, 3, 0, COMMAND_ID_21);
|
||||||
return;
|
return;
|
||||||
case 700:
|
case 700:
|
||||||
pSprite->cstat &= ~kSprBlock;
|
pSprite->cstat &= ~CSTAT_SPRITE_BLOCK;
|
||||||
pSprite->cstat |= kSprInvisible;
|
pSprite->cstat |= CSTAT_SPRITE_INVISIBLE;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if (pXSprite->state != pXSprite->restState && pXSprite->busyTime > 0)
|
if (pXSprite->state != pXSprite->restState && pXSprite->busyTime > 0)
|
||||||
|
|
Loading…
Reference in a new issue