Skip to content
This repository has been archived by the owner on Jan 21, 2023. It is now read-only.

Commit

Permalink
fixed bug
Browse files Browse the repository at this point in the history
  • Loading branch information
Perfare committed Aug 6, 2020
1 parent 0a41615 commit 217a799
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
9 changes: 7 additions & 2 deletions AssetStudioFBXWrapper/FbxExporterContext.cs
Original file line number Diff line number Diff line change
Expand Up @@ -210,8 +210,13 @@ private IntPtr ExportTexture(ImportedTexture texture)
private void ExportMesh(ImportedFrame rootFrame, List<ImportedMaterial> materialList, List<ImportedTexture> textureList, IntPtr frameNode, ImportedMesh importedMesh, bool exportSkins)
{
var boneList = importedMesh.BoneList;
var totalBoneCount = boneList.Count;
var hasBones = exportSkins && boneList != null && totalBoneCount > 0;
var totalBoneCount = 0;
var hasBones = false;
if (exportSkins && boneList?.Count > 0)
{
totalBoneCount = boneList.Count;
hasBones = true;
}

var pClusterArray = IntPtr.Zero;

Expand Down
4 changes: 2 additions & 2 deletions AssetStudioGUI/Studio.cs
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ private static int ExtractWebDataFile(string webFileName, EndianBinaryReader rea
return 0;
}

private static int ExtractStreamFile(string extractPath,StreamFile[] fileList)
private static int ExtractStreamFile(string extractPath, StreamFile[] fileList)
{
int extractedCount = 0;
foreach (var file in fileList)
Expand Down Expand Up @@ -328,7 +328,7 @@ public static Dictionary<string, SortedDictionary<int, TypeTreeItem>> BuildClass
{
key = -1 - type.m_ScriptTypeIndex;
}
items.Add(key, new TypeTreeItem(key, type.m_Nodes));
items[key] = new TypeTreeItem(key, type.m_Nodes);
}
typeMap.Add(assetsFile.unityVersion, items);
}
Expand Down

0 comments on commit 217a799

Please sign in to comment.