How does the dynamic of following the track work?

Hello, do you have any idea how the dynamic of following the path of the sphere that I left connected to works? Or is there a sample project about it?

Game Link: Game

Hi @Onur_Ozturk,

This project maybe a good starting point for adding paths and animating entities moving on them:

1 Like

Hello, thank you for your reply. In the game I want to make, I use 9 different parts when creating the track and add them end to end to create the road. How can I make the player follow the “path” objects on these paths that are added during runtime? More precisely, how do I get the player to go to the closest path point?

Given that your game has 9 different sections, each section would have a fixed path for the section so the ball can follow that path for that section (with an offset left/right for the gameplay).

For that, you could use the project linked by Leonidas as a base or use your own path/curve algorithm to define the (smooth) path.

The bit you would need to do is the connection between sections and could assume that the last point of the path for the previous section is the same as the first point of the new section.

1 Like

thank you. I will try