From c6991add46ed487cd878b2f825a43dc31f0aeec5 Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Tue, 11 May 2021 00:02:01 +0200 Subject: [PATCH] - Blood: fixed null pointer crash in actBurnSprite. --- source/games/blood/src/bloodactor.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/games/blood/src/bloodactor.h b/source/games/blood/src/bloodactor.h index 4947650ea..d98d4951e 100644 --- a/source/games/blood/src/bloodactor.h +++ b/source/games/blood/src/bloodactor.h @@ -142,7 +142,7 @@ inline void actBurnSprite(DBloodActor* pSource, DBloodActor* pTarget, int nTime) { auto pXSprite = &pTarget->x(); pXSprite->burnTime = ClipHigh(pXSprite->burnTime + nTime, sprite[pXSprite->reference].statnum == kStatDude ? 2400 : 1200); - pXSprite->burnSource = pSource->s().index; + pXSprite->burnSource = pSource? pSource->s().index : -1; } inline void GetActorExtents(DBloodActor* actor, int* top, int* bottom)