W
W
WOSNE2021-03-19 12:02:35
C++ / C#
WOSNE, 2021-03-19 12:02:35

How to move to different objects?

Hello everyone)
You need to move freely from point to point (small circles), depending on the direction of the arrows.

So that it moves to the nearest point in the direction and stops.

Tell me how this can be implemented, maybe someone has something similar, I can’t find it :(
Just a cry from the heart, help me, or go to the factory)

605465d39bb51861074163.png

Answer the question

In order to leave comments, you need to log in

2 answer(s)
F
freeExec, 2021-03-19
@WOSNE

You describe the graph, from point 1 you can get to point 2 through the top. From v.2 to the left v.3, to the right v.4 and so on.

W
WasTabon, 2021-03-19
@WasTabon

You just do horizontal and vertical movement, then for example you need to go down, you need to check by y whether the same point exists on the player’s y coordinates, if so, then run the movement script, and when it collides with a point (a tag for example) make the speed 0 I hope that I have clearly explained

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question