clean some properties
[exterlulz-kokogems.git] / src / Game.h
blob9d686fdebdd1ebaac158df260f3841620d30d1b8
1 /* ----====----====----====----====----====----====----====----====----====----
2 Game.h (jeweltoy)
4 JewelToy is a simple game played against the clock.
5 Copyright (C) 2001 Giles Williams
7 This program is free software; you can redistribute it and/or
8 modify it under the terms of the GNU General Public License
9 as published by the Free Software Foundation; either version 2
10 of the License, or (at your option) any later version.
12 This program is distributed in the hope that it will be useful,
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 GNU General Public License for more details.
17 You should have received a copy of the GNU General Public License
18 along with this program; if not, write to the Free Software
19 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
20 ----====----====----====----====----====----====----====----====----====---- */
22 #import <Cocoa/Cocoa.h>
24 @class Gem;
26 @interface Game : NSObject
28 // MW...
29 NSMutableArray *scoreBubbles;
31 Gem *board[8][8];
32 int sx1,sy1,sx2,sy2, hintx, hinty;
33 int _score, _bonusMultiplier, _fadedGems;
35 // CASCADE BONUS
36 int cascade;
38 BOOL muted;
41 @property (readonly) int score;
42 @property (readonly) int bonusMultiplier;
44 @property (readonly) NSPoint hintPoint;
46 - (id)init;
47 - (id)initWithImagesFrom:(NSArray *)imageArray;
48 - (id)initWithSpritesFrom:(NSArray *)spriteArray;
49 - (void)dealloc;
51 - (void)setImagesFrom:(NSArray *)imageArray;
52 - (void)setSpritesFrom:(NSArray *)spriteArray;
54 - (int)randomGemTypeAt:(int)x :(int)y;
55 - (Gem *)gemAt:(int)x :(int)y;
56 - (NSMutableArray *)scoreBubbles;
58 - (void)setMuted:(BOOL)value;
60 - (void)swap:(int)x1 :(int)y1 and:(int)x2 :(int)y2;
61 - (void)unswap;
63 - (BOOL)testForThreeAt:(int)x :(int)y;
64 - (BOOL)checkForThreeAt:(int)x :(int)y;
65 - (BOOL)finalTestForThreeAt:(int)x :(int)y;
66 - (BOOL)checkBoardForThrees;
67 - (BOOL)boardHasMoves;
68 - (void)showAllBoardMoves;
70 - (void)removeFadedGemsAndReorganiseWithImagesFrom:(NSArray *)imageArray;
71 - (void)removeFadedGemsAndReorganiseWithSpritesFrom:(NSArray *)spriteArray;
72 - (void)shake;
73 - (void)erupt;
74 - (void)explodeGameOver;
75 - (void)wholeNewGameWithImagesFrom:(NSArray *)imageArray;
76 - (void)wholeNewGameWithSpritesFrom:(NSArray *)spriteArray;
78 - (float)collectFadedGems;
79 - (void)increaseBonusMultiplier;
81 @end