From 29dc4a85f7417fc29917023d672dff70512433e4 Mon Sep 17 00:00:00 2001 From: YimingWu Date: Tue, 14 May 2024 06:49:30 +0200 Subject: [PATCH] Fix #121766: Softbody ensure current position When reading a cached frame the unmodified goal positions are not synchronized along. Now fixed. Co-authored by @bjornmose Pull Request: https://projects.blender.org/blender/blender/pulls/121768 --- source/blender/blenkernel/intern/softbody.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/source/blender/blenkernel/intern/softbody.cc b/source/blender/blenkernel/intern/softbody.cc index b8b974ccc07..529948084f8 100644 --- a/source/blender/blenkernel/intern/softbody.cc +++ b/source/blender/blenkernel/intern/softbody.cc @@ -3600,6 +3600,8 @@ void sbObjectStep(Depsgraph *depsgraph, if (cache_result == PTCACHE_READ_EXACT || cache_result == PTCACHE_READ_INTERPOLATED || (!can_simulate && cache_result == PTCACHE_READ_OLD)) { + /* Keep goal positions in track. */ + softbody_update_positions(ob, sb, vertexCos, numVerts); softbody_to_object(ob, vertexCos, numVerts, sb->local); BKE_ptcache_validate(cache, framenr);