0 votes

Hey all,

I mimicked the following drag and drop in 3D code available here godot-plugin-DragDrop3D and am getting the same freeze / sluggish movement of he original code
whenever I hit the edges ...

Is this behaviour expected ? It should be easy to reproduce using the original code.

If there is no workaround to this algorithm project_ray_origin , project_ray_normal , intersect_ray , can someone indicate a better one achieving the desired / smooth result ?

Tested on Ubuntu laptop + Android device : Same behaviour.

Thx

in Engine by (840 points)

1 Answer

0 votes
Best answer

For my code, I found the solution by putting the floor as layer collision 2 and the raycast collision mask to 2:

var cast = cam.get_world().direct_space_state.intersect_ray(from,to, [rigidBod], 2, true, false)

thus bypassing hickups on other rigid bodies.
It is now working very smoothly on my Android phone.

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.

Categories