- corrected the NUL checks in S_FindSkinnedSound.

This commit is contained in:
Christoph Oelckers 2021-06-04 07:57:05 +02:00
parent 7d1ce1c8cd
commit 8b5847d4a2
1 changed files with 3 additions and 3 deletions

View File

@ -1636,10 +1636,10 @@ int S_FindSkinnedSound (AActor *actor, FSoundID refid)
const char *pclass;
int gender = 0;
if (actor != nullptr)
if (actor != nullptr && actor->player != nullptr)
{
if (actor->player != nullptr) pclass = S_GetSoundClass(actor);
if (actor->player != nullptr) gender = actor->player->userinfo.GetGender();
pclass = S_GetSoundClass(actor);
gender = actor->player->userinfo.GetGender();
}
else
{