Add player check to valid_player

This commit is contained in:
8dcc 2023-07-24 17:33:27 +02:00
parent f3046d6ac8
commit a87b30dc40
1 changed files with 1 additions and 1 deletions

View File

@ -26,7 +26,7 @@ bool is_alive(cl_entity_t* ent) {
}
bool valid_player(cl_entity_t* ent) {
return ent && ent->index != localplayer->index &&
return ent && ent->player && ent->index != localplayer->index &&
ent->curstate.messagenum >= localplayer->curstate.messagenum;
}