0 votes

I'm trying some things and looking at tutorials to help me to get through some problems but there's lots of functions that doesn't exist anymore in Godot 3.0 like getcollider, getcollision_pos, etc. I tried to go for the documentation but it didn't helped me that much.

in Engine by (53 points)

2 Answers

+1 vote
Best answer

Official documentation:
though it changes from move_and_collide to move_and_slide without explanation

The api reference (is your best friend):

And the demos, kinematic character and Platformer demos use KinematicBody2D.

The main change is that move is now move_and_collide and returns a KinematicCollision2D object with collision data, and move_and_slide add methods to get the list of collisions while sliding (check the reference).

by (7,874 points)
selected by

Ooh really thanks! I completely forgot about the api reference. Also I'm gonna look for some demos.

+1 vote

I did what you did before. Believe me it's not going to help at all if you don't read the docs very carefully, although you don't feel like sometimes. move_and_collide returns a KinematicCollision2D object, which gives you the collider via KinematicCollision2D.collider and the position via KinematicCollision2D.position.

by (840 points)
Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.