mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-03-22 02:42:20 +00:00
Merge branch 'fix-exitgame-ztarget-crash' into 'next'
Fix lock-on crash (Resolves #746) Closes #746 See merge request STJr/SRB2!1704
This commit is contained in:
commit
9c5427555b
1 changed files with 1 additions and 1 deletions
|
@ -1411,7 +1411,7 @@ void G_BuildTiccmd(ticcmd_t *cmd, INT32 realtics, UINT8 ssplayer)
|
|||
newtarget = P_SpawnMobj(ticcmd_ztargetfocus[forplayer]->x, ticcmd_ztargetfocus[forplayer]->y, ticcmd_ztargetfocus[forplayer]->z, MT_LOCKON); // positioning, flip handled in P_SceneryThinker
|
||||
P_SetTarget(&newtarget->target, ticcmd_ztargetfocus[forplayer]);
|
||||
|
||||
if (P_AproxDistance(
|
||||
if (player->mo && P_AproxDistance(
|
||||
player->mo->x - ticcmd_ztargetfocus[forplayer]->x,
|
||||
player->mo->y - ticcmd_ztargetfocus[forplayer]->y
|
||||
) > 50*player->mo->scale)
|
||||
|
|
Loading…
Reference in a new issue