Why I am not able to create segmented line in godot 4.2.1?

Godot 4.2.1

I am new in godot , and I am using godot 4.2.1 version, so I want to create segmented line like bubble shooter game, but I did not find any resources about it, I ask before but I did not get the answers unfortunately, my purpose segmented line here:

I want to create doted line like it, is possible in godot, I was ask before, ans someone recommended RayCast2D but I did not understand how I will do it, please recommend me, any suggestion will be appreciated.

you could have stayed in the previous thread rather than starting a new one about the same thing. if you don’t understand something, there is no shame in asking again and again. but it’s better to collect the advice that users give you in one of your own threads, where you can go back and have it in one place until you understand it completely.

1 Like

You can to use Line2D

and you can segment it as needed

and the raycast is needed to know where to segment Line2D in a collision and at what angle to proceed, etc.

so first you process everything via RayCast and then you apply it with known values to Line2D

tnx so much for your answer, how can I create scene tree structure, I will handle RayCast2D and Line2D at the same time, do you have any suggestion about it.

Very quickly I created a demonstration for you, it is not very usable but for a start maybe good for understanding.

It is only applicable to vertical collisions. Golf is not going to be it :thinking: … no, no way :slightly_smiling_face:

… to be continue( attach compress file not alowed, it’s logical) I’ll break it down in the next post :godot:


waw amazing can you share codes here, appreciated.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.