2010年2月6日 星期六

撲克牌牌型排列組合

最近迷上了一款iphone game : sword & poker, 這款遊戲是運用撲克牌牌型做組合給予敵人傷害的回合制rpg, 相當的耐玩.

因此這幾天花了點時間找資料研究關於撲克牌牌型的演算法, 以下為成果:


希望有機會也能來嘗試作作這類型的遊戲. :D


(Read more...)

2010年1月27日 星期三

QuickBox2D

QuickBox2D

QuickBox2D is a mini-library I created to work with Box2DFlashAS3. The main purpose of this library is to significantly simplify instantiation of rigid bodies and provide a simple way to skin rigid bodies with custom graphics.

可以讓你更為直覺快速建構Box2DFlashAS3物理碰撞環境.
讚! :D

(Read more...)

2010年1月26日 星期二

ListBase設定CSS後ComboxBox下拉選單字體顏色設定失效問題

在flex開發的專案中有用到css設定顏色的功能, 最近遇到ComboBox設定color下拉選單卻無法起作用的問題.後來發現如果在List組件 or ListBase 設CSS color, 會造成ComboBox設定CSS color失效, 造成的原因可能是ComboBox所顯示的下拉選單是ListBase Class的緣故.

我想這應該算是CSS繼承邏輯上的認知問題, 應該不算是什麼bug吧 :p
在這邊特此記錄一下以免又遇到相同狀況.
以下為示範的code :




(Read more...)

2010年1月17日 星期日

AS3 Data Structures For Game Developers (AS3DS)


AS3 Data Structures
AS3 Data Structures (code.google.com)

'AS3 Data Structures For Game Developers' is a package containing common data structures useful for flash game programming and application development. The project was started because I wanted a unified library which I could reuse in my games.

裡面定義許多可以運用的資料結構類別, 對開發遊戲相當地實用. 如果有機會能夠開發遊戲一定要好好研究一下:D

教學範例參考:

the graph class
the tree class
the queue class
the linked lists class 
more on linked list

(Read more...)

2010年1月11日 星期一

PushButton Engine + Box2DFlashAS3 小作品

上週末survey了幾個flash遊戲引擎, 後來挑了 PushButton Engine 研究.


The PushButton Engine is an Open Source, Flash game engine and framework that's designed for a new generation of games. PushButton Engine makes it easy to bring together great existing libraries and components for building Flash games. Spend less time on code, more time on building fun games.


PBE有加入Box2DFlashAS3的物理引擎支援,趁這週末花些時間研究一下如何應用
雖然實作上有遇到不少問題(我是挑svn latest版本研究, 跟r470版本差異部分蠻多的), 不過還是兜出了一個小作品"Avoid Ball":D
感覺PBE如果摸熟對遊戲開發上是個不錯的選擇.

- Avoid Ball:用左右鍵控制避免被球砸到(加上Box2DFlashAS3物理引擎)


- 2010/01/12 新增一個射擊遊戲範例:上下左右方向鍵控制 + 空白鍵射擊


(Read more...)

2009年12月30日 星期三

Flex4 速記

把一些常用的觀念先記下來, 日後有需要的再補上。

- Layout與組件脫離降低耦合度, 能更加靈活運用Layout.
Differences between Flex 3 and Flex 4 beta

- Group / Scroller
Introduction to viewports and scrolling in Flex 4 beta

- State狀態屬性切換更為直覺並增加易讀性
Differences between Flex 3 and Flex 4 beta

- effects : Animate/Transitions
 Effects in Adobe Flex 4 beta

- CSS
    *宣告namespace
    *多樣式設置
    *針對id設置
    *針對狀態樣式設置
How to use the new CSS syntax in Flex 4

- 雙向資料繫結 two-way data binding
How to use two-way data binding in Flex 4


(Read more...)

2009年12月27日 星期日

Mate flex framework

Mate is a tag-based, event-driven Flex framework.

雖然說關注這個framework有一陣子了卻一直沒有機會能用到,目前已經使用過Cairngorm,PureMVC. 希望日後有機會可在實際專案開發上使用。 :D


(Read more...)