From fb4e1d2d02176b5d1ba5dc526ca34dabdf2dd5d1 Mon Sep 17 00:00:00 2001 From: Marcel Admiraal Date: Sat, 16 Jul 2022 15:52:09 +0100 Subject: [PATCH 1/2] Set initial SceneTree processes times to 0.0 --- scene/main/scene_tree.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/scene/main/scene_tree.cpp b/scene/main/scene_tree.cpp index 3f3794600d3..8a0240069b9 100644 --- a/scene/main/scene_tree.cpp +++ b/scene/main/scene_tree.cpp @@ -2168,8 +2168,8 @@ SceneTree::SceneTree() { GLOBAL_DEF("debug/shapes/collision/draw_2d_outlines", true); tree_version = 1; - physics_process_time = 1; - idle_process_time = 1; + physics_process_time = 0.f; + idle_process_time = 0.f; root = nullptr; input_handled = false; From 162cb5748a9d3877275c6175db1869016fea55bb Mon Sep 17 00:00:00 2001 From: Marcel Admiraal Date: Sat, 16 Jul 2022 15:50:27 +0100 Subject: [PATCH 2/2] Update camera position when updating camera limit --- scene/2d/camera_2d.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scene/2d/camera_2d.cpp b/scene/2d/camera_2d.cpp index f93b16da348..37cc96e82f9 100644 --- a/scene/2d/camera_2d.cpp +++ b/scene/2d/camera_2d.cpp @@ -437,7 +437,7 @@ void Camera2D::clear_current() { void Camera2D::set_limit(Margin p_margin, int p_limit) { ERR_FAIL_INDEX((int)p_margin, 4); limit[p_margin] = p_limit; - update(); + _update_scroll(); } int Camera2D::get_limit(Margin p_margin) const {