Unity UI基类(暂时) using System.Collections; using System.Collections.Generic; using TMPro; using UnityEngine; using UnityEngine.EventSystems; using UnityEngine.UI; 2025-05-26 14 0
简单工厂设计模式(暂时) 一、工厂设计模式(Factory Pattern) 核心思想 将对象的创建和使用分离,通过统一的接口创建对象,避免直接在代码中硬编码 new 或 Instantiate,提高灵活性和可扩展性。 2025-05-22 17 0
Unity网络 分包粘包 //处理接受消息 分包、黏包问题的方法 private void HandleReceiveMsg(byte[] receiveBytes, int receiveNum) { int msgID = 0; int msgLength = 0; 2025-05-18 21 0
Unity 封装服务端练习(暂时) using System; using System.Collections.Generic; using System.Net; using System.Net.Sockets; using System.Text; using System.Threading; namespace Teac 2025-05-14 18 0
Unity C#线程池 using System.Collections; using System.Collections.Generic; using System.Threading; using UnityEngine; public class Lesson4 : MonoBehaviour { Thr 2025-05-13 13 0
Unity Task封装线程池类 using System.Collections; using System.Collections.Generic; using System.Threading; using System.Threading.Tasks; using UnityEngine; public class Les 2025-05-13 12 0
Unity网络基础Socket连接理论知识 服务端和客户端需要做什么 客户端 1.创建套接字Socket 2.用Connect方法与服务端相连 3.用Send和Receive相关方法收发数据 4.用Shutdown方法释放连接 5.关闭套接字 服务端 1.创建套接字Socket 2.用Bind方法将套接字与本地地址绑定 3.用Listen方法 2025-05-13 15 1
Unity网络基础socket套接字 using System.Collections; using System.Collections.Generic; using System.Net; using System.Net.Sockets; using UnityEngine; public class Lesson5 : Mon 2025-05-13 21 0
Unity网络基础二进制序列化 using System; using System.Collections; using System.Collections.Generic; using System.Text; using UnityEngine; using UnityEngine.WSA; public abstrac 2025-05-12 31 0
Unity网络基础域名解析 using System.Collections; using System.Collections.Generic; using System.Net; using System.Threading.Tasks; using UnityEngine; public class Lesson2 : 2025-05-09 22 0