0 votes

I am trying to move an actor beyond the initial screen edge, which is not working out for me.

I have a camera that pans, so I am moving beyond the initial position of where the screen ended, but when I have my Nav2D calculate a path for the actor it stops at the original screen edge.

As an extra test I have also tried resizing the screen and then it DOES move a little bit further, but stops at the new edge.

Here is an output of one such a movement event:

Calculating path...
Position actor:
(2002.339355, 1037.109009)
Coordinates goal:
(3012.104004, 1003.308044)
Path:
[(2001.592407, 1037.110718), (2001.51416, 1005.836548)]" `

Code of this call in question:
path = nav.get_simple_path(get_position(), coordinates, false)

Is this something I can fix somehow?

Cheers! :)

in Engine by (25 points)

1 Answer

+1 vote
Best answer

Silly fix: it was simply the nav mesh not being larger than the screen. Unfortunate oversight, leaving it here for others to learn from my mistake if anyone ever ends up in the same situation :)

by (25 points)
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.
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 webmaster@godotengine.org with your username.