# Puyo-Puyo设计文档

Puyo-Puyo设计文档

Purpose:

----------

The goal of this exercise is to develop a JAVA or C/C++ version of Puyo-Puyo, a variation of the Tetris game.

Rules of Game:

---------------

* Spheres come down from the top of the game board in pairs. A player can rotate them on their way down.

* Spheres come in 4 different colors: red, blue, green, and yellow

* Linking four spheres of the same color (horizontally, vertically or both(as in tetris)) removes them from the game board, allowing any sphere remaining to drop and fill the vacated space.

This may lead to several possible "chain combos" if additional colors match.

* The game board can be any size you want (we recommend 6x12)

l Note that the pair of spheres are not linked to each other. If one sphere is blocked because there is something underneath, the other one will continue falling (with no player control over it) until it reaches something.

1． 俄罗斯方块是单色的(当然有彩的)，其基本表示就是一个二维数组，数组中每个元素值取0和1，表示有没有方块。这个总体上来说也一样，只不过多取几个值来表示不同的颜色罢了。

0无1红2蓝3绿4黄

2． 俄罗斯方块一共有7种不同的积木，而这个就简单多了，只有一对球，呵呵。

3． 移动与碰撞检测两者几乎一样。就是那对球不是相连的，这个要另外考虑。

4． 消除算法。俄罗斯方块是一消一整行，算法上来说很好实现。而这个需要进行搜索，而且还会出现连消的情况，这应该是这个小游戏的一个难点吧。却实在实现时花了不少时间来想算法。

5． 失败条件两者一样。都是检测第一行是否有东西。。。。。。。

1． 下落球生成

R

G

R

G

G

G

R

R

2． 消除算法

3.连索消除

277 篇文章45 人订阅

0 条评论

1.7K70

2K40

50960

25830

69070

28880

9540

35420

7010

17410