2009年8月3日

如何取得目前的網址

string usl="http://"+this.Request.ServerVariables["SERVER_NAME"].ToString();

即可

2009年6月25日

一個收集遊戲引擎的網站

DevMaster.net - Your source for game development
這個網站收集了許多商業或是open source的遊戲引擎(3D、Game Engine)
相當不錯

2009年6月24日

[Silverlight2]如何在其他物件中直接找到Page

在製作silverlight時,常常會發生,
把資料轉移到其他地方處理,但是最後卻要顯示在Page上,
原本以為要找到Page很麻煩,需要一層一層的parent去找,
不過不用,請用以下代碼即可
Page _mypage = (Page)Application.Current.RootVisual;
如此一來,_mypage就直接指到page中了

2009年5月20日

Silverlight Tips of the Day

Silverlight Tips of the Day
在這個官方blog中,有從頭一開始,一步一步慢慢學習silverlight的文章,
講的很詳細,其中對於用silverlight製作遊戲的說明也很詳細,
尤其是Silverlight Tip of the Day #3: Silverlight Game Support, Limitations and Workarounds
這一篇其中引用了其他網站的連結,相當詳細,有興趣的人可以參考參考

GhostDoc Addin for Visual Studio

GhostDoc
一樣也是自動產生註解的addin
不過這是給C#用的,會幫你產生符合XML的註解

2009年5月19日

AtomineerUtils Addin for Visual Studio 2005 & 2008

AtomineerUtils
好用的visual studio addin,是懶人的好幫手!
簡單來說,可以幫你產生符合Doxygen的註解
我覺得好用功能簡介如下:
  • Command: Add Doc Comment:幫你產生註解
  • Command: Create Property/Accessor:幫你把class中的變數自動產生存取的函數
  • Command: Implement C++ method from .h:把class的function宣告完,幫你產生code
安裝方法:
下載後安裝,之後再去visual studio→選項→鍵盤→找到AtomineerUtils 開頭的設定,自己指定按鍵即可

2009年3月2日

在silverlight中使用txt 或是 xml

引用自:How to Get Files From Resources in Silverlight 2.0
簡單來說,步驟如下:
  1. 在方案管理員中,在要使用的檔案上按右鍵→屬性→建置動作→Resource
  2. 在程式中使用
    StreamResourceInfo sr = Application.GetResourceStream(new Uri("SilverlightApplication1;component/MyFile.txt", UriKind.Relative));
  3. SilverlightApplication1為擁有此物件的NameSpace
  4. MyFile.txt為要使用的檔案,若是在txt資料夾下,則應該為component/txt/MyFile.txt

2009年1月14日

Ogre介紹

簡單的說,這是一套2.5D~3D的免費繪圖引擎,而且還是open source,網路上得介紹已經很多了,我就不多說。
起手式,當然要從OGRE3D官方下載SDK或是source code。接著再去看官方的wiki開始學習吧。
一開始就先閱讀:

依照這兩個連結,應該就可以開始永遠的第一個hello world(會飛起來的好像比較厲害)