remove test behavior for score counter

Sun, 06 Jul 2025 18:45:47 +0200

author
Mike Becker <universe@uap-core.de>
date
Sun, 06 Jul 2025 18:45:47 +0200
changeset 183
48fbd9e497f2
parent 182
264dfe1928b2
child 184
fe735cd266f3

remove test behavior for score counter

test/snake/snake.c file | annotate | diff | comparison | revisions
--- a/test/snake/snake.c	Sat Jul 05 23:11:36 2025 +0200
+++ b/test/snake/snake.c	Sun Jul 06 18:45:47 2025 +0200
@@ -105,16 +105,6 @@
     asc_ui_add_node(node);
 }
 
-static void update_score_counter(AscBehavior *behavior) {
-    AscSceneNode *node = behavior->node;
-    static unsigned test_score = 0;
-    test_score += 100;
-    asc_text_printf(node, "Score: %u", test_score);
-    if (test_score > 9000) {
-        asc_behavior_remove(behavior);
-    }
-}
-
 static void create_score_counter(void) {
     asc_font(ASC_FONT_BOLD, 16);
     asc_ink_rgb(0, 255, 0);
@@ -123,8 +113,6 @@
         .x = 10, .y = 10,
         .text = "Score: 0"
     );
-    // TODO: remove this test behavior
-    asc_behavior_add(node, .func = update_score_counter, .interval = asc_milliseconds(250));
     asc_ui_add_node(node);
 }
 

mercurial