diff --git a/polymer/eduke32/source/game.c b/polymer/eduke32/source/game.c index 3dc266586..df89a38a8 100644 --- a/polymer/eduke32/source/game.c +++ b/polymer/eduke32/source/game.c @@ -5633,8 +5633,8 @@ int32_t A_Spawn(int32_t j, int32_t pn) case MASKWALL13__STATIC: case MASKWALL14__STATIC: case MASKWALL15__STATIC: - j = sp->cstat&60; - sp->cstat = j|1; + j = sp->cstat & SPAWN_PROTECT_CSTAT_MASK; + sp->cstat = j|CSTAT_SPRITE_BLOCK; changespritestat(i, STAT_DEFAULT); break; case FOOTPRINTS__STATIC: diff --git a/polymer/eduke32/source/game.h b/polymer/eduke32/source/game.h index bff508156..594fdbabd 100644 --- a/polymer/eduke32/source/game.h +++ b/polymer/eduke32/source/game.h @@ -386,6 +386,11 @@ extern vec2_t G_ScreenTextShadow(int32_t sx, int32_t sy, const int32_t font, int if (alpha < 0) { blend = -alpha; alpha = 0; orientation |= RS_TRANS1; } \ } while (0) +// Cstat protection mask for (currently) spawned MASKWALL* sprites. +// TODO: look at more cases of cstat=(cstat&PROTECTED)|ADDED in A_Spawn()? +// 2048+(32+16)+8+4 +#define SPAWN_PROTECT_CSTAT_MASK (CSTAT_SPRITE_NOSHADE|CSTAT_SPRITE_SLAB|CSTAT_SPRITE_XFLIP|CSTAT_SPRITE_YFLIP); + int32_t app_main(int32_t argc,const char **argv); void fadepal(int32_t r,int32_t g,int32_t b,int32_t start,int32_t end,int32_t step); //void fadepaltile(int32_t r,int32_t g,int32_t b,int32_t start,int32_t end,int32_t step,int32_t tile);