- cleanup stuff.

Removed unneeded prototypes, renamed some variables; no logic changes.
This commit is contained in:
Christoph Oelckers 2021-11-23 01:21:55 +01:00
parent 943641d18e
commit 624ad6a2ad
5 changed files with 5 additions and 13 deletions

View file

@ -227,12 +227,10 @@ inline DExhumedActor* insertActor(sectortype* s, int st)
}
DExhumedActor* GrabBody();
DExhumedActor* GrabBodyGunSprite();
void CreatePushBlock(sectortype* pSector);
void FuncCreatureChunk(int a, int, int nRun);
DExhumedActor* FindPlayer(DExhumedActor* nSprite, int nDistance, bool dontengage = false);
DExhumedActor* BuildCreatureChunk(DExhumedActor* pSrc, int nPic, bool bSpecial = false);
void BuildNear(int x, int y, int walldist, int nSector);
int PlotCourseToSprite(DExhumedActor* nSprite1, DExhumedActor* nSprite2);
void CheckSectorFloor(sectortype* pSector, int z, int *x, int *y);
int GetAngleToSprite(DExhumedActor* nSprite1, DExhumedActor* nSprite2);
@ -247,7 +245,6 @@ void SetQuake(DExhumedActor* nSprite, int nVal);
enum { kMaxMummies = 150 };
void BuildMummy(DExhumedActor* val, int x, int y, int z, sectortype* pSector, int nAngle);
void FuncMummy(int nSector, int edx, int nRun);
// object

View file

@ -241,7 +241,7 @@ void ResetSwordSeqs()
WeaponInfo[kWeaponSword].b[3] = 7;
}
Collision CheckCloseRange(int nPlayer, int *x, int *y, int *z, sectortype* *nSector)
Collision CheckCloseRange(int nPlayer, int *x, int *y, int *z, sectortype* *ppSector)
{
int hitSect, hitWall, hitSprite;
int hitX, hitY, hitZ;
@ -254,7 +254,7 @@ Collision CheckCloseRange(int nPlayer, int *x, int *y, int *z, sectortype* *nSec
vec3_t startPos = { *x, *y, *z };
hitdata_t hitData;
hitscan(&startPos, sectnum(*nSector), xVect, yVect, 0, &hitData, CLIPMASK1);
hitscan(&startPos, sectnum(*ppSector), xVect, yVect, 0, &hitData, CLIPMASK1);
hitX = hitData.pos.x;
hitY = hitData.pos.y;
hitZ = hitData.pos.z;
@ -282,7 +282,7 @@ Collision CheckCloseRange(int nPlayer, int *x, int *y, int *z, sectortype* *nSec
*x = hitX;
*y = hitY;
*z = hitZ;
*nSector = &sector[hitSect];
*ppSector = &sector[hitSect];
if (hitSprite > -1) {
c.setSprite(&exhumedActors[hitSprite]);

View file

@ -30,8 +30,6 @@ int GrabPlayer();
void InitPlayerInventory(int nPlayer);
void RestartPlayer(int nPlayer);
void FuncPlayer(int, int nSector, int nSprite, int nRun);
enum
{
kMaxPlayers = 8,

View file

@ -745,9 +745,6 @@ void AIQueenHead::Tick(RunListEvent* ev)
auto pActor = QueenHead.pActor;
auto pSprite = &pActor->s();
int nSector = pSprite->sectnum;
assert(validSectorIndex(nSector));
int nAction = QueenHead.nAction;
int nHd;
int var_14 = 0;

View file

@ -271,13 +271,13 @@ DExhumedActor* FindSnakeEnemy(int nSnake)
auto pSprite = &pActor->s();
int nAngle = pSprite->ang;
int nSector =pSprite->sectnum;
auto pSector =pSprite->sector();
int esi = 2048;
DExhumedActor* pEnemy = nullptr;
ExhumedSectIterator it(nSector);
ExhumedSectIterator it(pSector);
while (auto pAct2 = it.Next())
{
auto pSpr2 = &pAct2->s();