-
Notifications
You must be signed in to change notification settings - Fork 8
Open
Description
On the M2Utility - PostProcessImports() The for loop can crash, I haven't dove into to see why, but I added a try/catch so it could fail the needed ones and still end up clearing the queue.
try
{
if (metadata.textureTransforms.Count > 0 && metadata.textureTransforms[0].translation.timestamps.Count > 0)
{
for (int i = 0; i < metadata.textureTransforms.Count; i++)
{
Debug.Log("Creating animation clips for: " + metadata.fileName);
Debug.Log("Creating animation clip metadata.textureTransforms[i].translation.timestamps.Count: " + metadata.textureTransforms[i].translation.timestamps.Count);
Debug.Log("Creating animation clip metadata.textureTransforms[i].translation.values.Count" + metadata.textureTransforms[i].translation.values.Count);
AnimationClip newClip = AnimationUtility.CreateAnimationClip(metadata.textureTransforms[i]);
AssetDatabase.CreateAsset(newClip, Path.GetDirectoryName(path) + "/" + Path.GetFileNameWithoutExtension(path) + "[" + i + "]" + ".anim");
}
}
}
catch (Exception e)
{
Debug.LogError("Failed to create animation clip for: " + metadata.fileName);
Debug.LogError(e);
}Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels
