From 6c619af9ce5d177123ec5a1d7c3ac8127c0231ea Mon Sep 17 00:00:00 2001 From: Monster Iestyn Date: Wed, 26 Apr 2017 17:12:57 +0100 Subject: [PATCH] Use the skybox mobj's actual z position, rather than using the spawnpoint angle! This means setting the skybox view angle is no longer stupid, objectplace no longer breaks skyboxes, and Lua-defined skybox mobjs can actually set a Z position more easily now. --- src/p_mobj.c | 1 - src/r_main.c | 4 +--- 2 files changed, 1 insertion(+), 4 deletions(-) diff --git a/src/p_mobj.c b/src/p_mobj.c index 17d5d13b3..6b2d1af30 100644 --- a/src/p_mobj.c +++ b/src/p_mobj.c @@ -9717,7 +9717,6 @@ void P_SpawnMapThing(mapthing_t *mthing) switch(mobj->type) { case MT_SKYBOX: - mobj->angle = 0; if (mthing->options & MTF_OBJECTSPECIAL) skyboxmo[1] = mobj; else diff --git a/src/r_main.c b/src/r_main.c index f03af9963..c998a7d93 100644 --- a/src/r_main.c +++ b/src/r_main.c @@ -798,9 +798,7 @@ void R_SkyboxFrame(player_t *player) viewx = viewmobj->x; viewy = viewmobj->y; - viewz = 0; - if (viewmobj->spawnpoint) - viewz = ((fixed_t)viewmobj->spawnpoint->angle)<z; // 26/04/17: use actual Z position instead of spawnpoint angle! if (mapheaderinfo[gamemap-1]) {