From 81f042f08bc0fc818c4bef819aeec0af7559a2d6 Mon Sep 17 00:00:00 2001 From: "alexey.lysiuk" Date: Sat, 2 Jun 2018 09:43:33 +0300 Subject: [PATCH] - fixed compilation with Clang and GCC src/gl/scene/gl_flats.cpp:215:3: error: cannot jump from this goto statement to its label src/r_data/models/models.cpp:100:18: error: no member named 'floor' in namespace 'std' --- src/gl/scene/gl_flats.cpp | 2 +- src/r_data/models/models.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gl/scene/gl_flats.cpp b/src/gl/scene/gl_flats.cpp index e9a3314e0..63c4f9a01 100644 --- a/src/gl/scene/gl_flats.cpp +++ b/src/gl/scene/gl_flats.cpp @@ -207,6 +207,7 @@ void FDrawInfo::ProcessLights(GLFlat *flat, bool istrans) void FDrawInfo::DrawSubsectors(GLFlat *flat, int pass, bool processlights, bool istrans) { int dli = flat->dynlightindex; + auto vcount = flat->sector->ibocount; gl_RenderState.Apply(); if (gl.legacyMode) @@ -215,7 +216,6 @@ void FDrawInfo::DrawSubsectors(GLFlat *flat, int pass, bool processlights, bool goto legacy; } - auto vcount = flat->sector->ibocount; if (vcount > 0 && !gl_RenderState.GetClipLineShouldBeActive()) { if (processlights) SetupSectorLights(flat, GLPASS_ALL, &dli); diff --git a/src/r_data/models/models.cpp b/src/r_data/models/models.cpp index ca7b02ad3..b8b324524 100644 --- a/src/r_data/models/models.cpp +++ b/src/r_data/models/models.cpp @@ -97,7 +97,7 @@ void FModelRenderer::RenderModel(float x, float y, float z, FSpriteModelFrame *s if (smf->rotationSpeed > 0.0000000001) { double turns = (I_GetTime() + I_GetTimeFrac()) / (200.0 / smf->rotationSpeed); - turns -= std::floor(turns); + turns -= floor(turns); rotateOffset = turns * 360.0; } else