author | unc0rr |
Sun, 01 Jul 2007 20:16:19 +0000 | |
changeset 544 | 9e068d2398ca |
parent 542 | ec26095f1bed |
child 547 | b81a055f2d06 |
permissions | -rw-r--r-- |
4 | 1 |
(* |
2 |
* Hedgewars, a worms-like game |
|
393 | 3 |
* Copyright (c) 2004-2007 Andrey Korotaev <unC0Rr@gmail.com> |
4 | 4 |
* |
183 | 5 |
* This program is free software; you can redistribute it and/or modify |
6 |
* it under the terms of the GNU General Public License as published by |
|
7 |
* the Free Software Foundation; version 2 of the License |
|
4 | 8 |
* |
183 | 9 |
* This program is distributed in the hope that it will be useful, |
10 |
* but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
11 |
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
12 |
* GNU General Public License for more details. |
|
4 | 13 |
* |
183 | 14 |
* You should have received a copy of the GNU General Public License |
15 |
* along with this program; if not, write to the Free Software |
|
16 |
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA |
|
4 | 17 |
*) |
18 |
||
19 |
unit uConsts; |
|
20 |
interface |
|
80 | 21 |
uses SDLh, uLocale; |
4 | 22 |
{$INCLUDE options.inc} |
271 | 23 |
{$INCLUDE proto.inc} |
80 | 24 |
type TStuff = (sConsoleBG, sPowerBar, sQuestion, sWindBar, |
35 | 25 |
sWindL, sWindR, sRopeNode); |
282 | 26 |
|
4 | 27 |
TGameState = (gsLandGen, gsStart, gsGame, gsConsole, gsExit); |
282 | 28 |
|
155
401f4ea24715
Engine can generate land preview and send it via IPC
unc0rr
parents:
112
diff
changeset
|
29 |
TGameType = (gmtLocal, gmtDemo, gmtNet, gmtSave, gmtLandPreview); |
282 | 30 |
|
80 | 31 |
TPathType = (ptNone, ptData, ptGraphics, ptThemes, ptCurrTheme, ptTeams, ptMaps, |
32 |
ptMapCurrent, ptDemos, ptSounds, ptGraves, ptFonts, ptForts, |
|
161 | 33 |
ptLocale, ptAmmoMenu); |
282 | 34 |
|
4 | 35 |
TSprite = (sprWater, sprCloud, sprBomb, sprBigDigit, sprFrame, |
36 |
sprLag, sprArrow, sprGrenade, sprTargetP, sprUFO, |
|
10 | 37 |
sprSmokeTrace, sprRopeHook, sprExplosion50, sprMineOff, |
78 | 38 |
sprMineOn, sprCase, sprFAid, sprDynamite, sprPower, |
80 | 39 |
sprClusterBomb, sprClusterParticle, sprFlame, sprHorizont, |
161 | 40 |
sprSky, sprAMBorders, sprAMSlot, sprAMSlotName, sprAMAmmos, |
283 | 41 |
sprAMSlotKeys, sprAMSelection, sprFinger, sprAirBomb, |
534 | 42 |
sprAirplane, sprAmAirplane, sprAmGirder, sprHHTelepMask, |
43 |
sprSwitch); |
|
282 | 44 |
|
4 | 45 |
TGearType = (gtCloud, gtAmmo_Bomb, gtHedgehog, gtAmmo_Grenade, gtHealthTag, |
83 | 46 |
gtGrave, gtUFO, gtShotgunShot, gtPickHammer, gtRope, |
49 | 47 |
gtSmokeTrace, gtExplosion, gtMine, gtCase, gtDEagleShot, gtDynamite, |
82 | 48 |
gtTeamHealthSorter, gtClusterBomb, gtCluster, gtShover, gtFlame, |
211 | 49 |
gtFirePunch, gtATStartGame, gtATSmoothWindCh, gtATFinishGame, |
520 | 50 |
gtParachute, gtAirAttack, gtAirBomb, gtBlowTorch, gtGirder, |
534 | 51 |
gtTeleport, gtSmallDamage, gtSwitcher); |
282 | 52 |
|
16 | 53 |
TGearsType = set of TGearType; |
282 | 54 |
|
55 |
TSound = (sndGrenadeImpact, sndExplosion, sndThrowPowerUp, sndThrowRelease, |
|
56 |
sndSplash, sndShotgunReload, sndShotgunFire, sndGraveImpact, |
|
57 |
sndMineTick, sndPickhammer); |
|
58 |
||
82 | 59 |
TAmmoType = (amGrenade, amClusterBomb, amBazooka, amUFO, amShotgun, amPickHammer, |
60 |
amSkip, amRope, amMine, amDEagle, amDynamite, amFirePunch, |
|
409 | 61 |
amBaseballBat, amParachute, amAirAttack, amMineStrike, amBlowTorch, |
534 | 62 |
amGirder, amTeleport, amSwitch); |
282 | 63 |
|
522 | 64 |
THWFont = (fnt16, fntBig, fntSmall); |
282 | 65 |
|
174 | 66 |
TCapGroup = (capgrpGameState, capgrpAmmoinfo, capgrpNetSay, capgrpVolume); |
282 | 67 |
|
307 | 68 |
TStatInfoType = (siGameResult, siMaxStepDamage, siKilledHHs); |
306 | 69 |
|
4 | 70 |
THHFont = record |
71 |
Handle: PTTF_Font; |
|
371 | 72 |
Height: LongInt; |
73 |
style: LongInt; |
|
4 | 74 |
Name: string[15]; |
75 |
end; |
|
282 | 76 |
|
4 | 77 |
TAmmo = record |
78 |
Propz: LongWord; |
|
79 |
Count: LongWord; |
|
80 |
NumPerTurn: LongWord; |
|
81 |
Timer: LongWord; |
|
408 | 82 |
Pos: LongWord; |
4 | 83 |
AmmoType: TAmmoType; |
84 |
end; |
|
85 |
||
86 |
||
105 | 87 |
const |
43 | 88 |
errmsgCreateSurface = 'Error creating SDL surface'; |
4 | 89 |
errmsgTransparentSet = 'Error setting transparent color'; |
90 |
errmsgUnknownCommand = 'Unknown command'; |
|
91 |
errmsgUnknownVariable = 'Unknown variable'; |
|
92 |
errmsgIncorrectUse = 'Incorrect use'; |
|
93 |
errmsgShouldntRun = 'This program shouldn''t be run manually'; |
|
94 |
||
95 |
msgLoading = 'Loading '; |
|
96 |
msgOK = 'ok'; |
|
97 |
msgFailed = 'failed'; |
|
98 |
msgGettingConfig = 'Getting game config...'; |
|
99 |
||
100 |
const |
|
304 | 101 |
cMaxPower = 1500; |
102 |
cMaxAngle = 2048; |
|
103 |
cPowerDivisor = 1500; |
|
104 |
||
74 | 105 |
MAXNAMELEN = 32; |
106 |
||
64 | 107 |
COLOR_LAND = $00FFFFFF; |
108 |
||
55
e09f7c952a40
Send run parameters by cmd line, game parameters by IPC... breaks network game
unc0rr
parents:
53
diff
changeset
|
109 |
cifRandomize = $00000001; |
e09f7c952a40
Send run parameters by cmd line, game parameters by IPC... breaks network game
unc0rr
parents:
53
diff
changeset
|
110 |
cifTheme = $00000002; |
e09f7c952a40
Send run parameters by cmd line, game parameters by IPC... breaks network game
unc0rr
parents:
53
diff
changeset
|
111 |
cifMap = $00000002; // either theme or map (or map+theme) |
e09f7c952a40
Send run parameters by cmd line, game parameters by IPC... breaks network game
unc0rr
parents:
53
diff
changeset
|
112 |
cifAllInited = cifRandomize or |
e09f7c952a40
Send run parameters by cmd line, game parameters by IPC... breaks network game
unc0rr
parents:
53
diff
changeset
|
113 |
cifTheme or |
e09f7c952a40
Send run parameters by cmd line, game parameters by IPC... breaks network game
unc0rr
parents:
53
diff
changeset
|
114 |
cifMap; |
e09f7c952a40
Send run parameters by cmd line, game parameters by IPC... breaks network game
unc0rr
parents:
53
diff
changeset
|
115 |
|
188 | 116 |
cTransparentColor: Longword = $000000; |
4 | 117 |
|
109 | 118 |
cMaxHHIndex = 7; |
423 | 119 |
cMaxHHs = 30; |
53 | 120 |
cMaxSpawnPoints = 1024; |
4 | 121 |
|
22 | 122 |
cMaxEdgePoints = 16384; |
123 |
||
53 | 124 |
cHHRadius = 9; |
70 | 125 |
cHHStepTicks = 38; |
509 | 126 |
|
294 | 127 |
cHHZ = 1000; |
128 |
cCurrHHZ = Succ(cHHZ); |
|
4 | 129 |
|
509 | 130 |
cShotgunRadius = 22; |
511 | 131 |
cBlowTorchC = 6; |
509 | 132 |
|
109 | 133 |
cKeyMaxIndex = 1023; |
4 | 134 |
|
97
e7c1df9cce2c
- make the game be run from ${PREFIX}/bin with data in ${PREFIX}/share/hedgewars/Data
unc0rr
parents:
95
diff
changeset
|
135 |
cMaxCaptions = 4; |
e7c1df9cce2c
- make the game be run from ${PREFIX}/bin with data in ${PREFIX}/share/hedgewars/Data
unc0rr
parents:
95
diff
changeset
|
136 |
|
4 | 137 |
cInactDelay = 1500; |
138 |
||
139 |
gfForts = $00000001; |
|
140 |
||
141 |
gstDrowning = $00000001; |
|
142 |
gstHHDriven = $00000002; |
|
143 |
gstMoving = $00000004; |
|
144 |
gstAttacked = $00000008; |
|
145 |
gstAttacking = $00000010; |
|
146 |
gstCollision = $00000020; |
|
147 |
gstHHChooseTarget = $00000040; |
|
148 |
gstHHJumping = $00000100; |
|
149 |
gsttmpFlag = $00000200; |
|
150 |
gstHHThinking = $00000800; |
|
79 | 151 |
gstNoDamage = $00001000; |
424 | 152 |
gstHHHJump = $00002000; |
511 | 153 |
gstAnimation = $00004000; |
4 | 154 |
|
155 |
gm_Left = $00000001; |
|
156 |
gm_Right = $00000002; |
|
157 |
gm_Up = $00000004; |
|
158 |
gm_Down = $00000008; |
|
159 |
gm_Switch = $00000010; |
|
160 |
gm_Attack = $00000020; |
|
161 |
gm_LJump = $00000040; |
|
162 |
gm_HJump = $00000080; |
|
163 |
gm_Destroy= $00000100; |
|
164 |
||
263 | 165 |
cMaxSlotIndex = 8; |
409 | 166 |
cMaxSlotAmmoIndex = 2; |
4 | 167 |
|
168 |
ammoprop_Timerable = $00000001; |
|
169 |
ammoprop_Power = $00000002; |
|
170 |
ammoprop_NeedTarget = $00000004; |
|
171 |
ammoprop_ForwMsgs = $00000008; |
|
542 | 172 |
ammoprop_AttackInMove = $00000010; |
13 | 173 |
ammoprop_NoCrosshair = $00000040; |
263 | 174 |
ammoprop_AttackingPut = $00000080; |
4 | 175 |
AMMO_INFINITE = High(LongWord); |
176 |
||
42 | 177 |
EXPLAllDamageInRadius = $00000001; |
178 |
EXPLAutoSound = $00000002; |
|
179 |
EXPLNoDamage = $00000004; |
|
180 |
EXPLDoNotTouchHH = $00000008; |
|
305 | 181 |
EXPLDontDraw = $00000010; |
42 | 182 |
|
183 |
posCaseAmmo = $00000001; |
|
184 |
posCaseHealth = $00000002; |
|
4 | 185 |
|
371 | 186 |
NoPointX = Low(LongInt); |
4 | 187 |
|
74 | 188 |
cHHFileName = 'Hedgehog'; |
189 |
cCHFileName = 'Crosshair'; |
|
4 | 190 |
cThemeCFGFilename = 'theme.cfg'; |
191 |
||
192 |
Fontz: array[THWFont] of THHFont = ( |
|
351 | 193 |
(Handle: nil; |
194 |
Height: 12; |
|
202 | 195 |
style: TTF_STYLE_NORMAL; |
74 | 196 |
Name: 'DejaVuSans.ttf'), |
351 | 197 |
(Handle: nil; |
198 |
Height: 24; |
|
202 | 199 |
style: TTF_STYLE_NORMAL; |
522 | 200 |
Name: 'DejaVuSans.ttf'), |
201 |
(Handle: nil; |
|
202 |
Height: 10; |
|
203 |
style: TTF_STYLE_NORMAL; |
|
74 | 204 |
Name: 'DejaVuSans.ttf') |
4 | 205 |
); |
206 |
||
202 | 207 |
FontBorder = 2; |
208 |
||
99 | 209 |
PathPrefix: string = './'; |
210 |
Pathz: array[TPathType] of string = ( |
|
80 | 211 |
'', // ptNone |
267 | 212 |
'', // ptData |
213 |
'Graphics', // ptGraphics |
|
214 |
'Themes', // ptThemes |
|
215 |
'Themes/avematan', // ptCurrTheme |
|
216 |
'Teams', // ptTeams |
|
217 |
'Maps', // ptMaps |
|
53 | 218 |
'', // ptMapCurrent |
267 | 219 |
'Demos', // ptDemos |
220 |
'Sounds', // ptSounds |
|
221 |
'Graphics/Graves', // ptGraves |
|
222 |
'Fonts', // ptFonts |
|
223 |
'Forts', // ptForts |
|
224 |
'Locale', // ptLocale |
|
225 |
'Graphics/AmmoMenu' // ptAmmoMenu |
|
4 | 226 |
); |
227 |
||
228 |
StuffLoadData: array[TStuff] of record |
|
229 |
FileName: String[31]; |
|
230 |
Path : TPathType; |
|
231 |
end = ( |
|
74 | 232 |
(FileName: 'Console'; Path: ptGraphics ), // sConsoleBG |
233 |
(FileName: 'PowerBar'; Path: ptGraphics ), // sPowerBar |
|
234 |
(FileName: 'thinking'; Path: ptGraphics ), // sQuestion |
|
235 |
(FileName: 'WindBar'; Path: ptGraphics ), // sWindBar |
|
236 |
(FileName: 'WindL'; Path: ptGraphics ), // sWindL |
|
237 |
(FileName: 'WindR'; Path: ptGraphics ), // sWindR |
|
238 |
(FileName: 'RopeNode'; Path: ptGraphics ) // sRopeNode |
|
4 | 239 |
); |
240 |
StuffPoz: array[TStuff] of TSDL_Rect = ( |
|
241 |
(x: 256; y: 256; w: 256; h: 256), // sConsoleBG |
|
242 |
(x: 256; y: 768; w: 256; h: 32), // sPowerBar |
|
5 | 243 |
(x: 256; y: 512; w: 32; h: 32), // sQuestion |
244 |
(x: 256; y: 800; w: 151; h: 17), // sWindBar |
|
245 |
(x: 256; y: 817; w: 80; h: 13), // sWindL |
|
35 | 246 |
(x: 336; y: 817; w: 80; h: 13), // sWindR |
247 |
(x: 256; y: 544; w: 6; h: 6) // sRopeNode |
|
4 | 248 |
); |
249 |
SpritesData: array[TSprite] of record |
|
35 | 250 |
FileName: String[31]; |
80 | 251 |
Path, AltPath: TPathType; |
35 | 252 |
Surface : PSDL_Surface; |
371 | 253 |
Width, Height: LongInt; |
35 | 254 |
hasAlpha: boolean; |
255 |
end = ( |
|
351 | 256 |
(FileName: 'BlueWater'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
257 |
Width: 256; Height: 48; hasAlpha: false),// sprWater |
|
258 |
(FileName: 'Clouds'; Path: ptCurrTheme; AltPath: ptGraphics; Surface: nil; |
|
259 |
Width: 256; Height:128; hasAlpha: false),// sprCloud |
|
260 |
(FileName: 'Bomb'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
261 |
Width: 16; Height: 16; hasAlpha: false),// sprBomb |
|
262 |
(FileName: 'BigDigits'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
263 |
Width: 32; Height: 32; hasAlpha: true),// sprBigDigit |
|
264 |
(FileName: 'Frame'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
265 |
Width: 4; Height: 32; hasAlpha: true),// sprFrame |
|
266 |
(FileName: 'Lag'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
446 | 267 |
Width: 65; Height: 65; hasAlpha: true),// sprLag |
351 | 268 |
(FileName: 'Arrow'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
269 |
Width: 16; Height: 16; hasAlpha: false),// sprCursor |
|
270 |
(FileName: 'Grenade'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
271 |
Width: 32; Height: 32; hasAlpha: false),// sprGrenade |
|
272 |
(FileName: 'Targetp'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
273 |
Width: 32; Height: 32; hasAlpha: false),// sprTargetP |
|
274 |
(FileName: 'UFO'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
275 |
Width: 32; Height: 32; hasAlpha: false),// sprUFO |
|
276 |
(FileName:'SmokeTrace'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
277 |
Width: 32; Height: 32; hasAlpha: true),// sprSmokeTrace |
|
278 |
(FileName: 'RopeHook'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
279 |
Width: 32; Height: 32; hasAlpha: false),// sprRopeHook |
|
280 |
(FileName: 'Expl50'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
281 |
Width: 64; Height: 64; hasAlpha: false),// sprExplosion50 |
|
282 |
(FileName: 'MineOff'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
283 |
Width: 16; Height: 16; hasAlpha: false),// sprMineOff |
|
284 |
(FileName: 'MineOn'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
285 |
Width: 16; Height: 16; hasAlpha: false),// sprMineOn |
|
286 |
(FileName: 'Case'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
287 |
Width: 32; Height: 32; hasAlpha: false),// sprCase |
|
288 |
(FileName: 'FirstAid'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
289 |
Width: 48; Height: 48; hasAlpha: false),// sprFAid |
|
290 |
(FileName: 'dynamite'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
291 |
Width: 32; Height: 32; hasAlpha: false),// sprDynamite |
|
292 |
(FileName: 'Power'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
293 |
Width: 32; Height: 32; hasAlpha: true),// sprPower |
|
294 |
(FileName: 'ClBomb'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
295 |
Width: 16; Height: 16; hasAlpha: false),// sprClusterBomb |
|
296 |
(FileName:'ClParticle'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
297 |
Width: 16; Height: 16; hasAlpha: false),// sprClusterParticle |
|
298 |
(FileName: 'Flame'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
299 |
Width: 16; Height: 16; hasAlpha: false),// sprFlame |
|
300 |
(FileName: 'horizont'; Path: ptCurrTheme; AltPath: ptNone; Surface: nil; |
|
301 |
Width: 0; Height: 0; hasAlpha: false),// sprHorizont |
|
302 |
(FileName: 'Sky'; Path: ptCurrTheme; AltPath: ptNone; Surface: nil; |
|
303 |
Width: 0; Height: 0; hasAlpha: false),// sprSky |
|
304 |
(FileName: 'BrdrLines'; Path: ptAmmoMenu; AltPath: ptNone; Surface: nil; |
|
305 |
Width: 202; Height: 1; hasAlpha: false),// sprAMBorders |
|
306 |
(FileName: 'Slot'; Path: ptAmmoMenu; AltPath: ptNone; Surface: nil; |
|
307 |
Width: 202; Height: 33; hasAlpha: false),// sprAMSlot |
|
308 |
(FileName: 'AmmoName'; Path: ptAmmoMenu; AltPath: ptNone; Surface: nil; |
|
309 |
Width: 202; Height: 33; hasAlpha: false),// sprAMSlotName |
|
310 |
(FileName: 'Ammos'; Path: ptAmmoMenu; AltPath: ptNone; Surface: nil; |
|
311 |
Width: 32; Height: 32; hasAlpha: false),// sprAMAmmos |
|
312 |
(FileName: 'SlotKeys'; Path: ptAmmoMenu; AltPath: ptNone; Surface: nil; |
|
313 |
Width: 32; Height: 32; hasAlpha: false),// sprAMSlotKeys |
|
314 |
(FileName: 'Selection'; Path: ptAmmoMenu; AltPath: ptNone; Surface: nil; |
|
315 |
Width: 32; Height: 32; hasAlpha: false),// sprAMSelection |
|
316 |
(FileName: 'Finger'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
317 |
Width: 32; Height: 48; hasAlpha: false),// sprFinger |
|
318 |
(FileName: 'AirBomb'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
319 |
Width: 32; Height: 32; hasAlpha: false),// sprAirBomb |
|
320 |
(FileName: 'Airplane'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
408 | 321 |
Width: 125; Height: 42; hasAlpha: false),// sprAirplane |
322 |
(FileName:'amAirplane'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
409 | 323 |
Width: 64; Height: 32; hasAlpha: true),// sprAirplane |
324 |
(FileName: 'amGirder'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
520 | 325 |
Width: 160; Height:160; hasAlpha: false),// sprAmGirder |
326 |
(FileName: 'hhMask'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
534 | 327 |
Width: 32; Height: 32; hasAlpha: false),// sprHHTelepMask |
328 |
(FileName: 'Switch'; Path: ptGraphics; AltPath: ptNone; Surface: nil; |
|
329 |
Width: 32; Height: 32; hasAlpha: false) // sprSwitch |
|
35 | 330 |
); |
4 | 331 |
Soundz: array[TSound] of record |
332 |
FileName: String[31]; |
|
333 |
Path : TPathType; |
|
334 |
id : PMixChunk; |
|
282 | 335 |
lastChan: LongInt; |
4 | 336 |
end = ( |
467 | 337 |
(FileName: 'grenadeimpact.ogg'; Path: ptSounds; id: nil; lastChan: 0),// sndGrenadeImpact |
338 |
(FileName: 'explosion.ogg'; Path: ptSounds; id: nil; lastChan: 0),// sndExplosion |
|
339 |
(FileName: 'throwpowerup.ogg'; Path: ptSounds; id: nil; lastChan: 0),// sndThrowPowerUp |
|
340 |
(FileName: 'throwrelease.ogg'; Path: ptSounds; id: nil; lastChan: 0),// sndThrowRelease |
|
341 |
(FileName: 'splash.ogg'; Path: ptSounds; id: nil; lastChan: 0),// sndSplash |
|
342 |
(FileName: 'shotgunreload.ogg'; Path: ptSounds; id: nil; lastChan: 0),// sndShotgunReload |
|
343 |
(FileName: 'shotgunfire.ogg'; Path: ptSounds; id: nil; lastChan: 0),// sndShotgunFire |
|
344 |
(FileName: 'graveimpact.ogg'; Path: ptSounds; id: nil; lastChan: 0),// sndGraveImpact |
|
345 |
(FileName: 'minetick.ogg'; Path: ptSounds; id: nil; lastChan: 0),// sndMineTicks |
|
346 |
(FileName: 'pickhammer.ogg'; Path: ptSounds; id: nil; lastChan: 0) // sndPickhammer |
|
4 | 347 |
); |
348 |
||
349 |
Ammoz: array [TAmmoType] of record |
|
80 | 350 |
NameId: TAmmoStrId; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
351 |
Probability, NumberInCase: Longword; |
4 | 352 |
Ammo: TAmmo; |
112 | 353 |
Slot: 0..cMaxSlotIndex; |
4 | 354 |
TimeAfterTurn: Longword; |
304 | 355 |
minAngle, maxAngle: Longword; |
408 | 356 |
PosCount: Longword; |
357 |
PosSprite: TSprite; |
|
4 | 358 |
end = ( |
80 | 359 |
(NameId: sidGrenade; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
360 |
Probability: 0; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
361 |
NumberInCase: 1; |
263 | 362 |
Ammo: (Propz: ammoprop_Timerable or |
363 |
ammoprop_Power; |
|
4 | 364 |
Count: AMMO_INFINITE; |
365 |
NumPerTurn: 0; |
|
366 |
Timer: 3000; |
|
408 | 367 |
Pos: 0; |
4 | 368 |
AmmoType: amGrenade); |
10 | 369 |
Slot: 1; |
351 | 370 |
TimeAfterTurn: 3000; |
371 |
minAngle: 0; |
|
408 | 372 |
maxAngle: 0; |
495 | 373 |
PosCount: 1; |
374 |
PosSprite: sprWater), |
|
80 | 375 |
(NameId: sidClusterBomb; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
376 |
Probability: 100; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
377 |
NumberInCase: 3; |
263 | 378 |
Ammo: (Propz: ammoprop_Timerable or |
379 |
ammoprop_Power; |
|
78 | 380 |
Count: 5; |
381 |
NumPerTurn: 0; |
|
382 |
Timer: 3000; |
|
408 | 383 |
Pos: 0; |
78 | 384 |
AmmoType: amClusterBomb); |
385 |
Slot: 1; |
|
351 | 386 |
TimeAfterTurn: 3000; |
387 |
minAngle: 0; |
|
408 | 388 |
maxAngle: 0; |
495 | 389 |
PosCount: 1; |
390 |
PosSprite: sprWater), |
|
80 | 391 |
(NameId: sidBazooka; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
392 |
Probability: 0; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
393 |
NumberInCase: 1; |
4 | 394 |
Ammo: (Propz: ammoprop_Power; |
395 |
Count: AMMO_INFINITE; |
|
396 |
NumPerTurn: 0; |
|
397 |
Timer: 0; |
|
408 | 398 |
Pos: 0; |
4 | 399 |
AmmoType: amBazooka); |
10 | 400 |
Slot: 0; |
351 | 401 |
TimeAfterTurn: 3000; |
402 |
minAngle: 0; |
|
408 | 403 |
maxAngle: 0; |
495 | 404 |
PosCount: 1; |
405 |
PosSprite: sprWater), |
|
80 | 406 |
(NameId: sidUFO; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
407 |
Probability: 100; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
408 |
NumberInCase: 1; |
263 | 409 |
Ammo: (Propz: ammoprop_Power or |
410 |
ammoprop_NeedTarget; |
|
56 | 411 |
Count: 2; |
4 | 412 |
NumPerTurn: 0; |
413 |
Timer: 0; |
|
408 | 414 |
Pos: 0; |
4 | 415 |
AmmoType: amUFO); |
416 |
Slot: 0; |
|
351 | 417 |
TimeAfterTurn: 3000; |
418 |
minAngle: 0; |
|
408 | 419 |
maxAngle: 0; |
495 | 420 |
PosCount: 1; |
421 |
PosSprite: sprWater), |
|
80 | 422 |
(NameId: sidShotgun; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
423 |
Probability: 0; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
424 |
NumberInCase: 1; |
95 | 425 |
Ammo: (Propz: ammoprop_ForwMsgs; |
4 | 426 |
Count: AMMO_INFINITE; |
427 |
NumPerTurn: 1; |
|
428 |
Timer: 0; |
|
408 | 429 |
Pos: 0; |
4 | 430 |
AmmoType: amShotgun); |
431 |
Slot: 2; |
|
351 | 432 |
TimeAfterTurn: 3000; |
433 |
minAngle: 0; |
|
408 | 434 |
maxAngle: 0; |
495 | 435 |
PosCount: 1; |
436 |
PosSprite: sprWater), |
|
80 | 437 |
(NameId: sidPickHammer; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
438 |
Probability: 0; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
439 |
NumberInCase: 1; |
263 | 440 |
Ammo: (Propz: ammoprop_ForwMsgs or |
542 | 441 |
ammoprop_AttackInMove or |
263 | 442 |
ammoprop_NoCrosshair; |
4 | 443 |
Count: 2; |
444 |
NumPerTurn: 0; |
|
445 |
Timer: 0; |
|
408 | 446 |
Pos: 0; |
4 | 447 |
AmmoType: amPickHammer); |
263 | 448 |
Slot: 6; |
351 | 449 |
TimeAfterTurn: 0; |
450 |
minAngle: 0; |
|
408 | 451 |
maxAngle: 0; |
495 | 452 |
PosCount: 1; |
453 |
PosSprite: sprWater), |
|
80 | 454 |
(NameId: sidSkip; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
455 |
Probability: 0; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
456 |
NumberInCase: 1; |
4 | 457 |
Ammo: (Propz: 0; |
458 |
Count: AMMO_INFINITE; |
|
459 |
NumPerTurn: 0; |
|
460 |
Timer: 0; |
|
408 | 461 |
Pos: 0; |
4 | 462 |
AmmoType: amSkip); |
263 | 463 |
Slot: 8; |
351 | 464 |
TimeAfterTurn: 0; |
465 |
minAngle: 0; |
|
408 | 466 |
maxAngle: 0; |
495 | 467 |
PosCount: 1; |
468 |
PosSprite: sprWater), |
|
80 | 469 |
(NameId: sidRope; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
470 |
Probability: 100; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
471 |
NumberInCase: 3; |
263 | 472 |
Ammo: (Propz: ammoprop_ForwMsgs or |
542 | 473 |
ammoprop_AttackInMove; |
4 | 474 |
Count: 5; |
475 |
NumPerTurn: 0; |
|
476 |
Timer: 0; |
|
408 | 477 |
Pos: 0; |
4 | 478 |
AmmoType: amRope); |
263 | 479 |
Slot: 7; |
304 | 480 |
TimeAfterTurn: 0; |
351 | 481 |
minAngle: 0; |
408 | 482 |
maxAngle: cMaxAngle div 2; |
495 | 483 |
PosCount: 1; |
484 |
PosSprite: sprWater), |
|
80 | 485 |
(NameId: sidMine; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
486 |
Probability: 100; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
487 |
NumberInCase: 1; |
13 | 488 |
Ammo: (Propz: ammoprop_NoCrosshair; |
56 | 489 |
Count: 2; |
10 | 490 |
NumPerTurn: 0; |
491 |
Timer: 0; |
|
408 | 492 |
Pos: 0; |
10 | 493 |
AmmoType: amMine); |
79 | 494 |
Slot: 4; |
351 | 495 |
TimeAfterTurn: 5000; |
496 |
minAngle: 0; |
|
408 | 497 |
maxAngle: 0; |
495 | 498 |
PosCount: 1; |
499 |
PosSprite: sprWater), |
|
80 | 500 |
(NameId: sidDEagle; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
501 |
Probability: 100; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
502 |
NumberInCase: 2; |
37 | 503 |
Ammo: (Propz: 0; |
75 | 504 |
Count: 3; |
37 | 505 |
NumPerTurn: 3; |
506 |
Timer: 0; |
|
408 | 507 |
Pos: 0; |
37 | 508 |
AmmoType: amDEagle); |
509 |
Slot: 2; |
|
351 | 510 |
TimeAfterTurn: 3000; |
511 |
minAngle: 0; |
|
408 | 512 |
maxAngle: 0; |
495 | 513 |
PosCount: 1; |
514 |
PosSprite: sprWater), |
|
408 | 515 |
(NameId: sidDynamite; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
516 |
Probability: 100; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
517 |
NumberInCase: 1; |
408 | 518 |
Ammo: (Propz: ammoprop_NoCrosshair or |
542 | 519 |
ammoprop_AttackInMove; |
408 | 520 |
Count: 1; |
521 |
NumPerTurn: 0; |
|
522 |
Timer: 0; |
|
523 |
Pos: 0; |
|
524 |
AmmoType: amDynamite); |
|
525 |
Slot: 4; |
|
526 |
TimeAfterTurn: 5000; |
|
351 | 527 |
minAngle: 0; |
408 | 528 |
maxAngle: 0; |
495 | 529 |
PosCount: 1; |
530 |
PosSprite: sprWater), |
|
408 | 531 |
(NameId: sidFirePunch; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
532 |
Probability: 0; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
533 |
NumberInCase: 1; |
408 | 534 |
Ammo: (Propz: ammoprop_NoCrosshair or |
535 |
ammoprop_ForwMsgs or |
|
542 | 536 |
ammoprop_AttackInMove; |
408 | 537 |
Count: AMMO_INFINITE; |
538 |
NumPerTurn: 0; |
|
539 |
Timer: 0; |
|
540 |
Pos: 0; |
|
541 |
AmmoType: amFirePunch); |
|
542 |
Slot: 3; |
|
543 |
TimeAfterTurn: 3000; |
|
544 |
MinAngle: 0; |
|
545 |
maxAngle: 0; |
|
495 | 546 |
PosCount: 1; |
547 |
PosSprite: sprWater), |
|
408 | 548 |
(NameId: sidBaseballBat; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
549 |
Probability: 100; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
550 |
NumberInCase: 1; |
408 | 551 |
Ammo: (Propz: 0; |
552 |
Count: 1; |
|
553 |
NumPerTurn: 0; |
|
554 |
Timer: 0; |
|
555 |
Pos: 0; |
|
556 |
AmmoType: amBaseballBat); |
|
557 |
Slot: 3; |
|
558 |
TimeAfterTurn: 5000; |
|
351 | 559 |
minAngle: 0; |
408 | 560 |
maxAngle: cMaxAngle div 2; |
495 | 561 |
PosCount: 1; |
562 |
PosSprite: sprWater), |
|
211 | 563 |
(NameId: sidParachute; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
564 |
Probability: 100; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
565 |
NumberInCase: 1; |
263 | 566 |
Ammo: (Propz: ammoprop_ForwMsgs or |
542 | 567 |
ammoprop_AttackInMove or |
454 | 568 |
ammoprop_NoCrosshair; |
211 | 569 |
Count: 2; |
570 |
NumPerTurn: 0; |
|
571 |
Timer: 0; |
|
408 | 572 |
Pos: 0; |
211 | 573 |
AmmoType: amParachute); |
263 | 574 |
Slot: 7; |
351 | 575 |
TimeAfterTurn: 0; |
576 |
minAngle: 0; |
|
408 | 577 |
maxAngle: 0; |
495 | 578 |
PosCount: 1; |
579 |
PosSprite: sprWater), |
|
263 | 580 |
(NameId: sidAirAttack; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
581 |
Probability: 100; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
582 |
NumberInCase: 1; |
263 | 583 |
Ammo: (Propz: ammoprop_NoCrosshair or |
584 |
ammoprop_NeedTarget or |
|
585 |
ammoprop_AttackingPut; |
|
285 | 586 |
Count: 1; |
263 | 587 |
NumPerTurn: 0; |
588 |
Timer: 0; |
|
408 | 589 |
Pos: 0; |
263 | 590 |
AmmoType: amAirAttack); |
591 |
Slot: 5; |
|
351 | 592 |
TimeAfterTurn: 0; |
593 |
minAngle: 0; |
|
408 | 594 |
maxAngle: 0; |
595 |
PosCount: 2; |
|
596 |
PosSprite: sprAmAirplane), |
|
285 | 597 |
(NameId: sidMineStrike; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
598 |
Probability: 400; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
599 |
NumberInCase: 1; |
285 | 600 |
Ammo: (Propz: ammoprop_NoCrosshair or |
601 |
ammoprop_NeedTarget or |
|
602 |
ammoprop_AttackingPut; |
|
603 |
Count: 1; |
|
604 |
NumPerTurn: 0; |
|
605 |
Timer: 0; |
|
408 | 606 |
Pos: 0; |
285 | 607 |
AmmoType: amMineStrike); |
608 |
Slot: 5; |
|
351 | 609 |
TimeAfterTurn: 0; |
610 |
minAngle: 0; |
|
408 | 611 |
maxAngle: 0; |
612 |
PosCount: 2; |
|
613 |
PosSprite: sprAmAirplane), |
|
302 | 614 |
(NameId: sidBlowTorch; |
394
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
615 |
Probability: 100; |
4c017ae1226a
- Implement hack to let ammo stores work without needed assistance of frontend
unc0rr
parents:
393
diff
changeset
|
616 |
NumberInCase: 2; |
302 | 617 |
Ammo: (Propz: ammoprop_ForwMsgs; |
618 |
Count: 1; |
|
619 |
NumPerTurn: 0; |
|
620 |
Timer: 0; |
|
408 | 621 |
Pos: 0; |
302 | 622 |
AmmoType: amBlowTorch); |
623 |
Slot: 6; |
|
304 | 624 |
TimeAfterTurn: 3000; |
305 | 625 |
minAngle: 768; |
408 | 626 |
maxAngle: 1280; |
495 | 627 |
PosCount: 1; |
628 |
PosSprite: sprWater), |
|
409 | 629 |
(NameId: sidGirder; |
630 |
Probability: 400; |
|
411 | 631 |
NumberInCase: 3; |
409 | 632 |
Ammo: (Propz: ammoprop_NoCrosshair or |
633 |
ammoprop_NeedTarget or |
|
634 |
ammoprop_AttackingPut; |
|
635 |
Count: 1; |
|
636 |
NumPerTurn: 0; |
|
637 |
Timer: 0; |
|
638 |
Pos: 0; |
|
639 |
AmmoType: amGirder); |
|
640 |
Slot: 6; |
|
641 |
TimeAfterTurn: 3000; |
|
642 |
minAngle: 0; |
|
643 |
maxAngle: 0; |
|
423 | 644 |
PosCount: 8; |
520 | 645 |
PosSprite: sprAmGirder), |
646 |
(NameId: sidTeleport; |
|
647 |
Probability: 400; |
|
648 |
NumberInCase: 1; |
|
525 | 649 |
Ammo: (Propz: ammoprop_ForwMsgs or |
650 |
ammoprop_NoCrosshair or |
|
520 | 651 |
ammoprop_NeedTarget or |
652 |
ammoprop_AttackingPut; |
|
653 |
Count: 2; |
|
654 |
NumPerTurn: 0; |
|
655 |
Timer: 0; |
|
656 |
Pos: 0; |
|
657 |
AmmoType: amTeleport); |
|
658 |
Slot: 7; |
|
659 |
TimeAfterTurn: 0; |
|
660 |
minAngle: 0; |
|
661 |
maxAngle: 0; |
|
662 |
PosCount: 1; |
|
534 | 663 |
PosSprite: sprWater), |
664 |
(NameId: sidSwitch; |
|
665 |
Probability: 100; |
|
666 |
NumberInCase: 1; |
|
667 |
Ammo: (Propz: ammoprop_ForwMsgs or |
|
668 |
ammoprop_NoCrosshair; |
|
669 |
Count: 3; |
|
670 |
NumPerTurn: 0; |
|
671 |
Timer: 0; |
|
672 |
Pos: 0; |
|
673 |
AmmoType: amSwitch); |
|
674 |
Slot: 8; |
|
675 |
TimeAfterTurn: 0; |
|
676 |
minAngle: 0; |
|
677 |
maxAngle: 0; |
|
678 |
PosCount: 1; |
|
520 | 679 |
PosSprite: sprWater)); |
37 | 680 |
|
4 | 681 |
implementation |
682 |
||
683 |
end. |