test/snake.c

changeset 47
44457f6cb0a2
parent 46
d3285aed65b3
child 48
6e5b5ba2752c
--- a/test/snake.c	Fri Mar 29 00:03:25 2024 +0100
+++ b/test/snake.c	Mon Apr 01 18:54:19 2024 +0200
@@ -50,7 +50,7 @@
     asc_ink_rgb(255, 0, 0);
     AscSceneNode* node = asc_text(10, 10, "XXXXXXX FPS");
     asc_scene_add_behavior(node, update_fps_counter);
-    asc_scene_add(&asc_window_active->ui, node);
+    asc_scene_node_link(asc_window_active->ui, node);
 }
 
 static void update_score_counter(AscSceneNode *node) {
@@ -71,7 +71,7 @@
     asc_ink_rgb(0, 255, 0);
     AscSceneNode* node = asc_text(0, 0, "Score: 0");
     asc_scene_add_behavior(node, update_score_counter);
-    asc_scene_add(&asc_window_active->ui, node);
+    asc_scene_node_link(asc_window_active->ui, node);
 }
 
 int main(int argc, char** argv) {

mercurial