diff --git a/.vs/Switch_Toolbox/v15/.suo b/.vs/Switch_Toolbox/v15/.suo index 468698c9..b471cd6b 100644 Binary files a/.vs/Switch_Toolbox/v15/.suo and b/.vs/Switch_Toolbox/v15/.suo differ diff --git a/.vs/Switch_Toolbox/v15/Server/sqlite3/storage.ide b/.vs/Switch_Toolbox/v15/Server/sqlite3/storage.ide index 041044bc..ccbd21e0 100644 Binary files a/.vs/Switch_Toolbox/v15/Server/sqlite3/storage.ide and b/.vs/Switch_Toolbox/v15/Server/sqlite3/storage.ide differ diff --git a/.vs/Switch_Toolbox/v15/Server/sqlite3/storage.ide-wal b/.vs/Switch_Toolbox/v15/Server/sqlite3/storage.ide-wal index 3ac96982..c8c88f72 100644 Binary files a/.vs/Switch_Toolbox/v15/Server/sqlite3/storage.ide-wal and b/.vs/Switch_Toolbox/v15/Server/sqlite3/storage.ide-wal differ diff --git a/Switch_FileFormatsMain/YAML/YamlFmaa.cs b/Switch_FileFormatsMain/YAML/YamlFmaa.cs index dfea1dc8..f8074900 100644 --- a/Switch_FileFormatsMain/YAML/YamlFmaa.cs +++ b/Switch_FileFormatsMain/YAML/YamlFmaa.cs @@ -16,6 +16,7 @@ namespace FirstPlugin { public string Name { get; set; } public string Path { get; set; } + public bool Loop { get; set; } public int FrameCount { get; set; } public List MaterialAnimConfigs = new List(); @@ -25,6 +26,7 @@ namespace FirstPlugin Name = materialAnim.Name; Path = materialAnim.Path; FrameCount = materialAnim.FrameCount; + Loop = materialAnim.Loop; foreach (var mat in materialAnim.MaterialAnimDataList) { @@ -87,15 +89,24 @@ namespace FirstPlugin MaterialAnim matAnim = new MaterialAnim(); matAnim.Name = Name; matAnim.Path = Path; + matAnim.Loop = Loop; matAnim.FrameCount = FrameCount; matAnim.TextureNames = GenerateTextureList(); + matAnim.BindIndices = new ushort[MaterialAnimConfigs.Count]; + for (int i = 0; i < matAnim.BindIndices.Length; i++) + matAnim.BindIndices[i] = ushort.MaxValue; foreach (var matCfg in MaterialAnimConfigs) { var matAnimData = new MaterialAnimData(); matAnimData.Constants = new List(); matAnimData.Curves = new List(); - matAnimData.BeginVisalConstantIndex = 0; + matAnimData.BeginVisalConstantIndex = -1; + matAnimData.ShaderParamCurveIndex = -1; + matAnimData.VisualConstantIndex = -1; + matAnimData.TexturePatternCurveIndex = -1; + matAnimData.VisalCurveIndex = -1; + matAnim.MaterialAnimDataList.Add(matAnimData); foreach (var texturePatternCfg in matCfg.TexturePatternInfos) { @@ -107,6 +118,9 @@ namespace FirstPlugin } else if (texturePatternCfg.CurveData != null) { + matAnimData.TexturePatternCurveIndex = 0; + matAnimData.BeginVisalConstantIndex = 0; + AnimCurve curve = new AnimCurve(); matAnimData.Curves.Add(curve); @@ -231,8 +245,16 @@ namespace FirstPlugin public static MaterialAnim FromYaml(string Name) { - var serializer = new Serializer(); - var config = serializer.Deserialize(Name); + var serializerSettings = new SerializerSettings() + { + EmitTags = false + }; + + serializerSettings.DefaultStyle = YamlStyle.Any; + serializerSettings.ComparerForKeySorting = null; + + var serializer = new Serializer(serializerSettings); + var config = serializer.Deserialize(Name); return ((AnimConfig)config).FromYaml(); } diff --git a/Switch_FileFormatsMain/obj/Release/DesignTimeResolveAssemblyReferences.cache b/Switch_FileFormatsMain/obj/Release/DesignTimeResolveAssemblyReferences.cache index a3758d1f..d79637cf 100644 Binary files a/Switch_FileFormatsMain/obj/Release/DesignTimeResolveAssemblyReferences.cache and b/Switch_FileFormatsMain/obj/Release/DesignTimeResolveAssemblyReferences.cache differ