From 51c035efffb4a986c0203cd88e544b30ec1b7110 Mon Sep 17 00:00:00 2001 From: "y.b.l**" Date: Sat, 18 Feb 2023 10:16:48 +0800 Subject: [PATCH] Update events.md --- source/documentation/events.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/source/documentation/events.md b/source/documentation/events.md index 54361e1..76e6c9e 100644 --- a/source/documentation/events.md +++ b/source/documentation/events.md @@ -44,7 +44,7 @@ When you trigger the event, a single paramter can be passed as the second argume ``` // Assume that color is an object square.bind("ChangeColor", function(color) { - this.color(color.r, color,g, color.b); + this.color(color.r, color.g, color.b); }) // Specify the RGB values corresponding to pink @@ -130,4 +130,4 @@ In such a globally bound function, the context will be the global Crafty object `Crafty.unbind()` and `Crafty.one()` also exist, and act exactly as you'd expect! -One particularly important built-in global event is "UpdateFrame". You can read more about it in the section on Crafty's [game loop](/documentation/gameloop.html) \ No newline at end of file +One particularly important built-in global event is "UpdateFrame". You can read more about it in the section on Crafty's [game loop](/documentation/gameloop.html)