+1 vote

Well, I'm testing Godot 3.0 Alpha1 and noticed that the method "is_colliding()" is gone for good from KinematicBody2D.

Is there any way to check this collision?

I've already tried the following (new) methods:

"getcollisioncount()" (expecting it would return me a number bigger than 0)

In advance, thank you!

in Engine by (13 points)

I also need to know if this is valid:

Dictionary move ( Vector2 rel_vec )
Move the body in the given direction, stopping if there is an obstacle. If as a result of a movement there will be any collision then informations about this collision will be in returned dictionary. Dictionary will contains those keys:

“position” - collision position
“normal” - collision normal
“local_shape” - id of this kinematic body shape that took part in a collision
“travel” - traveled movement before being stopped
“remainder” - remaining movement before being stopped
“collider_id” - id of the collider, it can be used when dealing with Physics2DServer
“collider” - colliding body
“collider_shape_index” - index of the colliding shape, inside collider body “collider_metadata”

It seems that on the Alpha the Normal returned, which I expected to be the collision normal is not correct....

Yes, there is a bug on the return values on the alpha, should be solved by now, you can try to compile from master or get a more recent build.

Please log in or register to answer this question.

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 Frequently asked questions and 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.