mirror of
https://github.com/aelurum/AssetStudio.git
synced 2025-05-27 22:00:23 -04:00
fixed some bug
This commit is contained in:
parent
0cd8d51526
commit
7e67f354e4
@ -1,7 +1,7 @@
|
|||||||
|
|
||||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||||
# Visual Studio 14
|
# Visual Studio 15
|
||||||
VisualStudioVersion = 14.0.25420.1
|
VisualStudioVersion = 15.0.27130.2024
|
||||||
MinimumVisualStudioVersion = 10.0.40219.1
|
MinimumVisualStudioVersion = 10.0.40219.1
|
||||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Unity Studio", "Unity Studio\Unity Studio.csproj", "{24551E2D-E9B6-4CD6-8F2A-D9F4A13E7853}"
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Unity Studio", "Unity Studio\Unity Studio.csproj", "{24551E2D-E9B6-4CD6-8F2A-D9F4A13E7853}"
|
||||||
EndProject
|
EndProject
|
||||||
@ -25,4 +25,7 @@ Global
|
|||||||
GlobalSection(SolutionProperties) = preSolution
|
GlobalSection(SolutionProperties) = preSolution
|
||||||
HideSolutionNode = FALSE
|
HideSolutionNode = FALSE
|
||||||
EndGlobalSection
|
EndGlobalSection
|
||||||
|
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||||
|
SolutionGuid = {F5C476A6-2B3B-416F-8BD5-6FE454FF3972}
|
||||||
|
EndGlobalSection
|
||||||
EndGlobal
|
EndGlobal
|
||||||
|
@ -1797,12 +1797,21 @@ namespace Unity_Studio
|
|||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
#region Face
|
#region Face
|
||||||
for (int f = 0; f < m_Mesh.m_Indices.Count / 3; f++)
|
int sum = 0;
|
||||||
|
for (var i = 0; i < m_Mesh.m_SubMeshes.Count; i++)
|
||||||
|
{
|
||||||
|
sb.AppendLine($"g {m_Mesh.m_Name}_{i}");
|
||||||
|
int indexCount = (int)m_Mesh.m_SubMeshes[i].indexCount;
|
||||||
|
var end = sum + indexCount / 3;
|
||||||
|
for (int f = sum; f < end; f++)
|
||||||
{
|
{
|
||||||
sb.AppendFormat("f {0}/{0}/{0} {1}/{1}/{1} {2}/{2}/{2}\r\n", m_Mesh.m_Indices[f * 3 + 2] + 1, m_Mesh.m_Indices[f * 3 + 1] + 1, m_Mesh.m_Indices[f * 3] + 1);
|
sb.AppendFormat("f {0}/{0}/{0} {1}/{1}/{1} {2}/{2}/{2}\r\n", m_Mesh.m_Indices[f * 3 + 2] + 1, m_Mesh.m_Indices[f * 3 + 1] + 1, m_Mesh.m_Indices[f * 3] + 1);
|
||||||
}
|
}
|
||||||
|
sum = end;
|
||||||
|
}
|
||||||
#endregion
|
#endregion
|
||||||
|
|
||||||
|
sb.Replace("NaN", "0");
|
||||||
File.WriteAllText(exportFullName, sb.ToString());
|
File.WriteAllText(exportFullName, sb.ToString());
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user