- handle 3 more of Exhumed's picnums that were quick to refactor

This commit is contained in:
Christoph Oelckers 2023-01-02 20:03:02 +01:00
parent 0e097903c4
commit 44e9a66319
2 changed files with 3 additions and 3 deletions

View file

@ -815,7 +815,7 @@ static void doPickupHealth(Player* pPlayer, DExhumedActor* pPickupActor, int nIt
if (nItem == 12)
{
pPickupActor->spr.hitag = 0;
pPickupActor->spr.picnum++;
pPickupActor->spr.setspritetexture(pPickupActor->spr.spritetexture() + 1);
ChangeActorStat(pPickupActor, 0);
}
else
@ -2051,7 +2051,7 @@ void AIPlayer::Tick(RunListEvent* ev)
const auto pPlayerActor = pPlayer->pActor;
pPlayerActor->spr.setspritetexture(getSequence(pPlayerActor->nSeqFile, PlayerSeq[nHeightTemplate[pPlayerActor->nAction]].nSeqId)->getFirstFrameTexture());
pPlayer->pDoppleSprite->spr.picnum = pPlayerActor->spr.picnum;
pPlayer->pDoppleSprite->spr.setspritetexture(pPlayerActor->spr.spritetexture());
doPlayerCounters(pPlayer);
doPlayerGravity(pPlayerActor);

View file

@ -149,7 +149,7 @@ DExhumedActor* FindFood(DExhumedActor* pActor)
DExhumedActor* pActor2 = nBodySprite[RandomSize(7) % nBodyTotal];
if (pActor2 != nullptr)
{
if (legacyTileNum(nPlayerPic) == pActor2->spr.picnum)
if (nPlayerPic == pActor2->spr.spritetexture())
{
if (cansee(pActor->spr.pos, pSector, pActor2->spr.pos, pActor2->sector())) {
return pActor2;