0 votes

Hello, I'm doing a raycast and I want to change the color of the object that the raycast hits, how can I do that?

asked Jul 15 in Projects by Qushy (28 points)

1 Answer

0 votes
Best answer

Use get_collider() to get the node the ray has hit, then change it's color either by altering the albedo color or the material's texture.

answered Jul 15 by Magso (721 points)
selected Jul 16 by Qushy
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.