kidscancode / godot_recipes

Lessons, tutorials, and guides for game development using the Godot game engine.
MIT License
239 stars 37 forks source link

[Discussion] 3D Kinematic Car: Slopes & ramps #44

Open cbscribe opened 3 years ago

cbscribe commented 3 years ago

Discussion for http://godotrecipes.com/3d/kinematic_car/car_slopes/

rafadiniz commented 3 years ago

is_colliding() doesn't work in godot 3.3.2, what function can I use instead?

cbscribe commented 3 years ago

What do you mean "doesn't work"? Raycast functionality is no different in any 3.x version of Godot.

rafadiniz commented 3 years ago

I got this message: Invalid call. Nonexistent function 'is_colliding' in base 'CollisionShape'.

Sorry for my ignorance, I started studying Godot recently

cbscribe commented 3 years ago

is_colliding() is a method of RayCast, not of CollisionShape. You're apparently trying to call it on the wrong object.

rafadiniz commented 3 years ago

So RayCast doesn't have to be a CollisionShape node? I think that was my mistake.

cbscribe commented 3 years ago

Yes, RayCast is a node.