mirror of
https://github.com/Relintai/pandemonium_engine.git
synced 2024-12-22 11:56:49 +01:00
Fix threaded bake logic in NavigationPolygonInstance and NavigationMeshInstance.
This commit is contained in:
parent
62e2b1623a
commit
2c3c7dcc73
@ -320,7 +320,7 @@ void NavigationPolygonInstance::bake_navigation_polygon(bool p_on_thread) {
|
||||
baking_started = true;
|
||||
|
||||
navpoly->clear();
|
||||
if (p_on_thread) { // && OS::get_singleton()->get_render_thread_mode() == OS::RenderThreadMode::RENDER_SEPARATE_THREAD
|
||||
if (p_on_thread && OS::get_singleton()->can_use_threads()) {
|
||||
Ref<FuncRef> f;
|
||||
f.instance();
|
||||
f->set_instance(this);
|
||||
|
@ -291,7 +291,7 @@ void NavigationMeshInstance::bake_navigation_mesh(bool p_on_thread) {
|
||||
|
||||
navmesh->clear();
|
||||
|
||||
if (p_on_thread && OS::get_singleton()->get_render_thread_mode() == OS::RenderThreadMode::RENDER_SEPARATE_THREAD) {
|
||||
if (p_on_thread && OS::get_singleton()->can_use_threads()) {
|
||||
Ref<FuncRef> f;
|
||||
f.instance();
|
||||
f->set_instance(this);
|
||||
|
Loading…
Reference in New Issue
Block a user