diff --git a/src/rendering/gl/renderer/gl_renderer.cpp b/src/rendering/gl/renderer/gl_renderer.cpp index 49ea8b0f4..6b722ad71 100644 --- a/src/rendering/gl/renderer/gl_renderer.cpp +++ b/src/rendering/gl/renderer/gl_renderer.cpp @@ -256,7 +256,8 @@ sector_t *FGLRenderer::RenderView(player_t* player) NoInterpolateView = false; // Shader start time does not need to be handled per level. Just use the one from the camera to render from. - gl_RenderState.CheckTimer(player->camera->Level->ShaderStartTime); + if (player->camera) + gl_RenderState.CheckTimer(player->camera->Level->ShaderStartTime); // prepare all camera textures that have been used in the last frame. // This must be done for all levels, not just the primary one! for (auto Level : AllLevels()) diff --git a/src/rendering/vulkan/system/vk_framebuffer.cpp b/src/rendering/vulkan/system/vk_framebuffer.cpp index 96a8c1cd1..b49798f4a 100644 --- a/src/rendering/vulkan/system/vk_framebuffer.cpp +++ b/src/rendering/vulkan/system/vk_framebuffer.cpp @@ -404,7 +404,8 @@ sector_t *VulkanFrameBuffer::RenderView(player_t *player) NoInterpolateView = false; // Shader start time does not need to be handled per level. Just use the one from the camera to render from. - GetRenderState()->CheckTimer(player->camera->Level->ShaderStartTime); + if (player->camera) + GetRenderState()->CheckTimer(player->camera->Level->ShaderStartTime); // prepare all camera textures that have been used in the last frame. // This must be done for all levels, not just the primary one! for (auto Level : AllLevels())