mirror of
https://github.com/openmoh/openmohaa.git
synced 2025-04-28 13:47:58 +03:00
Check for valid player 0 before setting subtitle
This commit is contained in:
parent
5f236d4d42
commit
1f3661238a
1 changed files with 1 additions and 1 deletions
|
@ -3693,7 +3693,7 @@ void Entity::Sound(
|
|||
if ((!checkSubtitle || g_subtitle->integer) && ret->subtitle) {
|
||||
Entity *p = G_GetEntity(0);
|
||||
|
||||
if (g_subtitle->integer == 2 || Square(max_dist) > DistanceSquared(org, p->edict->s.origin)) {
|
||||
if (p && (g_subtitle->integer == 2 || Square(max_dist) > DistanceSquared(org, p->edict->s.origin))) {
|
||||
cvar_t *curSubtitle = gi.Cvar_Get("curSubtitle", "0", 0);
|
||||
int curSub;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue