Toggle navigation
Search
思元的開發筆記
Programming
Unity
LeetCode
Golang
Game Demos
Archive
Blog
About
思元的開發筆記
關於 web service, unity, blogger 等軟體工程筆記
×
Search dev.twsiyuan.com
C# IEnumerator, IEnumerable, and Yield
這篇是因為工作上同事對於 yield return 的疑問,所以開始寫這篇文章,順便整理一下自己的經驗並且複習。 Iterator Pattern 在開始之前,稍稍提及迭代設計模式(Iterator Pattern),此模式目的是提供一組介面,能夠有順序得存取聚合...
Read More
王思元
11:59 下午
程式語言
,
C-sharp
Create Linux service wrapper script
遠端登入 Linux 操作,每次啟動不因遠端登出而關閉的程式 (program),或是關閉上一次運行的程序 (process),都需要輸入許多指令,對於不熟 Linux 新手的我來說,這有點麻煩啊。因此有這懶人包 bash script,一個包裝將程式包裝成 service ...
Read More
王思元
11:41 下午
軟體開發
,
Linux
HTTP router in golang
工作需求需要使用 golang 來建立 Restful API Server,在開始實作前,最優先想到的問題是:如何處理 URL Routing。從 golang 的官方文件中,要建立一個 HTTP 服務可以透過以下的方式: 但仔細去看內部的實作後,發現 net/http ...
Read More
王思元
10:01 下午
程式語言
,
Golang
較新的文章
較舊的文章
粉絲專頁
本週熱門
網誌存檔
贊助廣告
粉絲專頁
每周熱門
建置 Unity iOS xcode 專案遇到的錯誤與解決方案 (Linker error)
建置 xcode 專案丟出的錯誤訊息:Undefined symbols 最近要在 Unity 建置 iOS 專案遇到的錯誤問題,第一次跑整個建置流程,先在 Unity 執行遊戲建置產生 xcode 專案,再開啟 xcode 專案進行 app 打包建置,但卻遇到以下 li...
C++ Library callback using C# in Unity and cross thread call
由社團文章討論所做的測試,主要是有人詢問,在外部 C++ library callback 函數中,呼叫 StartCoroutine 而導致錯誤訊息 StartCoroutine can only be called from the main thread。這明顯是一個跨執...
Unity5 Graphic raycastTarget default values
What is this 從社團上看到有人在討論,Unity GUI 大量的 UI 物件會使得 Graphic Raycaster 效能低落,因為要判斷該 Canvas 上許多的 Graphic 物件有沒有被 Ray 打到。主要的解決方案是減少判斷的 Graphic 物件,設...
C# Array operations in Unity
Array 整理一下 C# Array(陣列)的筆記,紀錄對陣列常用的操作。 結論:若需要使用程式對 Array 進行大量的資料操作,請改用 List。 範例都以以下程式碼為基礎,在 Start 撰寫以下的展示程式碼。請注意引用到 UnityEditor,請留意發佈的編譯...
Unity Platformer 2D: Character Movement using Physical
物理與碰撞 想要在 Unity 中使用其物理引擎控制 2D 遊戲物件,Rigidbody2D,這一個組件(Component)是最重要的核心。把 Rigidbody2D 加上 2D 碰撞體(2D Colliders)放在同一個 GameObject 上,即可在遊戲中看到自由落...
TortoiseGit 配置 PuTTY Key
每次使用 TortoiseGit 進行專案遠端的 Pull/Push 都需要輸入一次認證,次數多了覺得麻煩懶惰,怎麼沒法記憶認證密碼這一回事?原來只是不會用而已…,以下筆記使用 PuTTY 建立 SSH Key,讓 Git 使用 SSH Key 認證,而不用每次進行遠端操作時,...
Unity5 Editor ReorderableList
ReorderableList 整理使用 Unity ReorderableList 筆記,希望以後有範本可以直接複製貼上,不用每次都要重新找文章,依樣畫葫蘆重做一次。 // Path: /Scripts/ShopMenu.cs using UnityEngine; ...
Unity Platformer 2D: Character Animations
延續上一篇 Character 2D Movement using Physical in Unity 的練習,繼續使用 FGJ 活動中,團隊所繪製的素材繼續練習。這次要結合之前的角色移動以及跳躍功能,加上播放對應的動畫。 Prepare Animation Clips...
Unity Coroutine 使用筆記
最近有人問為什麼 Nested coroutine 的機制與問題,為什麼會是需要 yield return StartCoroutine(...) ,而不能省略 StartCoroutine ?在久遠的 Unity3.x 時代,印象中得呼叫該函數才能夠正常運作。...
TCP 連線狀態機制與流程
在開發基於 HTTP 的網路應用服務時,當有大量連線要求,或是與長連線 (Persistent connection) 要求時,常常遇到底層 TCP 的連線斷線錯誤,導致服務不穩定。因此研究了解 TCP 的連線狀態機制,並嘗試用自己的方式整理筆記,希望能從基礎知識中找到...
網誌存檔
►
2018
( 27 )
►
10月
( 1 )
►
9月
( 1 )
►
8月
( 1 )
►
6月
( 3 )
►
5月
( 5 )
►
4月
( 4 )
►
3月
( 1 )
►
2月
( 6 )
►
1月
( 5 )
►
2017
( 59 )
►
12月
( 4 )
►
11月
( 3 )
►
10月
( 6 )
►
9月
( 5 )
►
8月
( 5 )
►
7月
( 5 )
►
6月
( 5 )
►
5月
( 4 )
►
4月
( 5 )
►
3月
( 8 )
►
2月
( 6 )
►
1月
( 3 )
▼
2016
( 44 )
►
12月
( 3 )
►
11月
( 2 )
►
10月
( 6 )
►
9月
( 4 )
►
8月
( 5 )
►
7月
( 4 )
►
6月
( 4 )
►
5月
( 2 )
►
4月
( 2 )
▼
3月
( 3 )
C# IEnumerator, IEnumerable, and Yield
Create Linux service wrapper script
HTTP router in golang
►
2月
( 6 )
►
1月
( 3 )
►
2015
( 1 )
►
12月
( 1 )
贊助廣告