From b4ea36cb687c1a464a5d7fe0161ddecda2e99258 Mon Sep 17 00:00:00 2001 From: 4sval Date: Fri, 4 Nov 2022 08:13:49 +0100 Subject: [PATCH] socket format --- CUE4Parse | 2 +- FModel/Settings/UserSettings.cs | 7 ++++ FModel/ViewModels/CUE4ParseViewModel.cs | 1 + FModel/ViewModels/ModelViewerViewModel.cs | 1 + FModel/ViewModels/SettingsViewModel.cs | 14 ++++++++ FModel/Views/SettingsView.xaml | 41 ++++++++++++++--------- 6 files changed, 50 insertions(+), 16 deletions(-) diff --git a/CUE4Parse b/CUE4Parse index 90ad492f..3ea132c5 160000 --- a/CUE4Parse +++ b/CUE4Parse @@ -1 +1 @@ -Subproject commit 90ad492f86c27577686cdbb4ed40eb06ee5f46ac +Subproject commit 3ea132c5b9464d3e0c991dadc4302a1b8da7bd06 diff --git a/FModel/Settings/UserSettings.cs b/FModel/Settings/UserSettings.cs index 6cc6e7c8..f017a1e5 100644 --- a/FModel/Settings/UserSettings.cs +++ b/FModel/Settings/UserSettings.cs @@ -607,6 +607,13 @@ namespace FModel.Settings set => SetProperty(ref _meshExportFormat, value); } + private ESocketFormat _socketExportFormat = ESocketFormat.Bone; + public ESocketFormat SocketExportFormat + { + get => _socketExportFormat; + set => SetProperty(ref _socketExportFormat, value); + } + private ELodFormat _lodExportFormat = ELodFormat.FirstLod; public ELodFormat LodExportFormat { diff --git a/FModel/ViewModels/CUE4ParseViewModel.cs b/FModel/ViewModels/CUE4ParseViewModel.cs index 91384f6f..15481014 100644 --- a/FModel/ViewModels/CUE4ParseViewModel.cs +++ b/FModel/ViewModels/CUE4ParseViewModel.cs @@ -823,6 +823,7 @@ public class CUE4ParseViewModel : ViewModel TextureFormat = UserSettings.Default.TextureExportFormat, LodFormat = UserSettings.Default.LodExportFormat, MeshFormat = UserSettings.Default.MeshExportFormat, + SocketFormat = UserSettings.Default.SocketExportFormat, Platform = UserSettings.Default.OverridedPlatform, ExportMorphTargets = UserSettings.Default.SaveMorphTargets }; diff --git a/FModel/ViewModels/ModelViewerViewModel.cs b/FModel/ViewModels/ModelViewerViewModel.cs index d19d5dce..2e141e28 100644 --- a/FModel/ViewModels/ModelViewerViewModel.cs +++ b/FModel/ViewModels/ModelViewerViewModel.cs @@ -192,6 +192,7 @@ public class ModelViewerViewModel : ViewModel TextureFormat = UserSettings.Default.TextureExportFormat, LodFormat = UserSettings.Default.LodExportFormat, MeshFormat = UserSettings.Default.MeshExportFormat, + SocketFormat = UserSettings.Default.SocketExportFormat, Platform = UserSettings.Default.OverridedPlatform, ExportMorphTargets = UserSettings.Default.SaveMorphTargets }; diff --git a/FModel/ViewModels/SettingsViewModel.cs b/FModel/ViewModels/SettingsViewModel.cs index 7ab634c9..f6567b87 100644 --- a/FModel/ViewModels/SettingsViewModel.cs +++ b/FModel/ViewModels/SettingsViewModel.cs @@ -131,6 +131,13 @@ public class SettingsViewModel : ViewModel set => SetProperty(ref _selectedMeshExportFormat, value); } + private ESocketFormat _selectedSocketExportFormat; + public ESocketFormat SelectedSocketExportFormat + { + get => _selectedSocketExportFormat; + set => SetProperty(ref _selectedSocketExportFormat, value); + } + private ELodFormat _selectedLodExportFormat; public ELodFormat SelectedLodExportFormat { @@ -154,6 +161,7 @@ public class SettingsViewModel : ViewModel public ReadOnlyObservableCollection CompressedAudios { get; private set; } public ReadOnlyObservableCollection CosmeticStyles { get; private set; } public ReadOnlyObservableCollection MeshExportFormats { get; private set; } + public ReadOnlyObservableCollection SocketExportFormats { get; private set; } public ReadOnlyObservableCollection LodExportFormats { get; private set; } public ReadOnlyObservableCollection TextureExportFormats { get; private set; } public ReadOnlyObservableCollection Platforms { get; private set; } @@ -179,6 +187,7 @@ public class SettingsViewModel : ViewModel private ECompressedAudio _compressedAudioSnapshot; private EIconStyle _cosmeticStyleSnapshot; private EMeshFormat _meshExportFormatSnapshot; + private ESocketFormat _socketExportFormatSnapshot; private ELodFormat _lodExportFormatSnapshot; private ETextureFormat _textureExportFormatSnapshot; @@ -229,6 +238,7 @@ public class SettingsViewModel : ViewModel _compressedAudioSnapshot = UserSettings.Default.CompressedAudioMode; _cosmeticStyleSnapshot = UserSettings.Default.CosmeticStyle; _meshExportFormatSnapshot = UserSettings.Default.MeshExportFormat; + _socketExportFormatSnapshot = UserSettings.Default.SocketExportFormat; _lodExportFormatSnapshot = UserSettings.Default.LodExportFormat; _textureExportFormatSnapshot = UserSettings.Default.TextureExportFormat; @@ -242,6 +252,7 @@ public class SettingsViewModel : ViewModel SelectedCompressedAudio = _compressedAudioSnapshot; SelectedCosmeticStyle = _cosmeticStyleSnapshot; SelectedMeshExportFormat = _meshExportFormatSnapshot; + SelectedSocketExportFormat = _socketExportFormatSnapshot; SelectedLodExportFormat = _lodExportFormatSnapshot; SelectedTextureExportFormat = _textureExportFormatSnapshot; SelectedAesReload = UserSettings.Default.AesReload; @@ -256,6 +267,7 @@ public class SettingsViewModel : ViewModel CompressedAudios = new ReadOnlyObservableCollection(new ObservableCollection(EnumerateCompressedAudios())); CosmeticStyles = new ReadOnlyObservableCollection(new ObservableCollection(EnumerateCosmeticStyles())); MeshExportFormats = new ReadOnlyObservableCollection(new ObservableCollection(EnumerateMeshExportFormat())); + SocketExportFormats = new ReadOnlyObservableCollection(new ObservableCollection(EnumerateSocketExportFormat())); LodExportFormats = new ReadOnlyObservableCollection(new ObservableCollection(EnumerateLodExportFormat())); TextureExportFormats = new ReadOnlyObservableCollection(new ObservableCollection(EnumerateTextureExportFormat())); Platforms = new ReadOnlyObservableCollection(new ObservableCollection(EnumerateUePlatforms())); @@ -344,6 +356,7 @@ public class SettingsViewModel : ViewModel UserSettings.Default.CompressedAudioMode = SelectedCompressedAudio; UserSettings.Default.CosmeticStyle = SelectedCosmeticStyle; UserSettings.Default.MeshExportFormat = SelectedMeshExportFormat; + UserSettings.Default.SocketExportFormat = SelectedSocketExportFormat; UserSettings.Default.LodExportFormat = SelectedLodExportFormat; UserSettings.Default.TextureExportFormat = SelectedTextureExportFormat; UserSettings.Default.AesReload = SelectedAesReload; @@ -367,6 +380,7 @@ public class SettingsViewModel : ViewModel private IEnumerable EnumerateCompressedAudios() => Enum.GetValues(); private IEnumerable EnumerateCosmeticStyles() => Enum.GetValues(); private IEnumerable EnumerateMeshExportFormat() => Enum.GetValues(); + private IEnumerable EnumerateSocketExportFormat() => Enum.GetValues(); private IEnumerable EnumerateLodExportFormat() => Enum.GetValues(); private IEnumerable EnumerateTextureExportFormat() => Enum.GetValues(); private IEnumerable EnumerateUePlatforms() => Enum.GetValues(); diff --git a/FModel/Views/SettingsView.xaml b/FModel/Views/SettingsView.xaml index 77f2202e..b8e1cc48 100644 --- a/FModel/Views/SettingsView.xaml +++ b/FModel/Views/SettingsView.xaml @@ -306,6 +306,7 @@ + @@ -330,8 +331,8 @@ - - + @@ -340,8 +341,18 @@ - - + + + + + + + + + + + - - + + - - + - - + - - + - + - - +