From bd7bb03f6492c04d5803f1555837dde34c8de767 Mon Sep 17 00:00:00 2001 From: Mikhail <99481254+DCFApixels@users.noreply.github.com> Date: Sun, 28 Apr 2024 18:56:26 +0800 Subject: [PATCH] fix for support 2020.0 --- src/Debug/MetaAttributes/MetaGroupAttribute.cs | 5 +++-- src/Utils/UncheckedCoreUtility.cs | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/Debug/MetaAttributes/MetaGroupAttribute.cs b/src/Debug/MetaAttributes/MetaGroupAttribute.cs index e8dd599..f494656 100644 --- a/src/Debug/MetaAttributes/MetaGroupAttribute.cs +++ b/src/Debug/MetaAttributes/MetaGroupAttribute.cs @@ -17,7 +17,7 @@ namespace DCFApixels.DragonECS } public MetaGroupAttribute(params string[] path) { - Data = new MetaGroupRef(string.Join('/', path)); + Data = new MetaGroupRef(string.Join("/", path)); } } public class MetaGroupRef @@ -27,13 +27,14 @@ namespace DCFApixels.DragonECS public readonly string Name; private string[] path = null; private static string pattern = @"Module(?=/)"; + private static char[] separatpor = new char[] { '/' }; public IReadOnlyCollection Splited { get { if (path == null) { - path = Name.Split('/', StringSplitOptions.RemoveEmptyEntries); + path = Name.Split(separatpor, StringSplitOptions.RemoveEmptyEntries); } return path; } diff --git a/src/Utils/UncheckedCoreUtility.cs b/src/Utils/UncheckedCoreUtility.cs index 5538d81..a85f4fc 100644 --- a/src/Utils/UncheckedCoreUtility.cs +++ b/src/Utils/UncheckedCoreUtility.cs @@ -34,7 +34,7 @@ namespace DCFApixels.DragonECS.UncheckedCore } public static bool CheckSpanValideDebug(EcsSpan span) { - HashSet set = new HashSet(span.Count); + HashSet set = new HashSet(); foreach (var e in span) { if (set.Add(e) == false)