namespace名称修改;Loom类名修改防止和其他工程冲突
							parent
							
								
									40d8710f37
								
							
						
					
					
						commit
						a885a394c0
					
				|  | @ -2,7 +2,7 @@ | |||
| using System.Collections.Generic; | ||||
| using UnityEngine; | ||||
| 
 | ||||
| namespace Guru | ||||
| namespace DofLibrary | ||||
| { | ||||
| 
 | ||||
|     public class GameEventMgr | ||||
|  |  | |||
|  | @ -116,7 +116,7 @@ namespace DofLibrary | |||
| 
 | ||||
|             if (OnConnected != null) | ||||
|             { | ||||
|                 Loom.QueueOnMainThread(() => | ||||
|                 LoomUtil.QueueOnMainThread(() => | ||||
|                 { | ||||
|                     OnConnected.Invoke(); | ||||
|                 }); | ||||
|  | @ -139,7 +139,7 @@ namespace DofLibrary | |||
| 
 | ||||
|             if (msg is ServerMessage server_msg) | ||||
|             { | ||||
|                 Loom.QueueOnMainThread(() => | ||||
|                 LoomUtil.QueueOnMainThread(() => | ||||
|                 { | ||||
|                     ProcessMessage(server_msg); | ||||
|                 }); | ||||
|  | @ -169,7 +169,7 @@ namespace DofLibrary | |||
|             Debug.Log("[GameKcpClient]: Connection closed"); | ||||
|             if (OnDisConnected != null) | ||||
|             { | ||||
|                 Loom.QueueOnMainThread(() => | ||||
|                 LoomUtil.QueueOnMainThread(() => | ||||
|                 { | ||||
|                     OnDisConnected.Invoke(); | ||||
|                 }); | ||||
|  |  | |||
|  | @ -3,17 +3,17 @@ using System.Collections.Generic; | |||
| using System.Threading; | ||||
| using UnityEngine; | ||||
| 
 | ||||
| namespace Guru | ||||
| namespace DofLibrary | ||||
| { | ||||
|     // Loom lets you easily run code on another thread and have that other thread run code on the main game thread when it needs to. | ||||
|     public class Loom : MonoBehaviour | ||||
|     public class LoomUtil : MonoBehaviour | ||||
|     { | ||||
|         public static int maxThreads = 10; | ||||
| 
 | ||||
|         private static int numThreads; | ||||
|         private static Loom _instance; | ||||
|         private static LoomUtil _instance; | ||||
| 
 | ||||
|         public static Loom Instance | ||||
|         public static LoomUtil Instance | ||||
|         { | ||||
|             get | ||||
|             { | ||||
|  | @ -39,7 +39,7 @@ namespace Guru | |||
|                 initialized = true; | ||||
|                 var g = new GameObject("Loom"); | ||||
|                 DontDestroyOnLoad(g); | ||||
|                 _instance = g.AddComponent<Loom>(); | ||||
|                 _instance = g.AddComponent<LoomUtil>(); | ||||
|             } | ||||
|         } | ||||
| 
 | ||||
|  | @ -2,7 +2,7 @@ | |||
| using System.IO; | ||||
| using ProtoBuf.Meta; | ||||
| 
 | ||||
| namespace Guru | ||||
| namespace DofLibrary | ||||
| { | ||||
|     public interface ISupportInitialize | ||||
|     { | ||||
|  |  | |||
		Loading…
	
		Reference in New Issue