summaryrefslogtreecommitdiff
path: root/doc/classes/CharacterBody2D.xml
diff options
context:
space:
mode:
authorconstantitus <constantitus@gmail.com>2023-02-13 23:14:48 +0200
committerconstantitus <constantitus@gmail.com>2023-02-13 23:14:48 +0200
commit69515742657cfc58a2de5a78eee6920dd4f3489b (patch)
treec20acdc30fa2e809e6ee11c74faa81d349143c8e /doc/classes/CharacterBody2D.xml
parent853c36ca0b6a4b8982215115b1fb1b62b58f2d98 (diff)
fixed c# example in CharacterBody2D doc
Diffstat (limited to 'doc/classes/CharacterBody2D.xml')
-rw-r--r--doc/classes/CharacterBody2D.xml4
1 files changed, 2 insertions, 2 deletions
diff --git a/doc/classes/CharacterBody2D.xml b/doc/classes/CharacterBody2D.xml
index 7395556d05..51cc752cae 100644
--- a/doc/classes/CharacterBody2D.xml
+++ b/doc/classes/CharacterBody2D.xml
@@ -71,10 +71,10 @@
print("Collided with: ", collision.collider.name)
[/gdscript]
[csharp]
- for (int i = 0; i &lt; GetSlideCount(); i++)
+ for (int i = 0; i &lt; GetSlideCollisionCount(); i++)
{
KinematicCollision2D collision = GetSlideCollision(i);
- GD.Print("Collided with: ", (collision.Collider as Node).Name);
+ GD.Print("Collided with: ", (collision.GetCollider() as Node).Name);
}
[/csharp]
[/codeblocks]