Просмотр исходного кода

修复编译不过的问题,热更处于试验阶段,不要影响其他人使用

tanghai 4 лет назад
Родитель
Сommit
bb68c3d042

+ 0 - 15
Client-Server.sln

@@ -43,8 +43,6 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ShareLib", "ThirdParty\Shar
 EndProject
 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Unity.Mono", "Unity\Unity.Mono.csproj", "{5910FA29-5797-199C-985B-FC9FC473328E}"
 EndProject
-Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Unity.Script", "Unity\Unity.Script.csproj", "{53D6CE23-4FE2-4716-83F4-B50A90F2D693}"
-EndProject
 Global
 	GlobalSection(SolutionConfigurationPlatforms) = preSolution
 		Debug|Any CPU = Debug|Any CPU
@@ -247,18 +245,6 @@ Global
 		{5910FA29-5797-199C-985B-FC9FC473328E}.Release|x64.Build.0 = Release|Any CPU
 		{5910FA29-5797-199C-985B-FC9FC473328E}.Release|x86.ActiveCfg = Release|Any CPU
 		{5910FA29-5797-199C-985B-FC9FC473328E}.Release|x86.Build.0 = Release|Any CPU
-		{53D6CE23-4FE2-4716-83F4-B50A90F2D693}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
-		{53D6CE23-4FE2-4716-83F4-B50A90F2D693}.Debug|Any CPU.Build.0 = Debug|Any CPU
-		{53D6CE23-4FE2-4716-83F4-B50A90F2D693}.Debug|x64.ActiveCfg = Debug|Any CPU
-		{53D6CE23-4FE2-4716-83F4-B50A90F2D693}.Debug|x64.Build.0 = Debug|Any CPU
-		{53D6CE23-4FE2-4716-83F4-B50A90F2D693}.Debug|x86.ActiveCfg = Debug|Any CPU
-		{53D6CE23-4FE2-4716-83F4-B50A90F2D693}.Debug|x86.Build.0 = Debug|Any CPU
-		{53D6CE23-4FE2-4716-83F4-B50A90F2D693}.Release|Any CPU.ActiveCfg = Release|Any CPU
-		{53D6CE23-4FE2-4716-83F4-B50A90F2D693}.Release|Any CPU.Build.0 = Release|Any CPU
-		{53D6CE23-4FE2-4716-83F4-B50A90F2D693}.Release|x64.ActiveCfg = Release|Any CPU
-		{53D6CE23-4FE2-4716-83F4-B50A90F2D693}.Release|x64.Build.0 = Release|Any CPU
-		{53D6CE23-4FE2-4716-83F4-B50A90F2D693}.Release|x86.ActiveCfg = Release|Any CPU
-		{53D6CE23-4FE2-4716-83F4-B50A90F2D693}.Release|x86.Build.0 = Release|Any CPU
 	EndGlobalSection
 	GlobalSection(SolutionProperties) = preSolution
 		HideSolutionNode = FALSE
@@ -280,7 +266,6 @@ Global
 		{9F66DBC1-55AB-40D4-B4C4-B707CB39E624} = {D885C55E-8E9B-4837-938D-15A919188607}
 		{EC8FBBC4-59C8-438C-AE16-1762C269B928} = {D885C55E-8E9B-4837-938D-15A919188607}
 		{5910FA29-5797-199C-985B-FC9FC473328E} = {914C77C9-212A-4DD0-8D9A-074620E77FAA}
-		{53D6CE23-4FE2-4716-83F4-B50A90F2D693} = {914C77C9-212A-4DD0-8D9A-074620E77FAA}
 	EndGlobalSection
 	GlobalSection(ExtensibilityGlobals) = postSolution
 		SolutionGuid = {EABC01E3-3EB5-47EF-B46E-AAD8BB3585F1}

+ 1 - 1
Libs/Interpreter/Interpreter/Interpreter.vcxproj

@@ -88,7 +88,7 @@
     <LinkIncremental>true</LinkIncremental>
     <IncludePath>$(SolutionDir)\Include;$(SolutionDir);$(IncludePath)</IncludePath>
     <LibraryPath>$(SolutionDir)\Libs;$(LibraryPath)</LibraryPath>
-    <OutDir>$(SolutionDir)Bin</OutDir>
+    <OutDir>$(SolutionDir)Bin\</OutDir>
   </PropertyGroup>
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
     <LinkIncremental>false</LinkIncremental>

+ 15 - 1
Unity/Assets/Mono/MonoBehaviour/Init.cs

@@ -44,6 +44,20 @@ namespace ET
 			}
 			else
 			{
+				UnityEngine.Debug.Log("unity standalone mode!");
+				foreach (Assembly assembly in AppDomain.CurrentDomain.GetAssemblies())
+				{
+					string assemblyName = $"{assembly.GetName().Name}.dll";
+					if (assemblyName != "Unity.ModelView.dll")
+					{
+						continue;
+					}
+
+					modelAssembly = assembly;
+					break;
+				}
+				
+				/*
 				byte[] log = new byte[1024];
 				Interpreter.InterpreterSetLog((buff, n) =>
 				{
@@ -52,7 +66,7 @@ namespace ET
 				});
 				Interpreter.InterpreterInit(@"E:\ET\Unity\UnityScript\", "Unity.Script.dll");
 				
-				/*
+				
 				UnityEngine.Debug.Log("unity script mode!");
 				byte[] dllBytes = File.ReadAllBytes("./Temp/Bin/Debug/Unity.Script.dll");
 				byte[] pdbBytes = File.ReadAllBytes("./Temp/Bin/Debug/Unity.Script.pdb");