diff --git a/servers/rendering/renderer_rd/storage_rd/light_storage.cpp b/servers/rendering/renderer_rd/storage_rd/light_storage.cpp index 1f6d1021f49..5f4bf6c8ed4 100644 --- a/servers/rendering/renderer_rd/storage_rd/light_storage.cpp +++ b/servers/rendering/renderer_rd/storage_rd/light_storage.cpp @@ -1669,6 +1669,8 @@ void LightStorage::update_reflection_probe_buffer(RenderDataRD *p_render_data, c for (uint32_t i = 0; i < reflection_count; i++) { ReflectionProbeInstance *rpi = reflection_sort[i].probe_instance; + rpi->last_pass = RSG::rasterizer->get_frame_number(); + if (using_forward_ids) { forward_id_storage->map_forward_id(FORWARD_ID_TYPE_REFLECTION_PROBE, rpi->forward_id, i, rpi->last_pass); } @@ -1717,8 +1719,6 @@ void LightStorage::update_reflection_probe_buffer(RenderDataRD *p_render_data, c // hook for subclass to do further processing. RendererSceneRenderRD::get_singleton()->setup_added_reflection_probe(transform, extents); - - rpi->last_pass = RSG::rasterizer->get_frame_number(); } if (reflection_count) {