Skip to content

Commit

Permalink
- fixed null pointer access in nnExtProcessSuperSprites
Browse files Browse the repository at this point in the history
  • Loading branch information
coelckers committed Sep 7, 2021
1 parent d5b26fc commit ce35142
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions source/games/blood/src/nnexts.cpp
Expand Up @@ -1380,9 +1380,9 @@ void nnExtProcessSuperSprites()
PLAYER* pPlayer = NULL;
for (int a = connecthead; a != -1; a = connectpoint2[a])
{
auto pact = pPlayer->actor;
pPlayer = &gPlayer[a];
if (pact->hit.hit.type == kHitSprite && pact->hit.hit.actor == debrisactor)
auto pact = pPlayer->actor;
if (pact->hit.hit.type == kHitSprite && pact->hit.hit.actor == debrisactor)
{
int nSpeed = approxDist(pact->xvel, pact->yvel);
nSpeed = ClipLow(nSpeed - MulScale(nSpeed, mass, 6), 0x9000 - (mass << 3));
Expand Down

0 comments on commit ce35142

Please sign in to comment.