0 votes

Hey guys,

I want to move between cells/waypoints/coordinates on a grid or path:


The player starts on the red point and with just one Input: Input.isactionpressed("ui_right") he automatically goes along the blue points to the next red point and stops. Input"down", he goes downwards and stops on the next, "up" or "right" to the next one and back and so on...

Do I have to use pathfinding with AStar?

Or an Array? like: [0,1,2]
0 = Obsticle
1 = stoppingcell
2 = walkingcell

Start at 1 and get next point 1...
0-0-0-0-0-0-2-0 and so on....

Do you have any ideas or examples, a link or any description?

Thank you so much :)

in Engine by (20 points)

Please log in or register to answer this question.

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 Frequently asked questions and How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to [email protected] with your username.