The Godot Q&A is currently undergoing maintenance!

Your ability to ask and answer questions is temporarily disabled. You can browse existing threads in read-only mode.

We are working on bringing this community platform back to its full functionality, stay tuned for updates.

godotengine.org | Twitter

0 votes

Hello, i'm making a game in which I use the NavigationPolygonInstance.
In my game I make obstacles by code, and it works well, but when I use the line of code:

    get_tree().reload_current_scene()

it seems like the last NavigationPolygonInstance it isn't restarted and saves the last shape, after making the obstacles and throw this error:

E 0:00:04:0071 NavigationPolygon: Convex partition failed!
scene/2d/navigationpolygon.cpp:260 @ makepolygonsfromoutlines()
Navigation2D.gd:56 @ obstacle()
CajaDeRecursos.gd:32 @ make
obstacle()
mainScript.gd:33 @ _ready()
First image before reloading

Second image after reloading

I don't have this error if I go to another scene and then I return to this.
Here is the project:Link with project
PD: the project is very spanglish

in Engine by (16 points)

1 Answer

0 votes

I finally found a way but it doesn't solve the problem.
I use a transition scene, so when I wan't to reload my scene I go first to that scene and then I charge my main scene.

by (16 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 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.