From bbc74a8cef7f0f76b4a41e0e0589f1e994ae88f8 Mon Sep 17 00:00:00 2001 From: Maximilian Giller Date: Wed, 24 May 2023 18:20:35 +0200 Subject: [PATCH] Fixed offset when rendering circles --- src/primitives/circle_object.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/primitives/circle_object.cpp b/src/primitives/circle_object.cpp index 8ba7bb1..99847c2 100644 --- a/src/primitives/circle_object.cpp +++ b/src/primitives/circle_object.cpp @@ -10,7 +10,7 @@ void CircleObject::draw(sf::RenderWindow *window) const { sf::CircleShape circle(radius); circle.setFillColor(color); - circle.setPosition(coordinates.isometric().x - radius / 2, coordinates.isometric().y - radius / 2); + circle.setPosition(coordinates.isometric().x - radius, coordinates.isometric().y - radius); window->draw(circle); }