test/snake/snake.c

changeset 116
bfb2a7d62047
parent 114
5b91bbab1ac0
--- a/test/snake/snake.c	Sat May 10 18:51:45 2025 +0200
+++ b/test/snake/snake.c	Sun May 11 14:51:00 2025 +0200
@@ -72,8 +72,7 @@
     if (asc_test_flag(node->flags, ASC_SCENE_NODE_GRAPHICS_UPDATED)
         || asc_active_window->resized) {
         asc_vec2u bottom_right = asc_active_window->dimensions;
-        // TODO: replace scale with asc_text_get_size()
-        asc_vec3f text_size = node->scale;
+        asc_vec2u text_size = ((AscText*)node)->dimension;
         asc_set_position2d(
                 node,
                 (int)bottom_right.x - (int)text_size.width - 10,

mercurial