mirror of
				https://github.com/maxartz15/VertexAnimation.git
				synced 2025-10-30 16:25:42 +01:00 
			
		
		
		
	ApplyAnimationBounds option.
This commit is contained in:
		| @@ -37,6 +37,7 @@ namespace TAO.VertexAnimation.Editor | ||||
| 		private void BakeGUI() | ||||
| 		{ | ||||
| 			EditorGUILayout.PropertyField(serializedObject.FindProperty("lodSettings").FindPropertyRelative("lodSettings")); | ||||
| 			EditorGUILayout.PropertyField(serializedObject.FindProperty("applyAnimationBounds")); | ||||
| 			EditorGUILayout.PropertyField(serializedObject.FindProperty("generateAnimationBook")); | ||||
|  | ||||
| 			using (new EditorGUILayout.HorizontalScope()) | ||||
|   | ||||
| @@ -18,6 +18,7 @@ namespace TAO.VertexAnimation.Editor | ||||
| 		public bool includeInactive = false; | ||||
| 	 | ||||
| 		public LODSettings lodSettings = new LODSettings(); | ||||
| 		public bool applyAnimationBounds = true; | ||||
| 		public bool generateAnimationBook = true; | ||||
| 		public bool generatePrefab = true; | ||||
| 		public Shader materialShader = null; | ||||
| @@ -117,8 +118,12 @@ namespace TAO.VertexAnimation.Editor | ||||
| 			}; | ||||
|  | ||||
| 			for (int i = 0; i < meshes.Length; i++) | ||||
| 			{ | ||||
| 				if (applyAnimationBounds) | ||||
| 				{ | ||||
| 					meshes[i].bounds = bounds; | ||||
| 				} | ||||
|  | ||||
| 				meshes[i].Finalize(); | ||||
| 				AssetDatabase.AddObjectToAsset(meshes[i], this); | ||||
| 			} | ||||
|   | ||||
		Reference in New Issue
	
	Block a user