mirror of
https://github.com/ZDoom/raze-gles.git
synced 2024-12-24 10:40:46 +00:00
- made THINGINFO const.
This commit is contained in:
parent
7a8208eb2f
commit
5c7b05a791
3 changed files with 8 additions and 8 deletions
|
@ -1707,7 +1707,7 @@ MissileType missileInfo[] = {
|
|||
}
|
||||
};
|
||||
|
||||
THINGINFO thingInfo[] = {
|
||||
const THINGINFO thingInfo[] = {
|
||||
//TNT Barrel
|
||||
{
|
||||
25,
|
||||
|
@ -3868,7 +3868,7 @@ void actImpactMissile(spritetype *pMissile, int hitCode)
|
|||
sectortype *pSectorHit = NULL; XSECTOR *pXSectorHit = NULL;
|
||||
|
||||
actHitcodeToData(hitCode, &gHitInfo, &nSpriteHit, &pSpriteHit, &pXSpriteHit, &nWallHit, &pWallHit, &pXWallHit, &nSectorHit, &pSectorHit, &pXSectorHit);
|
||||
THINGINFO *pThingInfo = NULL; DUDEINFO *pDudeInfo = NULL;
|
||||
const THINGINFO *pThingInfo = NULL; DUDEINFO *pDudeInfo = NULL;
|
||||
|
||||
if (hitCode == 3 && pSpriteHit) {
|
||||
switch (pSpriteHit->statnum) {
|
||||
|
@ -4211,7 +4211,7 @@ void ProcessTouchObjects(spritetype *pSprite, int nXSprite)
|
|||
if (pSprite2->statnum == kStatThing)
|
||||
{
|
||||
int nType = pSprite2->type-kThingBase;
|
||||
THINGINFO *pThingInfo = &thingInfo[nType];
|
||||
const THINGINFO *pThingInfo = &thingInfo[nType];
|
||||
if (pThingInfo->flags&1)
|
||||
|
||||
pSprite2->flags |= 1;
|
||||
|
@ -4546,7 +4546,7 @@ int MoveThing(spritetype *pSprite)
|
|||
int nSprite = pSprite->index;
|
||||
int v8 = 0;
|
||||
dassert(pSprite->type >= kThingBase && pSprite->type < kThingMax);
|
||||
THINGINFO *pThingInfo = &thingInfo[pSprite->type-kThingBase];
|
||||
const THINGINFO *pThingInfo = &thingInfo[pSprite->type-kThingBase];
|
||||
int nSector = pSprite->sectnum;
|
||||
dassert(nSector >= 0 && nSector < kMaxSectors);
|
||||
int top, bottom;
|
||||
|
@ -5829,7 +5829,7 @@ void actProcessSprites(void)
|
|||
if (pXSector && pXSector->panVel && (pXSector->panAlways || pXSector->state || pXSector->busy))
|
||||
{
|
||||
int nType = pSprite->type - kThingBase;
|
||||
THINGINFO *pThingInfo = &thingInfo[nType];
|
||||
const THINGINFO *pThingInfo = &thingInfo[nType];
|
||||
if (pThingInfo->flags & 1)
|
||||
|
||||
pSprite->flags |= 1;
|
||||
|
@ -6546,7 +6546,7 @@ spritetype * actSpawnThing(int nSector, int x, int y, int z, int nThingType)
|
|||
pSprite->type = nThingType;
|
||||
dassert(nXThing > 0 && nXThing < kMaxXSprites);
|
||||
XSPRITE *pXThing = &xsprite[nXThing];
|
||||
THINGINFO *pThingInfo = &thingInfo[nType];
|
||||
const THINGINFO *pThingInfo = &thingInfo[nType];
|
||||
pXThing->health = pThingInfo->startHealth<<4;
|
||||
pSprite->clipdist = pThingInfo->clipdist;
|
||||
pSprite->flags = pThingInfo->flags;
|
||||
|
|
|
@ -186,7 +186,7 @@ extern WEAPONITEMDATA gWeaponItemData[];
|
|||
extern ITEMDATA gItemData[];
|
||||
extern MissileType missileInfo[];
|
||||
extern EXPLOSION explodeInfo[];
|
||||
extern THINGINFO thingInfo[];
|
||||
extern const THINGINFO thingInfo[];
|
||||
extern VECTORDATA gVectorData[];
|
||||
|
||||
extern int gDudeDrag;
|
||||
|
|
|
@ -284,7 +284,7 @@ static void ThrowThing(int nXIndex, bool impact) {
|
|||
if (curWeapon < kThingBase || curWeapon >= kThingMax)
|
||||
return;
|
||||
|
||||
THINGINFO* pThinkInfo = &thingInfo[curWeapon - kThingBase];
|
||||
const THINGINFO* pThinkInfo = &thingInfo[curWeapon - kThingBase];
|
||||
if (!pThinkInfo->allowThrow) return;
|
||||
|
||||
if (!playGenDudeSound(pSprite, kGenDudeSndAttackThrow))
|
||||
|
|
Loading…
Reference in a new issue