summary refs log tree commit diff stats
path: root/libs/cocos2d/CCActionTiledGrid.h
diff options
context:
space:
mode:
Diffstat (limited to 'libs/cocos2d/CCActionTiledGrid.h')
-rwxr-xr-xlibs/cocos2d/CCActionTiledGrid.h211
1 files changed, 211 insertions, 0 deletions
diff --git a/libs/cocos2d/CCActionTiledGrid.h b/libs/cocos2d/CCActionTiledGrid.h new file mode 100755 index 0000000..d66132d --- /dev/null +++ b/libs/cocos2d/CCActionTiledGrid.h
@@ -0,0 +1,211 @@
1/*
2 * cocos2d for iPhone: http://www.cocos2d-iphone.org
3 *
4 * Copyright (c) 2009 On-Core
5 *
6 * Permission is hereby granted, free of charge, to any person obtaining a copy
7 * of this software and associated documentation files (the "Software"), to deal
8 * in the Software without restriction, including without limitation the rights
9 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
10 * copies of the Software, and to permit persons to whom the Software is
11 * furnished to do so, subject to the following conditions:
12 *
13 * The above copyright notice and this permission notice shall be included in
14 * all copies or substantial portions of the Software.
15 *
16 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
19 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
21 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
22 * THE SOFTWARE.
23 *
24 */
25
26#import "CCActionGrid.h"
27
28/** CCShakyTiles3D action */
29@interface CCShakyTiles3D : CCTiledGrid3DAction
30{
31 int randrange;
32 BOOL shakeZ;
33}
34
35/** creates the action with a range, whether or not to shake Z vertices, a grid size, and duration */
36+(id)actionWithRange:(int)range shakeZ:(BOOL)shakeZ grid:(ccGridSize)gridSize duration:(ccTime)d;
37/** initializes the action with a range, whether or not to shake Z vertices, a grid size, and duration */
38-(id)initWithRange:(int)range shakeZ:(BOOL)shakeZ grid:(ccGridSize)gridSize duration:(ccTime)d;
39
40@end
41
42////////////////////////////////////////////////////////////
43
44/** CCShatteredTiles3D action */
45@interface CCShatteredTiles3D : CCTiledGrid3DAction
46{
47 int randrange;
48 BOOL once;
49 BOOL shatterZ;
50}
51
52/** creates the action with a range, whether of not to shatter Z vertices, a grid size and duration */
53+(id)actionWithRange:(int)range shatterZ:(BOOL)shatterZ grid:(ccGridSize)gridSize duration:(ccTime)d;
54/** initializes the action with a range, whether or not to shatter Z vertices, a grid size and duration */
55-(id)initWithRange:(int)range shatterZ:(BOOL)shatterZ grid:(ccGridSize)gridSize duration:(ccTime)d;
56
57@end
58
59////////////////////////////////////////////////////////////
60
61/** CCShuffleTiles action
62 Shuffle the tiles in random order
63 */
64@interface CCShuffleTiles : CCTiledGrid3DAction
65{
66 int seed;
67 NSUInteger tilesCount;
68 int *tilesOrder;
69 void *tiles;
70}
71
72/** creates the action with a random seed, the grid size and the duration */
73+(id)actionWithSeed:(int)s grid:(ccGridSize)gridSize duration:(ccTime)d;
74/** initializes the action with a random seed, the grid size and the duration */
75-(id)initWithSeed:(int)s grid:(ccGridSize)gridSize duration:(ccTime)d;
76
77@end
78
79////////////////////////////////////////////////////////////
80
81/** CCFadeOutTRTiles action
82 Fades out the tiles in a Top-Right direction
83 */
84@interface CCFadeOutTRTiles : CCTiledGrid3DAction
85{
86}
87@end
88
89////////////////////////////////////////////////////////////
90
91/** CCFadeOutBLTiles action.
92 Fades out the tiles in a Bottom-Left direction
93 */
94@interface CCFadeOutBLTiles : CCFadeOutTRTiles
95{
96}
97@end
98
99////////////////////////////////////////////////////////////
100
101/** CCFadeOutUpTiles action.
102 Fades out the tiles in upwards direction
103 */
104@interface CCFadeOutUpTiles : CCFadeOutTRTiles
105{
106}
107@end
108
109////////////////////////////////////////////////////////////
110
111/** CCFadeOutDownTiles action.
112 Fades out the tiles in downwards direction
113 */
114@interface CCFadeOutDownTiles : CCFadeOutUpTiles
115{
116}
117@end
118
119////////////////////////////////////////////////////////////
120
121/** CCTurnOffTiles action.
122 Turn off the files in random order
123 */
124@interface CCTurnOffTiles : CCTiledGrid3DAction
125{
126 int seed;
127 NSUInteger tilesCount;
128 int *tilesOrder;
129}
130
131/** creates the action with a random seed, the grid size and the duration */
132+(id)actionWithSeed:(int)s grid:(ccGridSize)gridSize duration:(ccTime)d;
133/** initializes the action with a random seed, the grid size and the duration */
134-(id)initWithSeed:(int)s grid:(ccGridSize)gridSize duration:(ccTime)d;
135@end
136
137////////////////////////////////////////////////////////////
138
139/** CCWavesTiles3D action. */
140@interface CCWavesTiles3D : CCTiledGrid3DAction
141{
142 int waves;
143 float amplitude;
144 float amplitudeRate;
145}
146
147/** waves amplitude */
148@property (nonatomic,readwrite) float amplitude;
149/** waves amplitude rate */
150@property (nonatomic,readwrite) float amplitudeRate;
151
152/** creates the action with a number of waves, the waves amplitude, the grid size and the duration */
153+(id)actionWithWaves:(int)wav amplitude:(float)amp grid:(ccGridSize)gridSize duration:(ccTime)d;
154/** initializes the action with a number of waves, the waves amplitude, the grid size and the duration */
155-(id)initWithWaves:(int)wav amplitude:(float)amp grid:(ccGridSize)gridSize duration:(ccTime)d;
156
157@end
158
159////////////////////////////////////////////////////////////
160
161/** CCJumpTiles3D action.
162 A sin function is executed to move the tiles across the Z axis
163 */
164@interface CCJumpTiles3D : CCTiledGrid3DAction
165{
166 int jumps;
167 float amplitude;
168 float amplitudeRate;
169}
170
171/** amplitude of the sin*/
172@property (nonatomic,readwrite) float amplitude;
173/** amplitude rate */
174@property (nonatomic,readwrite) float amplitudeRate;
175
176/** creates the action with the number of jumps, the sin amplitude, the grid size and the duration */
177+(id)actionWithJumps:(int)j amplitude:(float)amp grid:(ccGridSize)gridSize duration:(ccTime)d;
178/** initializes the action with the number of jumps, the sin amplitude, the grid size and the duration */
179-(id)initWithJumps:(int)j amplitude:(float)amp grid:(ccGridSize)gridSize duration:(ccTime)d;
180
181@end
182
183////////////////////////////////////////////////////////////
184
185/** CCSplitRows action */
186@interface CCSplitRows : CCTiledGrid3DAction
187{
188 int rows;
189 CGSize winSize;
190}
191/** creates the action with the number of rows to split and the duration */
192+(id)actionWithRows:(int)rows duration:(ccTime)duration;
193/** initializes the action with the number of rows to split and the duration */
194-(id)initWithRows:(int)rows duration:(ccTime)duration;
195
196@end
197
198////////////////////////////////////////////////////////////
199
200/** CCSplitCols action */
201@interface CCSplitCols : CCTiledGrid3DAction
202{
203 int cols;
204 CGSize winSize;
205}
206/** creates the action with the number of columns to split and the duration */
207+(id)actionWithCols:(int)cols duration:(ccTime)duration;
208/** initializes the action with the number of columns to split and the duration */
209-(id)initWithCols:(int)cols duration:(ccTime)duration;
210
211@end