diff --git a/Editor/BuildProcess/ObfuzProcess2021.cs b/Editor/BuildProcess/ObfuzProcess2021.cs index 7445fef..f8075c9 100644 --- a/Editor/BuildProcess/ObfuzProcess2021.cs +++ b/Editor/BuildProcess/ObfuzProcess2021.cs @@ -15,7 +15,7 @@ using System.Reflection; namespace Obfuz { -#if UNITY_2019 || UNITY_2020 || UNITY_2021 +#if UNITY_2019 || UNITY_2020 || UNITY_2021 || UNITY_2022 internal class ObfuzProcess2021 : IPreprocessBuildWithReport, IPostprocessBuildWithReport { private static bool s_obfuscated = false; @@ -35,9 +35,11 @@ namespace Obfuz private static string GetScriptAssembliesPath(object obj) { -#if UNITY_2021 - object settings = obj.GetType().GetProperty("settings").GetValue(obj); - string path = (string)settings.GetType().GetProperty("OutputDirectory").GetValue(settings); +#if UNITY_2021_1_OR_NEWER + //object settings = obj.GetType().GetProperty("settings").GetValue(obj); + //string path = (string)settings.GetType().GetProperty("OutputDirectory").GetValue(settings); + //return path; + return "Library/Bee/PlayerScriptAssemblies"; #else return "Library/PlayerScriptAssemblies"; #endif diff --git a/Editor/BuildProcess/ObfuzProcess2022OrNewer.cs b/Editor/BuildProcess/ObfuzProcess2022OrNewer.cs index 6ff58f1..e99fccc 100644 --- a/Editor/BuildProcess/ObfuzProcess2022OrNewer.cs +++ b/Editor/BuildProcess/ObfuzProcess2022OrNewer.cs @@ -14,7 +14,7 @@ using UnityEditor.Compilation; namespace Obfuz { -#if UNITY_2022_1_OR_NEWER +#if DISABLE internal class ObfuzProcess2022OrNewer : IPreprocessBuildWithReport, IProcessSceneWithReport, IPostprocessBuildWithReport { private static bool s_inBuild = false;