tanghai 3 лет назад
Родитель
Сommit
c0e16270bc

+ 8 - 0
Unity/Assets/Scripts/Core/Method.meta

@@ -0,0 +1,8 @@
+fileFormatVersion: 2
+guid: 653a223bbff127d49baf78f578fd1e80
+folderAsset: yes
+DefaultImporter:
+  externalObjects: {}
+  userData: 
+  assetBundleName: 
+  assetBundleVariant: 

+ 0 - 0
Unity/Assets/Scripts/Mono/Helper/IStaticMethod.cs → Unity/Assets/Scripts/Core/Method/IStaticMethod.cs


+ 1 - 1
Unity/Assets/Scripts/Mono/Helper/IStaticMethod.cs.meta → Unity/Assets/Scripts/Core/Method/IStaticMethod.cs.meta

@@ -1,5 +1,5 @@
 fileFormatVersion: 2
-guid: 1d6265995f1f4d449b27faa203772743
+guid: f0cc0989ea0c5eb4a874d721f2a0cd17
 MonoImporter:
   externalObjects: {}
   serializedVersion: 2

+ 2 - 3
Unity/Assets/Scripts/Mono/Helper/MonoStaticMethod.cs → Unity/Assets/Scripts/Core/Method/StaticMethod.cs

@@ -1,15 +1,14 @@
-using System;
 using System.Reflection;
 
 namespace ET
 {
-    public class MonoStaticMethod : IStaticMethod
+    public class StaticMethod : IStaticMethod
     {
         private readonly MethodInfo methodInfo;
 
         private readonly object[] param;
 
-        public MonoStaticMethod(Assembly assembly, string typeName, string methodName)
+        public StaticMethod(Assembly assembly, string typeName, string methodName)
         {
             this.methodInfo = assembly.GetType(typeName).GetMethod(methodName);
             this.param = new object[this.methodInfo.GetParameters().Length];

+ 1 - 1
Unity/Assets/Scripts/Mono/Helper/MonoStaticMethod.cs.meta → Unity/Assets/Scripts/Core/Method/StaticMethod.cs.meta

@@ -1,5 +1,5 @@
 fileFormatVersion: 2
-guid: c3725cc38f688e24c9c31c0e5d04a4d6
+guid: fdd300b0cfa10f74a85807aad908db63
 MonoImporter:
   externalObjects: {}
   serializedVersion: 2

+ 2 - 2
Unity/Assets/Scripts/Mono/CodeLoader.cs

@@ -42,7 +42,7 @@ namespace ET
 					Dictionary<string, Type> types = AssemblyHelper.GetAssemblyTypes(typeof (Game).Assembly, this.assembly);
 					Game.EventSystem.Add(types);
 					
-					IStaticMethod start = new MonoStaticMethod(assembly, "ET.Client.Entry", "Start");
+					IStaticMethod start = new StaticMethod(assembly, "ET.Client.Entry", "Start");
 					start.Run();
 					break;
 				}
@@ -53,7 +53,7 @@ namespace ET
 					
 					assembly = Assembly.Load(assBytes, pdbBytes);
 					this.LoadLogic();
-					IStaticMethod start = new MonoStaticMethod(assembly, "ET.Client.Entry", "Start");
+					IStaticMethod start = new StaticMethod(assembly, "ET.Client.Entry", "Start");
 					start.Run();
 					break;
 				}

+ 0 - 4
Unity/Assets/Scripts/Mono/MonoBehaviour/Init.cs

@@ -16,10 +16,6 @@ namespace ET
 		
 		private void Awake()
 		{
-#if ENABLE_IL2CPP
-			this.CodeMode = CodeMode.ILRuntime;
-#endif
-
 			DontDestroyOnLoad(gameObject);
 
 			CodeLoader.Instance.CodeMode = this.CodeMode;