Cloth: Copy point cache settings when copying cloth modifier

This fixes the issue mentioned in the comment in T74515.

Reviewers: mont29

Differential Revision: https://developer.blender.org/D7104
This commit is contained in:
2020-03-11 13:43:15 +01:00
parent 5cb2861420
commit 6eeaecdd67

View File

@@ -179,7 +179,11 @@ static void copyData(const ModifierData *md, ModifierData *target, const int fla
}
else {
tclmd->point_cache = BKE_ptcache_add(&tclmd->ptcaches);
tclmd->point_cache->step = 1;
if (clmd->point_cache != NULL) {
tclmd->point_cache->step = clmd->point_cache->step;
tclmd->point_cache->startframe = clmd->point_cache->startframe;
tclmd->point_cache->endframe = clmd->point_cache->endframe;
}
}
tclmd->sim_parms = MEM_dupallocN(clmd->sim_parms);