From c85adbe65b9c4adac183de716c3044f93358388a Mon Sep 17 00:00:00 2001 From: walon Date: Thu, 24 Nov 2022 12:09:04 +0800 Subject: [PATCH] =?UTF-8?q?[refactor]=20=20UNITY=5FVERSION=20=E7=9B=B8?= =?UTF-8?q?=E5=85=B3=E5=AE=9A=E4=B9=89=E4=BB=8E=20Il2CppCompatibleDef.h=20?= =?UTF-8?q?=E7=A7=BB=E5=88=B0=20il2cpp-config.h?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Editor/Commands/Il2CppDefGeneratorCommand.cs | 2 +- Editor/Il2CppDef/Il2CppDefGenerator.cs | 2 +- Runtime/UnchangedAttribute.cs | 2 +- package.json | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Editor/Commands/Il2CppDefGeneratorCommand.cs b/Editor/Commands/Il2CppDefGeneratorCommand.cs index 97a407a..b503aa1 100644 --- a/Editor/Commands/Il2CppDefGeneratorCommand.cs +++ b/Editor/Commands/Il2CppDefGeneratorCommand.cs @@ -18,7 +18,7 @@ namespace HybridCLR.Editor.Commands var options = new Il2CppDef.Il2CppDefGenerator.Options() { UnityVersion = UnityEngine.Application.unityVersion, - OutputFile = $"{SettingsUtil.LocalIl2CppDir}/libil2cpp/hybridclr/Il2CppCompatibleDef.h", + OutputFile = $"{SettingsUtil.LocalIl2CppDir}/libil2cpp/il2cpp-config.h", }; var g = new Il2CppDef.Il2CppDefGenerator(options); diff --git a/Editor/Il2CppDef/Il2CppDefGenerator.cs b/Editor/Il2CppDef/Il2CppDefGenerator.cs index cac458a..ae1a8c0 100644 --- a/Editor/Il2CppDef/Il2CppDefGenerator.cs +++ b/Editor/Il2CppDef/Il2CppDefGenerator.cs @@ -50,7 +50,7 @@ namespace HybridCLR.Editor.Il2CppDef } } - frr.Replace("UNITY_CONFIG", string.Join("\n", lines)); + frr.Replace("UNITY_VERSION", string.Join("\n", lines)); frr.Commit(_options.OutputFile); Debug.Log($"[HybridCLR.Editor.Il2CppDef.Generator] output:{_options.OutputFile}"); diff --git a/Runtime/UnchangedAttribute.cs b/Runtime/UnchangedAttribute.cs index fd974b9..9337168 100644 --- a/Runtime/UnchangedAttribute.cs +++ b/Runtime/UnchangedAttribute.cs @@ -5,7 +5,7 @@ using System.Threading.Tasks; namespace HybridCLR.Runtime { - [AttributeUsage(AttributeTargets.Method)] + [AttributeUsage(AttributeTargets.Method | AttributeTargets.Struct)] public class UnchangedAttribute : Attribute { public bool Unchanged { get; } diff --git a/package.json b/package.json index fc5898c..444dbe8 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "com.focus-creative-games.hybridclr_unity", - "version": "0.10.5", + "version": "0.11.0", "displayName": "HybridCLR", "description": "Unity package for HybridCLR. It includes editor and runtime scripts and assets for HybridCLR", "category": "Runtime",