diff --git a/src/polyrenderer/scene/poly_sky.cpp b/src/polyrenderer/scene/poly_sky.cpp index 8c84901b86..82be3f2bc0 100644 --- a/src/polyrenderer/scene/poly_sky.cpp +++ b/src/polyrenderer/scene/poly_sky.cpp @@ -27,6 +27,7 @@ #include "poly_sky.h" #include "poly_portal.h" #include "r_sky.h" // for skyflatnum +#include "g_levellocals.h" PolySkyDome::PolySkyDome() { diff --git a/src/swrenderer/plane/r_skyplane.cpp b/src/swrenderer/plane/r_skyplane.cpp index 727a04e511..dd8c2ca044 100644 --- a/src/swrenderer/plane/r_skyplane.cpp +++ b/src/swrenderer/plane/r_skyplane.cpp @@ -41,6 +41,7 @@ #include "swrenderer/line/r_walldraw.h" #include "swrenderer/scene/r_portal.h" #include "swrenderer/r_memory.h" +#include "g_levellocals.h" CVAR(Bool, r_linearsky, false, CVAR_ARCHIVE | CVAR_GLOBALCONFIG); EXTERN_CVAR(Int, r_skymode) @@ -115,7 +116,7 @@ namespace swrenderer else { // MBF's linedef-controlled skies // Sky Linedef - const line_t *l = &lines[(pl->sky & ~PL_SKYFLAT) - 1]; + const line_t *l = &level.lines[(pl->sky & ~PL_SKYFLAT) - 1]; // Sky transferred from first sidedef const side_t *s = l->sidedef[0]; diff --git a/src/swrenderer/scene/r_bsp.cpp b/src/swrenderer/scene/r_bsp.cpp index 1e390b313b..3a910f01b1 100644 --- a/src/swrenderer/scene/r_bsp.cpp +++ b/src/swrenderer/scene/r_bsp.cpp @@ -54,6 +54,7 @@ #include "r_sky.h" #include "po_man.h" #include "r_data/colormaps.h" +#include "g_levellocals.h" EXTERN_CVAR(Bool, r_fullbrightignoresectorcolor); diff --git a/src/swrenderer/scene/r_things.cpp b/src/swrenderer/scene/r_things.cpp index 569e9be10b..af503244dc 100644 --- a/src/swrenderer/scene/r_things.cpp +++ b/src/swrenderer/scene/r_things.cpp @@ -67,6 +67,7 @@ #include "swrenderer/things/r_wallsprite.h" #include "swrenderer/things/r_sprite.h" #include "swrenderer/r_memory.h" +#include "g_levellocals.h" EXTERN_CVAR(Int, r_drawfuzz) EXTERN_CVAR(Bool, r_drawvoxels) diff --git a/src/swrenderer/things/r_playersprite.cpp b/src/swrenderer/things/r_playersprite.cpp index 3755236525..d37320c39b 100644 --- a/src/swrenderer/things/r_playersprite.cpp +++ b/src/swrenderer/things/r_playersprite.cpp @@ -54,6 +54,7 @@ #include "swrenderer/scene/r_portal.h" #include "swrenderer/things/r_sprite.h" #include "swrenderer/r_memory.h" +#include "g_levellocals.h" EXTERN_CVAR(Bool, st_scale) EXTERN_CVAR(Bool, r_drawplayersprites)