diff --git a/AxibugEmuOnline.Client/Assets/Resources/Icons/76734d0ee23c1460aa92ce4e99efd55796830cb1.jpg b/AxibugEmuOnline.Client/Assets/Resources/Icons/76734d0ee23c1460aa92ce4e99efd55796830cb1.jpg deleted file mode 100644 index c54b8a3..0000000 Binary files a/AxibugEmuOnline.Client/Assets/Resources/Icons/76734d0ee23c1460aa92ce4e99efd55796830cb1.jpg and /dev/null differ diff --git a/AxibugEmuOnline.Client/Assets/Resources/Icons/PreviewFilter.bmp b/AxibugEmuOnline.Client/Assets/Resources/Icons/PreviewFilter.bmp new file mode 100644 index 0000000..f43a7b6 Binary files /dev/null and b/AxibugEmuOnline.Client/Assets/Resources/Icons/PreviewFilter.bmp differ diff --git a/AxibugEmuOnline.Client/Assets/Resources/Icons/76734d0ee23c1460aa92ce4e99efd55796830cb1.jpg.meta b/AxibugEmuOnline.Client/Assets/Resources/Icons/PreviewFilter.bmp.meta similarity index 95% rename from AxibugEmuOnline.Client/Assets/Resources/Icons/76734d0ee23c1460aa92ce4e99efd55796830cb1.jpg.meta rename to AxibugEmuOnline.Client/Assets/Resources/Icons/PreviewFilter.bmp.meta index 22d9e85..6908801 100644 --- a/AxibugEmuOnline.Client/Assets/Resources/Icons/76734d0ee23c1460aa92ce4e99efd55796830cb1.jpg.meta +++ b/AxibugEmuOnline.Client/Assets/Resources/Icons/PreviewFilter.bmp.meta @@ -1,5 +1,5 @@ fileFormatVersion: 2 -guid: a25a763784438ee40892d9d4cf4606df +guid: e043954733c440645ba43b09301ee4a6 TextureImporter: internalIDToNameTable: [] externalObjects: {} @@ -34,7 +34,7 @@ TextureImporter: maxTextureSize: 2048 textureSettings: serializedVersion: 2 - filterMode: 1 + filterMode: 0 aniso: 1 mipBias: 0 wrapU: 1 @@ -69,10 +69,10 @@ TextureImporter: platformSettings: - serializedVersion: 4 buildTarget: DefaultTexturePlatform - maxTextureSize: 2048 + maxTextureSize: 256 resizeAlgorithm: 0 - textureFormat: -1 - textureCompression: 1 + textureFormat: 4 + textureCompression: 2 compressionQuality: 50 crunchedCompression: 0 allowsAlphaSplitting: 0 diff --git a/AxibugEmuOnline.Client/Assets/Scene/AxibugEmuOnline.Client.unity b/AxibugEmuOnline.Client/Assets/Scene/AxibugEmuOnline.Client.unity index 5b8bcc3..5f46b7d 100644 --- a/AxibugEmuOnline.Client/Assets/Scene/AxibugEmuOnline.Client.unity +++ b/AxibugEmuOnline.Client/Assets/Scene/AxibugEmuOnline.Client.unity @@ -15218,7 +15218,7 @@ MonoBehaviour: m_OnCullStateChanged: m_PersistentCalls: m_Calls: [] - m_Sprite: {fileID: 21300000, guid: a25a763784438ee40892d9d4cf4606df, type: 3} + m_Sprite: {fileID: 21300000, guid: e043954733c440645ba43b09301ee4a6, type: 3} m_Type: 0 m_PreserveAspect: 0 m_FillCenter: 1 diff --git a/AxibugEmuOnline.Client/Assets/Script/AppMain/UI/BgSettingsUI/GlobalFilterListMenuItem.cs b/AxibugEmuOnline.Client/Assets/Script/AppMain/UI/BgSettingsUI/GlobalFilterListMenuItem.cs index 139c83d..d116295 100644 --- a/AxibugEmuOnline.Client/Assets/Script/AppMain/UI/BgSettingsUI/GlobalFilterListMenuItem.cs +++ b/AxibugEmuOnline.Client/Assets/Script/AppMain/UI/BgSettingsUI/GlobalFilterListMenuItem.cs @@ -1,4 +1,4 @@ -using AxibugEmuOnline.Client.ClientCore; +using AxibugEmuOnline.Client.ClientCore; using System; using System.Collections.Generic; using System.Linq; @@ -25,6 +25,7 @@ namespace AxibugEmuOnline.Client protected override void GetVirtualListDatas(Action datas) { List list = new List(); + list.Add(null); list.AddRange(App.filter.Filters.Select(f => (object)f)); datas.Invoke(list); } diff --git a/AxibugEmuOnline.Client/Assets/Script/AppMain/UI/BgSettingsUI/UI_FilterItem.cs b/AxibugEmuOnline.Client/Assets/Script/AppMain/UI/BgSettingsUI/UI_FilterItem.cs index 92e5c10..ad20700 100644 --- a/AxibugEmuOnline.Client/Assets/Script/AppMain/UI/BgSettingsUI/UI_FilterItem.cs +++ b/AxibugEmuOnline.Client/Assets/Script/AppMain/UI/BgSettingsUI/UI_FilterItem.cs @@ -1,4 +1,4 @@ -using AxibugEmuOnline.Client.ClientCore; +using AxibugEmuOnline.Client.ClientCore; using AxibugEmuOnline.Client.UI; using System; using System.Collections.Generic; @@ -9,7 +9,7 @@ using static AxibugEmuOnline.Client.FilterManager; namespace AxibugEmuOnline.Client { /// - /// ɫUI + /// 背景颜色设置UI /// public class UI_FilterItem : MenuItem, IVirtualItem { @@ -25,7 +25,10 @@ namespace AxibugEmuOnline.Client private void UpdateView() { - SetBaseInfo(Datacontext.Name, $":{Datacontext.Paramerters.Count}", null); + if (Datacontext == null) + SetBaseInfo("无", null, null); + else + SetBaseInfo(Datacontext.Name, $"参数数量:{Datacontext.Paramerters.Count}", null); } public void SetDependencyProperty(object data) @@ -35,7 +38,10 @@ namespace AxibugEmuOnline.Client if (m_select) { App.filter.EnableFilterPreview(); - App.filter.EnableFilter(Datacontext); + if (App.filter != null) + App.filter.EnableFilter(Datacontext); + else + App.filter.ShutDownFilter(); } } @@ -43,16 +49,19 @@ namespace AxibugEmuOnline.Client public override bool OnEnterItem() { - var opts = new List(); - opts.Add(new Opt_CreatePreset(Datacontext)); - opts.AddRange(Datacontext.Presets.Select(p => new Opt_Presets(Datacontext, p))); - - OverlayManager.PopSideBar(opts, onClose: () => - { - App.filter.EnableFilterPreview(); - Datacontext.ResetPreset(); - App.filter.EnableFilter(Datacontext); - }); + if (Datacontext != null && Datacontext.Paramerters.Count > 0) + { + var opts = new List(); + opts.Add(new Opt_CreatePreset(Datacontext)); + opts.AddRange(Datacontext.Presets.Select(p => new Opt_Presets(Datacontext, p))); + + OverlayManager.PopSideBar(opts, onClose: () => + { + App.filter.EnableFilterPreview(); + Datacontext.ResetPreset(); + App.filter.EnableFilter(Datacontext); + }); + } return false; } @@ -61,7 +70,7 @@ namespace AxibugEmuOnline.Client { private Filter m_filter; - public Opt_CreatePreset(Filter filter) : base("˾Ԥ", Resources.LoadAll("Icons/XMB-Icons/misc")[0]) + public Opt_CreatePreset(Filter filter) : base("创建滤镜预设", Resources.LoadAll("Icons/XMB-Icons/misc")[0]) { m_filter = filter; } @@ -81,7 +90,7 @@ namespace AxibugEmuOnline.Client var result = m_filter.CreatePreset(presetName, out var newPreset); if (!result) OverlayManager.PopTip(result); else optionUI.AddOptionMenuWhenPoping(new Opt_Presets(m_filter, newPreset)); - }, "ΪԤһ", string.Empty); + }, "为预设设置一个名称", string.Empty); } } public class Opt_Presets : ExpandMenu @@ -170,7 +179,7 @@ namespace AxibugEmuOnline.Client private Filter m_filter; private FilterPreset m_preset; - public Opt_Delete(Filter filter, FilterPreset preset) : base("ɾԤ", null) + public Opt_Delete(Filter filter, FilterPreset preset) : base("删除预设", null) { m_filter = filter; m_preset = preset;