diff --git a/game/graphics.cc b/game/graphics.cc index 09135cf..12fedfd 100644 --- a/game/graphics.cc +++ b/game/graphics.cc @@ -352,9 +352,10 @@ void Graphics::render(double time) for(unsigned int i = 0; i std::get<1>(renderQueue.at(j)) && ! enqueued){ + if (shadowRenderQueue.at(i).currentPriority > std::get<1>(renderQueue.at(j))){ renderQueue.at(j) = std::make_tuple(shadowRenderQueue.at(i).light, shadowRenderQueue.at(i).currentPriority, i); enqueued = true; + break; } } if (enqueued) {