You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-04 12:00:25 +00:00
Move NavigationServer navmesh sync from main() to process()
Moves NavigationServer navmesh sync from main() to process().
This commit is contained in:
@@ -4602,13 +4602,6 @@ bool Main::iteration() {
|
|||||||
XRServer::get_singleton()->_process();
|
XRServer::get_singleton()->_process();
|
||||||
#endif // XR_DISABLED
|
#endif // XR_DISABLED
|
||||||
|
|
||||||
#ifndef NAVIGATION_2D_DISABLED
|
|
||||||
NavigationServer2D::get_singleton()->sync();
|
|
||||||
#endif // NAVIGATION_2D_DISABLED
|
|
||||||
#ifndef NAVIGATION_3D_DISABLED
|
|
||||||
NavigationServer3D::get_singleton()->sync();
|
|
||||||
#endif // NAVIGATION_3D_DISABLED
|
|
||||||
|
|
||||||
for (int iters = 0; iters < advance.physics_steps; ++iters) {
|
for (int iters = 0; iters < advance.physics_steps; ++iters) {
|
||||||
if (Input::get_singleton()->is_agile_input_event_flushing()) {
|
if (Input::get_singleton()->is_agile_input_event_flushing()) {
|
||||||
Input::get_singleton()->flush_buffered_events();
|
Input::get_singleton()->flush_buffered_events();
|
||||||
|
|||||||
@@ -1262,6 +1262,8 @@ void GodotNavigationServer2D::process(double p_delta_time) {
|
|||||||
// Will run reliably every rendered frame independent of the physics tick rate.
|
// Will run reliably every rendered frame independent of the physics tick rate.
|
||||||
// Use for things that (only) need to update once per main loop iteration and rendered frame or is visible to the user.
|
// Use for things that (only) need to update once per main loop iteration and rendered frame or is visible to the user.
|
||||||
// E.g. (final) sync of objects for this main loop iteration, updating rendered debug visuals, updating debug statistics, ...
|
// E.g. (final) sync of objects for this main loop iteration, updating rendered debug visuals, updating debug statistics, ...
|
||||||
|
|
||||||
|
sync();
|
||||||
}
|
}
|
||||||
|
|
||||||
void GodotNavigationServer2D::physics_process(double p_delta_time) {
|
void GodotNavigationServer2D::physics_process(double p_delta_time) {
|
||||||
|
|||||||
@@ -1343,6 +1343,8 @@ void GodotNavigationServer3D::process(double p_delta_time) {
|
|||||||
// Will run reliably every rendered frame independent of the physics tick rate.
|
// Will run reliably every rendered frame independent of the physics tick rate.
|
||||||
// Use for things that (only) need to update once per main loop iteration and rendered frame or is visible to the user.
|
// Use for things that (only) need to update once per main loop iteration and rendered frame or is visible to the user.
|
||||||
// E.g. (final) sync of objects for this main loop iteration, updating rendered debug visuals, updating debug statistics, ...
|
// E.g. (final) sync of objects for this main loop iteration, updating rendered debug visuals, updating debug statistics, ...
|
||||||
|
|
||||||
|
sync();
|
||||||
}
|
}
|
||||||
|
|
||||||
void GodotNavigationServer3D::physics_process(double p_delta_time) {
|
void GodotNavigationServer3D::physics_process(double p_delta_time) {
|
||||||
|
|||||||
Reference in New Issue
Block a user