mirror of
				https://github.com/maxartz15/VertexAnimation.git
				synced 2025-11-04 10:25:44 +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;
 | 
			
		||||
@@ -118,7 +119,11 @@ namespace TAO.VertexAnimation.Editor
 | 
			
		||||
 | 
			
		||||
			for (int i = 0; i < meshes.Length; i++)
 | 
			
		||||
			{
 | 
			
		||||
				meshes[i].bounds = bounds;
 | 
			
		||||
				if (applyAnimationBounds)
 | 
			
		||||
				{
 | 
			
		||||
					meshes[i].bounds = bounds;
 | 
			
		||||
				}
 | 
			
		||||
 | 
			
		||||
				meshes[i].Finalize();
 | 
			
		||||
				AssetDatabase.AddObjectToAsset(meshes[i], this);
 | 
			
		||||
			}
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user