diff --git a/examples_dd3d/DebugDrawDemoScene.tscn b/examples_dd3d/DebugDrawDemoScene.tscn index e807e992..bcf73c6c 100644 --- a/examples_dd3d/DebugDrawDemoScene.tscn +++ b/examples_dd3d/DebugDrawDemoScene.tscn @@ -374,7 +374,6 @@ func _on_Button_pressed() -> void: process_priority = 1 script = ExtResource("1") custom_font = ExtResource("2_aedbq") -update_in_physics = true draw_array_of_boxes = true text_groups_show_stats = true text_groups_position = 2 diff --git a/src/3d/render_instances.cpp b/src/3d/render_instances.cpp index 4b8503d6..6b8b4856 100644 --- a/src/3d/render_instances.cpp +++ b/src/3d/render_instances.cpp @@ -166,6 +166,13 @@ PackedFloat32Array GeometryPool::get_raw_data(InstanceType _type, temp_raw_buffe } } } + } else { + // Force reset stats + for (auto &proc : pools) { + auto &inst = proc.instances[(int)_type]; + inst._prev_used_instant = inst.used_instant; + inst.used_delayed = 0; + } } return buffer.slice(0, last_added * INSTANCE_DATA_FLOAT_COUNT);