Camera crash fixes
UNRELATED, but they made this branch a pain in the ass to test so I needed to fix this here :V
This commit is contained in:
parent
b83286b532
commit
9630e01616
|
@ -4033,6 +4033,7 @@ static void M_ForceLoadGameResponse(INT32 ch)
|
||||||
displayplayer = consoleplayer;
|
displayplayer = consoleplayer;
|
||||||
multiplayer = false;
|
multiplayer = false;
|
||||||
splitscreen = 0;
|
splitscreen = 0;
|
||||||
|
SplitScreen_OnChange(); // not needed?
|
||||||
|
|
||||||
if (setsizeneeded)
|
if (setsizeneeded)
|
||||||
R_ExecuteSetViewSize();
|
R_ExecuteSetViewSize();
|
||||||
|
@ -4122,6 +4123,7 @@ void G_LoadGame(UINT32 slot, INT16 mapoverride)
|
||||||
displayplayer = consoleplayer;
|
displayplayer = consoleplayer;
|
||||||
multiplayer = false;
|
multiplayer = false;
|
||||||
splitscreen = 0;
|
splitscreen = 0;
|
||||||
|
SplitScreen_OnChange(); // not needed?
|
||||||
|
|
||||||
// G_DeferedInitNew(sk_medium, G_BuildMapName(1), 0, 0, 1);
|
// G_DeferedInitNew(sk_medium, G_BuildMapName(1), 0, 0, 1);
|
||||||
if (setsizeneeded)
|
if (setsizeneeded)
|
||||||
|
|
|
@ -3654,6 +3654,11 @@ boolean P_CameraThinker(player_t *player, camera_t *thiscam, boolean resetcalled
|
||||||
{
|
{
|
||||||
boolean itsatwodlevel = false;
|
boolean itsatwodlevel = false;
|
||||||
postimg_t postimg = postimg_none;
|
postimg_t postimg = postimg_none;
|
||||||
|
|
||||||
|
// This can happen when joining
|
||||||
|
if (thiscam->subsector == NULL || thiscam->subsector->sector == NULL)
|
||||||
|
return true;
|
||||||
|
|
||||||
if (twodlevel
|
if (twodlevel
|
||||||
|| (thiscam == &camera && players[displayplayer].mo && (players[displayplayer].mo->flags2 & MF2_TWOD))
|
|| (thiscam == &camera && players[displayplayer].mo && (players[displayplayer].mo->flags2 & MF2_TWOD))
|
||||||
|| (thiscam == &camera2 && players[secondarydisplayplayer].mo && (players[secondarydisplayplayer].mo->flags2 & MF2_TWOD))
|
|| (thiscam == &camera2 && players[secondarydisplayplayer].mo && (players[secondarydisplayplayer].mo->flags2 & MF2_TWOD))
|
||||||
|
|
|
@ -8083,6 +8083,10 @@ boolean P_MoveChaseCamera(player_t *player, camera_t *thiscam, boolean resetcall
|
||||||
if (!player || !player->mo)
|
if (!player || !player->mo)
|
||||||
return true;
|
return true;
|
||||||
|
|
||||||
|
// This can happen when joining
|
||||||
|
if (thiscam->subsector == NULL || thiscam->subsector->sector == NULL)
|
||||||
|
return true;
|
||||||
|
|
||||||
mo = player->mo;
|
mo = player->mo;
|
||||||
|
|
||||||
#ifndef NOCLIPCAM
|
#ifndef NOCLIPCAM
|
||||||
|
|
Loading…
Reference in New Issue