From 5c419938f772a441b5b83cb7ccdd73d056cb2dfa Mon Sep 17 00:00:00 2001 From: Wojciech Madry Date: Fri, 18 Aug 2023 22:40:22 +0200 Subject: [PATCH] Fix next three ball render without textures Signed-off-by: Wojciech Madry --- src/function/drawer/drawer_window.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/function/drawer/drawer_window.cpp b/src/function/drawer/drawer_window.cpp index f3823fa..99c0c3c 100644 --- a/src/function/drawer/drawer_window.cpp +++ b/src/function/drawer/drawer_window.cpp @@ -42,10 +42,9 @@ void draw_window(sf::RenderWindow &window, map &Map, WhiteBox.setPosition(pos); // Draw whitebox around ball. window.draw(WhiteBox); - auto ballID = - static_cast(static_cast( - ResourceType::BALL_CIRCLE_START) + - NextEnum.first()); + auto ballID = static_cast( + static_cast(ResourceType::BALL_CIRCLE_START) + + static_cast(NextEnum.second().enum_color())); auto &Ball = Resource.get_as(ballID); // No textured ball auto radius = wb / 2.0f - Ball.getRadius();