From 2e1809793bd6a88b9bd18c4365725b254b11b28a Mon Sep 17 00:00:00 2001 From: 4sval Date: Sat, 25 Feb 2023 02:43:35 +0100 Subject: [PATCH] load mat layers from settings --- CUE4Parse | 2 +- FModel/Views/Snooper/Options.cs | 2 +- FModel/Views/Snooper/Shading/Material.cs | 3 ++- FModel/Views/Snooper/Shading/TextureHelper.cs | 2 +- 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/CUE4Parse b/CUE4Parse index 4ac22af1..e9a88678 160000 --- a/CUE4Parse +++ b/CUE4Parse @@ -1 +1 @@ -Subproject commit 4ac22af1ff164287f936730bec57261f997ce734 +Subproject commit e9a88678cc4fffecb6a5ee6dfbd3b94df0648d61 diff --git a/FModel/Views/Snooper/Options.cs b/FModel/Views/Snooper/Options.cs index 361ae4d1..e3d970a7 100644 --- a/FModel/Views/Snooper/Options.cs +++ b/FModel/Views/Snooper/Options.cs @@ -31,7 +31,7 @@ public class Options public readonly Dictionary Icons; - private ETexturePlatform _platform; + private readonly ETexturePlatform _platform; public Options() { diff --git a/FModel/Views/Snooper/Shading/Material.cs b/FModel/Views/Snooper/Shading/Material.cs index 0c6bd4ea..1dc4f10e 100644 --- a/FModel/Views/Snooper/Shading/Material.cs +++ b/FModel/Views/Snooper/Shading/Material.cs @@ -7,6 +7,7 @@ using CUE4Parse.UE4.Assets.Exports.Texture; using CUE4Parse.UE4.Objects.Core.Math; using CUE4Parse.UE4.Objects.Core.Misc; using FModel.Extensions; +using FModel.Settings; using FModel.Views.Snooper.Models; using ImGuiNET; using OpenTK.Graphics.OpenGL4; @@ -66,7 +67,7 @@ public class Material : IDisposable { Name = unrealMaterial.Name; Path = unrealMaterial.GetPathName(); - unrealMaterial.GetParams(Parameters, EMaterialFormat.AllLayers); + unrealMaterial.GetParams(Parameters, UserSettings.Default.MaterialExportFormat); } public void Setup(Options options, int uvCount) diff --git a/FModel/Views/Snooper/Shading/TextureHelper.cs b/FModel/Views/Snooper/Shading/TextureHelper.cs index e7538d9c..2811049d 100644 --- a/FModel/Views/Snooper/Shading/TextureHelper.cs +++ b/FModel/Views/Snooper/Shading/TextureHelper.cs @@ -21,6 +21,7 @@ public static class TextureHelper // B: Metallic case "hk_project": case "cosmicshake": + case "phoenix": { unsafe { @@ -42,7 +43,6 @@ public static class TextureHelper case "shootergame": case "divineknockout": case "moonman": - case "marsman": { unsafe {