public void CreateNewIKAdjustList(vShooterManager targetShooterManager) { vWeaponIKAdjustList ikAdjust = ScriptableObject.CreateInstance <vWeaponIKAdjustList>(); AssetDatabase.CreateAsset(ikAdjust, "Assets/" + manager.gameObject.name + "@IKAdjustList.asset"); targetShooterManager.weaponIKAdjustList = ikAdjust; AssetDatabase.SaveAssets(); }
public void CreateNewIKAdjustList(vIShooterIKController targetShooterManager) { vWeaponIKAdjustList ikAdjust = ScriptableObject.CreateInstance <vWeaponIKAdjustList>(); AssetDatabase.CreateAsset(ikAdjust, "Assets/" + ikController.gameObject.name + "@IKAdjustList.asset"); targetShooterManager.WeaponIKAdjustList = ikAdjust; ikList = new SerializedObject(ikAdjust); ikList.ApplyModifiedProperties(); AssetDatabase.SaveAssets(); EditorUtility.SetDirty(ikList.targetObject); }