mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-26 03:30:46 +00:00
Fix more uses of lotag with values >= 32768 beyond those reported as warnings.
git-svn-id: https://svn.eduke32.com/eduke32@6602 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
parent
1396f51ca2
commit
af6097a281
4 changed files with 13 additions and 13 deletions
|
@ -6449,7 +6449,7 @@ ACTOR_STATIC void G_MoveEffectors(void) //STATNUM 3
|
||||||
|
|
||||||
if (animGoal >= 0)
|
if (animGoal >= 0)
|
||||||
{
|
{
|
||||||
int shadeInc = ((pSector->lotag & 0x8000) || actor[spriteNum].t_data[4]) ? -pData[3] : pData[3];
|
int shadeInc = ((pSector->lotag & 0x8000u) || actor[spriteNum].t_data[4]) ? -pData[3] : pData[3];
|
||||||
|
|
||||||
if (spriteLotag == SE_9_DOWN_OPEN_DOOR_LIGHTS)
|
if (spriteLotag == SE_9_DOWN_OPEN_DOOR_LIGHTS)
|
||||||
shadeInc = -shadeInc;
|
shadeInc = -shadeInc;
|
||||||
|
@ -6499,7 +6499,7 @@ ACTOR_STATIC void G_MoveEffectors(void) //STATNUM 3
|
||||||
|
|
||||||
case SE_10_DOOR_AUTO_CLOSE:
|
case SE_10_DOOR_AUTO_CLOSE:
|
||||||
// XXX: 32791, what the hell?
|
// XXX: 32791, what the hell?
|
||||||
if ((pSector->lotag&0xff) == ST_27_STRETCH_BRIDGE || (pSector->floorz > pSector->ceilingz && (pSector->lotag&0xff) != ST_23_SWINGING_DOOR) || pSector->lotag == (int16_t)32791)
|
if ((pSector->lotag&0xff) == ST_27_STRETCH_BRIDGE || (pSector->floorz > pSector->ceilingz && (pSector->lotag&0xff) != ST_23_SWINGING_DOOR) || pSector->lotag == (int16_t)32791u)
|
||||||
{
|
{
|
||||||
j = 1;
|
j = 1;
|
||||||
|
|
||||||
|
|
|
@ -587,7 +587,7 @@ void G_DoCheats(void)
|
||||||
if (lotag == -1 || lotag == 32767) continue;
|
if (lotag == -1 || lotag == 32767) continue;
|
||||||
if ((lotag & 0x7fff) > 2)
|
if ((lotag & 0x7fff) > 2)
|
||||||
{
|
{
|
||||||
if (lotag&(0xffff-16384))
|
if (lotag & (uint16_t)~16384u)
|
||||||
sector[i].lotag &= (uint16_t)~16384u;
|
sector[i].lotag &= (uint16_t)~16384u;
|
||||||
G_OperateSectors(i, pPlayer->i);
|
G_OperateSectors(i, pPlayer->i);
|
||||||
}
|
}
|
||||||
|
|
|
@ -5284,7 +5284,7 @@ HORIZONLY:;
|
||||||
|
|
||||||
if (squishPlayer || klabs(actor[pPlayer->i].floorz-actor[pPlayer->i].ceilingz) < (48<<8))
|
if (squishPlayer || klabs(actor[pPlayer->i].floorz-actor[pPlayer->i].ceilingz) < (48<<8))
|
||||||
{
|
{
|
||||||
if (!(sector[pSprite->sectnum].lotag & 0x8000) &&
|
if (!(sector[pSprite->sectnum].lotag & 0x8000u) &&
|
||||||
(isanunderoperator(sector[pSprite->sectnum].lotag) || isanearoperator(sector[pSprite->sectnum].lotag)))
|
(isanunderoperator(sector[pSprite->sectnum].lotag) || isanearoperator(sector[pSprite->sectnum].lotag)))
|
||||||
G_ActivateBySector(pSprite->sectnum, pPlayer->i);
|
G_ActivateBySector(pSprite->sectnum, pPlayer->i);
|
||||||
|
|
||||||
|
|
|
@ -540,7 +540,7 @@ void G_OperateSectors(int sectNum, int spriteNum)
|
||||||
int32_t i;
|
int32_t i;
|
||||||
sectortype *const pSector = §or[sectNum];
|
sectortype *const pSector = §or[sectNum];
|
||||||
|
|
||||||
switch (pSector->lotag&(0xffff-49152))
|
switch (pSector->lotag & (uint16_t)~49152u)
|
||||||
{
|
{
|
||||||
case ST_30_ROTATE_RISE_BRIDGE:
|
case ST_30_ROTATE_RISE_BRIDGE:
|
||||||
j = sector[sectNum].hitag;
|
j = sector[sectNum].hitag;
|
||||||
|
@ -769,7 +769,7 @@ void G_OperateSectors(int sectNum, int spriteNum)
|
||||||
|
|
||||||
pSector->lotag ^= 0x8000u;
|
pSector->lotag ^= 0x8000u;
|
||||||
|
|
||||||
if (pSector->lotag&0x8000)
|
if (pSector->lotag & 0x8000u)
|
||||||
{
|
{
|
||||||
j = nextsectorneighborz(sectNum,pSector->ceilingz,-1,-1);
|
j = nextsectorneighborz(sectNum,pSector->ceilingz,-1,-1);
|
||||||
if (j == -1) j = nextsectorneighborz(sectNum,pSector->ceilingz,1,1);
|
if (j == -1) j = nextsectorneighborz(sectNum,pSector->ceilingz,1,1);
|
||||||
|
@ -799,7 +799,7 @@ void G_OperateSectors(int sectNum, int spriteNum)
|
||||||
case ST_20_CEILING_DOOR:
|
case ST_20_CEILING_DOOR:
|
||||||
REDODOOR:
|
REDODOOR:
|
||||||
|
|
||||||
if (pSector->lotag&0x8000)
|
if (pSector->lotag & 0x8000u)
|
||||||
{
|
{
|
||||||
for (SPRITES_OF_SECT(sectNum, i))
|
for (SPRITES_OF_SECT(sectNum, i))
|
||||||
if (sprite[i].statnum == STAT_EFFECTOR && SLT(i)==SE_9_DOWN_OPEN_DOOR_LIGHTS)
|
if (sprite[i].statnum == STAT_EFFECTOR && SLT(i)==SE_9_DOWN_OPEN_DOOR_LIGHTS)
|
||||||
|
@ -853,7 +853,7 @@ REDODOOR:
|
||||||
|
|
||||||
case ST_22_SPLITTING_DOOR:
|
case ST_22_SPLITTING_DOOR:
|
||||||
|
|
||||||
if (pSector->lotag&0x8000)
|
if (pSector->lotag & 0x8000u)
|
||||||
{
|
{
|
||||||
// WTF?
|
// WTF?
|
||||||
int const q = (pSector->ceilingz + pSector->floorz) >> 1;
|
int const q = (pSector->ceilingz + pSector->floorz) >> 1;
|
||||||
|
@ -898,7 +898,7 @@ REDODOOR:
|
||||||
if (i < 0)
|
if (i < 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
int const tag = sector[SECT(i)].lotag&0x8000;
|
uint16_t const tag = sector[SECT(i)].lotag & 0x8000u;
|
||||||
|
|
||||||
if (j >= 0)
|
if (j >= 0)
|
||||||
{
|
{
|
||||||
|
@ -906,9 +906,9 @@ REDODOOR:
|
||||||
|
|
||||||
for (SPRITES_OF(STAT_EFFECTOR, i))
|
for (SPRITES_OF(STAT_EFFECTOR, i))
|
||||||
{
|
{
|
||||||
if (tag == (sector[SECT(i)].lotag&0x8000) && SLT(i) == SE_11_SWINGING_DOOR && sprite[j].hitag == SHT(i) && !T5(i))
|
if (tag == (sector[SECT(i)].lotag & 0x8000u) && SLT(i) == SE_11_SWINGING_DOOR && sprite[j].hitag == SHT(i) && !T5(i))
|
||||||
{
|
{
|
||||||
if (sector[SECT(i)].lotag&0x8000) sector[SECT(i)].lotag &= 0x7fff;
|
if (sector[SECT(i)].lotag & 0x8000u) sector[SECT(i)].lotag &= 0x7fff;
|
||||||
else sector[SECT(i)].lotag |= 0x8000u;
|
else sector[SECT(i)].lotag |= 0x8000u;
|
||||||
|
|
||||||
T5(i) = 1;
|
T5(i) = 1;
|
||||||
|
@ -946,7 +946,7 @@ REDODOOR:
|
||||||
A_CallSound(SECT(i),i);
|
A_CallSound(SECT(i),i);
|
||||||
A_CallSound(SECT(i),i);
|
A_CallSound(SECT(i),i);
|
||||||
|
|
||||||
T5(i) = (sector[SECT(i)].lotag&0x8000) ? 1 : 2;
|
T5(i) = (sector[SECT(i)].lotag & 0x8000u) ? 1 : 2;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -960,7 +960,7 @@ REDODOOR:
|
||||||
sector[sectNum].lotag ^= 0x8000u;
|
sector[sectNum].lotag ^= 0x8000u;
|
||||||
// Highest bit now set means we're opening.
|
// Highest bit now set means we're opening.
|
||||||
|
|
||||||
actor[j].t_data[0] = (sector[sectNum].lotag&0x8000) ? 1 : 2;
|
actor[j].t_data[0] = (sector[sectNum].lotag & 0x8000u) ? 1 : 2;
|
||||||
A_CallSound(sectNum,spriteNum);
|
A_CallSound(sectNum,spriteNum);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue