public void BuildObjects(GameObject springBoneRoot, GameObject colliderRoot, IEnumerable <string> requiredBones) { DestroyOldSpringBones(springBoneRoot); if (requiredBones != null) { FilterBoneRecordsByRequiredBonesAndCreateUnrecordedBones(springBoneRoot, requiredBones); } var initialTransforms = GameObjectUtil.BuildNameToComponentMap <Transform>(springBoneRoot, true); foreach (var record in pivotRecords) { SetupPivotFromSerializer(initialTransforms, record); } var setupMaps = SpringBoneSetupMaps.Build(springBoneRoot, colliderRoot); foreach (var record in springBoneRecords) { SetupSpringBoneFromSerializer(setupMaps, record); } var springManager = GameObjectUtil.AcquireComponent <SpringManager>(springBoneRoot, true); SpringBoneSetup.FindAndAssignSpringBones(springManager); }