原创 C#枚舉長度,順便寫個關於枚舉的循環選擇

獲取枚舉長度 Enum.GetValues(typeof(yourEnums)).Length; 枚舉的循環選擇 YourEnums _yourEnums; public YourEnums _YourEnum

原创 獲取周圍collider

Physics.OverlapSphere(position, Distance, mask);

原创 利用LineRenderer繪製圓

應用: 1.可視化 2.設置圓形區域 /* *********************************************** * Discribe:Use LineRenderer to DrawCircle * Auth

原创 Unity打包Windows程序,概率性出現無法全屏或分辨率不匹配等問題

註冊表 註冊表路徑: HKEY_CURRENT_USER\Software\ [CompanyName] \ [ProductName] 看Key的名稱就知道表示的是哪一個參數,就很直白 key type value

原创 編輯器拓展 => 自定義快捷鍵

控制所選層級面板物體的激活狀態 public class GameObjectControl { //控制當前選擇對象的顯示 alt + f [MenuItem("Toolkit/GameObject/Active Ga

原创 AudioClip讀寫

https://github.com/deadlyfingers/UnityWav using UnityEngine; using System.Text; using System.IO; using System; ///

原创 進制轉換-HexStrTobyte

private byte[] HexStrTobyte(string hexString) { hexString = hexString.Replace(" ", ""); if

原创 C# Delegate 4.7.1-api

C# 委託 #region 程序集 mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089 // D:\Unity2018.2.7f1\Un

原创 移動端藍牙按鍵,兼容iOS12.3以下

if (Application.platform == RuntimePlatform.WindowsEditor) { if (Input.GetKey(

原创 .NET Udp 廣播

/* Author:Wilson Date:20200111 */ Udp廣播工具 using System; using LitJson; using System.Text; using System.Net; using S

原创 計時器《一》:計時和倒計時,回調方法,計時類型

計時和倒計時,開始、進度及結束回調,計時類型,同時多個計時器計時... using UnityEngine; using System.Collections; using System; using WillData; /// <

原创 unity相關問題

unity相關問題,先查閱unity的API!!! unity相關問題,先查閱unity的API!!! unity相關問題,先查閱unity的API!!!

原创 Application.logMessageReceivedThreaded 日誌系統《三》

using System; using System.Collections; using System.Collections.Generic; using System.IO; using UnityEngine; public

原创 偶寄幾的編譯器工具

using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEditor; using System.IO;

原创 C#生成解決方案報錯

報錯內容: 1>------ 已啓動全部重新生成: 項目: WebSocket4Net, 配置: Debug Any CPU ------ 2>------ 已啓動全部重新生成: 項目: Newtonsoft.Json, 配置: