mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2024-11-26 06:11:01 +00:00
Add a player->mo check before attempting to account for ztargetting.
This commit is contained in:
parent
2615528f45
commit
e0afc2d2b6
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