From 171447b4928136265bca86b1ab4f07831330a6f9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alf-Andr=C3=A9=20Walla?= Date: Fri, 13 Sep 2024 20:42:07 +0200 Subject: [PATCH] Update README --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 089fe797..5cf63211 100644 --- a/README.md +++ b/README.md @@ -63,12 +63,12 @@ static void add_coin(const Node& player) { + std::to_string(coins) + ((coins == 1) ? " coin" : " coins")); } -extern "C" Variant _on_body_entered(Node player) { - if (player.get_name() != "Player") { +extern "C" Variant _on_body_entered(Node2D node) { + if (node.get_name() != "Player") return {}; - } + get_node().queue_free(); // Remove the current coin! - add_coin(player); + add_coin(node); return {}; } ```