Merge pull request #26830 from KidRigger/physics_fps_bug

Fixes physic_fps=0 bug that prevented quit.
This commit is contained in:
Rémi Verschelde 2019-04-05 16:56:29 +02:00 committed by GitHub
commit 03bd93e3b3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -1882,7 +1882,9 @@ bool Main::iteration() {
uint64_t idle_begin = OS::get_singleton()->get_ticks_usec();
OS::get_singleton()->get_main_loop()->idle(step * time_scale);
if (OS::get_singleton()->get_main_loop()->idle(step * time_scale)) {
exit = true;
}
message_queue->flush();
VisualServer::get_singleton()->sync(); //sync if still drawing from previous frames.