[Kde-games-devel] KDiamond patch for checking board playability
Stefan Majewsky
majewsky at gmx.net
Thu May 29 22:12:44 CEST 2008
On Thursday 29 May 2008 02:12:03 Paul B wrote:
> I know that there's a feature freeze so this can't really be included
> in the game, and Stefan (the maintainer I think) says he'll work on
> it when feature freeze is over, but I made it for myself and decided
> to post it here for anyone who wants to use it. Or if Stefan thinks
> it's good he can incorporate it after feature freeze
I'm thinking about opening a feature branch where I can implement the features
listed on the 4.2 feature plan, and merge it with trunk after it reopens for
features. BTW are there any restrictions on branches/work?
> The isPlayable() function basically just goes through each diamond,
> checking if a combination can be made from it, and then returning
> true once it finds a possible combo. If no possible matches are found
> it returns false and the game ends.
> It could probably be easily modified to go through the whole board,
> count how much matches in total and keep the diamonds that can be
> used in matches in a list, so that it could display how much possible
> moves there are and you could have a hint button to highlight one of
> them at random.
Despite from not having tested it, the patch looks very good. However, there
are two points I would like to raise:
1. If at all, I would only include a full implementation, i.e. including the
number of possible moves, and the hint button. (Perhaps also an undo button,
but I'm not sure how the difficulty will be affected by this.)
2. KDiamond could need some refactoring. (It has mostly been hacked together
in two weeks.) I've tested the concept of a separate game manager class in
Palapeli, and it proved to be reliable and clean. Because of these dawning
changes, I'm very glad about any feature requests, as it's more easy to
include these ideas in the revised design.
3. Do not expect anything of this to happen too soon, I'm busy with my normal
life. Nevertheless, everything should be possible by 4.2.
Stefan
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part.
Url : http://mail.kde.org/pipermail/kde-games-devel/attachments/20080529/499ada7a/attachment.pgp
More information about the kde-games-devel
mailing list