hedgewars/uConsts.pas
author unc0rr
Mon, 22 Aug 2005 13:35:41 +0000
changeset 1 30f2d1037d5d
child 2 4eeab397c3c6
permissions -rw-r--r--
Add current sources. hw, hwserv and runhelper are compilable under Windows and *nix with FreePascal (and use -Od option) and run well on these OSes Hedge.dpr can be run only in Windows... to be ported
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
1
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
     1
(*
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
     2
 * Hedgewars, a worms-like game
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
     3
 * Copyright (c) 2004, 2005 Andrey Korotaev <unC0Rr@gmail.com>
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
     4
 *
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
     5
 * Distributed under the terms of the BSD-modified licence:
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
     6
 *
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
     7
 * Permission is hereby granted, free of charge, to any person obtaining a copy
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
     8
 * of this software and associated documentation files (the "Software"), to deal
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
     9
 * with the Software without restriction, including without limitation the
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    10
 * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    11
 * sell copies of the Software, and to permit persons to whom the Software is
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    12
 * furnished to do so, subject to the following conditions:
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    13
 *
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    14
 * 1. Redistributions of source code must retain the above copyright notice,
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    15
 *    this list of conditions and the following disclaimer.
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    16
 * 2. Redistributions in binary form must reproduce the above copyright notice,
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    17
 *    this list of conditions and the following disclaimer in the documentation
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    18
 *    and/or other materials provided with the distribution.
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    19
 * 3. The name of the author may not be used to endorse or promote products
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    20
 *    derived from this software without specific prior written permission.
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    21
 *
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    22
 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    23
 * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    24
 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    25
 * EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    26
 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    27
 * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    28
 * OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    29
 * WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    30
 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    31
 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    32
 *)
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    33
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    34
unit uConsts;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    35
interface
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    36
uses SDLh;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    37
{$INCLUDE options.inc}
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    38
type TStuff     = (sHorizont, sSky, sConsoleBG, sPowerBar, sQuestion);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    39
     TGameState = (gsLandGen, gsStart, gsGame, gsConsole, gsExit);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    40
     TGameType  = (gmtLocal, gmtDemo, gmtNet);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    41
     TPathType  = (ptData, ptGraphics, ptThemes, ptThemeCurrent, ptTeams, ptMaps,
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    42
                   ptMapCurrent, ptDemos, ptSounds, ptGraves, ptFonts, ptForts);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    43
     TSprite    = (sprWater, sprCloud, sprBomb, sprBigDigit, sprFrame,
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    44
                   sprLag, sprArrow, sprGrenade, sprTargetP, sprUFO,
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    45
                   sprSmokeTrace, sprRopeHook);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    46
     TGearType  = (gtCloud, gtAmmo_Bomb, gtHedgehog, gtAmmo_Grenade, gtHealthTag,
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    47
                   gtGrave, gtUFO, gtShotgunShot, gtActionTimer, gtPickHammer, gtRope,
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    48
                   gtSmokeTrace);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    49
     TSound     = (sndGrenadeImpact, sndExplosion, sndThrowPowerUp, sndThrowRelease, sndSplash,
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    50
                   sndShotgunReload, sndShotgunFire, sndGraveImpact);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    51
     TAmmoType  = (amGrenade, amBazooka, amUFO, amShotgun, amPickHammer, amSkip, amRope);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    52
     THWFont    = (fnt16, fntBig);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    53
     THHFont    = record
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    54
                  Handle: PTTF_Font;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    55
                  Height: integer;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    56
                  Name: string[15];
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    57
                  end;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    58
     TAmmo = record
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    59
             Propz: LongWord;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    60
             Count: LongWord;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    61
             NumPerTurn: LongWord;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    62
             Timer: LongWord;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    63
             AmmoType: TAmmoType;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    64
             end;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    65
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    66
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    67
resourcestring
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    68
      errmsgCreateSurface   = 'Error creating DirectDraw7 surface';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    69
      errmsgNoDesc          = 'Unknown error';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    70
      errmsgTransparentSet  = 'Error setting transparent color';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    71
      errmsgDynamicVar      = 'Error working with dynamic memory';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    72
      errmsgUnknownCommand  = 'Unknown command';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    73
      errmsgUnknownVariable = 'Unknown variable';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    74
      errmsgIncorrectUse    = 'Incorrect use';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    75
      errmsgShouldntRun     = 'This program shouldn''t be run manually';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    76
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    77
      msgLoading           = 'Loading ';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    78
      msgOK                = 'ok';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    79
      msgFailed            = 'failed';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    80
      msgGettingConfig     = 'Getting game config...';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    81
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    82
const
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    83
      cAppName  = 'hw';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    84
      cAppTitle = 'hw';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    85
      cNetProtoVersion = 1;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    86
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    87
      rndfillstr = 'hw';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    88
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    89
      cTransparentColor: Cardinal = $000000;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    90
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    91
      cMaxHHIndex = 9;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    92
      cMaxHHs     = 20;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    93
      cHHSurfaceWidth     = 512;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    94
      cHHSurfaceHeigth    = 256;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    95
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    96
      cHHHalfHeight = 11;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    97
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    98
      cKeyMaxIndex = 322;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
    99
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   100
      cMaxCaptions         = 4;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   101
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   102
      cInactDelay = 1500;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   103
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   104
      gstDrowning       = $00000001;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   105
      gstHHDriven       = $00000002;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   106
      gstMoving         = $00000004;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   107
      gstAttacked       = $00000008;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   108
      gstAttacking      = $00000010;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   109
      gstCollision      = $00000020;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   110
      gstHHChooseTarget = $00000040;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   111
      gstFalling        = $00000080;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   112
      gstHHJumping      = $00000100;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   113
      gsttmpFlag        = $00000200;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   114
      gstOutOfHH        = $00000400;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   115
      gstHHThinking     = $00000800;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   116
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   117
      gtsStartGame      = 1;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   118
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   119
      gm_Left   = $00000001;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   120
      gm_Right  = $00000002;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   121
      gm_Up     = $00000004;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   122
      gm_Down   = $00000008;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   123
      gm_Switch = $00000010;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   124
      gm_Attack = $00000020;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   125
      gm_LJump  = $00000040;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   126
      gm_HJump  = $00000080;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   127
      gm_Destroy= $00000100;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   128
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   129
      cMaxSlot            = 4;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   130
      cMaxSlotAmmo        = 1;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   131
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   132
      ammoprop_Timerable    = $00000001;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   133
      ammoprop_Power        = $00000002;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   134
      ammoprop_NeedTarget   = $00000004;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   135
      ammoprop_ForwMsgs     = $00000008;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   136
      ammoprop_AttackInFall = $00000010;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   137
      ammoprop_AttackInJump = $00000020;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   138
      AMMO_INFINITE = High(LongWord);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   139
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   140
      capgrpStartGame     = 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   141
      capgrpAmmoinfo      = 1;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   142
      capgrpNetSay        = 2;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   143
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   144
      EXPLAllDamageInRadius = 1;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   145
      EXPLAutoSound         = 2;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   146
      EXPLNoDamage          = 4;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   147
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   148
      cToggleConsoleKey     = 39;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   149
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   150
      NoPointX = Low(Integer); // êîíñòàíòà äëÿ TargetPoint, ïîêàçûâàåò, ÷òî öåëü íå óêàçàíà
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   151
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   152
      cLandFileName = 'Land.bmp';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   153
      cHHFileName   = 'Hedgehog.png';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   154
      cCHFileName   = 'Crosshair.png';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   155
      cThemeCFGFilename = 'theme.cfg';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   156
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   157
      Fontz: array[THWFont] of THHFont = (
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   158
                                         (Height: 12;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   159
                                          Name: 'UN1251N.TTF'),
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   160
                                         (Height: 24;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   161
                                          Name: 'UN1251N.TTF')
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   162
                                         );
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   163
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   164
      Pathz: array[TPathType] of string[ 64] = (
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   165
                                               'Data/',                         // ptData
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   166
                                               'Data/Graphics/',                // ptGraphics
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   167
                                               'Data/Themes/',                  // ptThemes
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   168
                                               'Data/Themes/Default/',          // ptThemeCurrent
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   169
                                               'Data/Teams/',                   // ptTeams
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   170
                                               'Data/Maps/',                    // ptMaps
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   171
                                               'Data/Maps/Current/',            // ptMapCurrent
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   172
                                               'Data/Demos/',                   // ptDemos
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   173
                                               'Data/Sounds/',                  // ptSounds
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   174
                                               'Data/Graphics/Graves/',         // ptGraves
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   175
                                               'Data/Fonts/',                   // ptFonts
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   176
                                               'Data/Forts/'                    // ptForts
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   177
                                               );
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   178
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   179
      StuffLoadData: array[TStuff] of record
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   180
                                     FileName: String[31];
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   181
                                     Path    : TPathType;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   182
                                     end = (
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   183
                                     (FileName: 'horizont.png'; Path: ptThemeCurrent ),    // sHorizont
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   184
                                     (FileName:      'Sky.png'; Path: ptThemeCurrent ),    // sSky
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   185
                                     (FileName:  'Console.png'; Path: ptGraphics     ),    // sConsoleBG
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   186
                                     (FileName: 'PowerBar.png'; Path: ptGraphics     ),    // sPowerBar
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   187
                                     (FileName: 'thinking.png'; Path: ptGraphics     )     // sQuestion
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   188
                                     );
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   189
      StuffPoz: array[TStuff] of TSDL_Rect = (
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   190
                                      (x:   0; y:   0; w: 512; h: 256), // sHorizont
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   191
                                      (x: 512; y:   0; w:  64; h:1024), // sSky
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   192
                                      (x: 256; y: 256; w: 256; h: 256), // sConsoleBG
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   193
                                      (x: 256; y: 768; w: 256; h:  32), // sPowerBar
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   194
                                      (x: 256; y: 512; w:  32; h:  32)  // sQuestion
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   195
                                      );
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   196
      SpritesData: array[TSprite] of record
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   197
                                         FileName: String[31];
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   198
                                         Path    : TPathType;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   199
                                         Surface : PSDL_Surface;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   200
                                         Width, Height: integer;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   201
                                         end = (
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   202
                                         (FileName: 'BlueWater.png'; Path: ptGraphics; Width: 256; Height: 48),// sprWater
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   203
                                         (FileName:    'Clouds.png'; Path: ptGraphics; Width: 256; Height:128),// sprCloud
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   204
                                         (FileName:      'Bomb.png'; Path: ptGraphics; Width:  16; Height: 16),// sprBomb
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   205
                                         (FileName: 'BigDigits.png'; Path: ptGraphics; Width:  32; Height: 32),// sprBigDigit
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   206
                                         (FileName:     'Frame.png'; Path: ptGraphics; Width:   4; Height: 32),// sprFrame
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   207
                                         (FileName:       'Lag.png'; Path: ptGraphics; Width:  64; Height: 64),// sprLag
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   208
                                         (FileName:     'Arrow.png'; Path: ptGraphics; Width:  16; Height: 16),// sprCursor
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   209
                                         (FileName:   'Grenade.png'; Path: ptGraphics; Width:  32; Height: 32),// sprGrenade
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   210
                                         (FileName:   'Targetp.png'; Path: ptGraphics; Width:  32; Height: 32),// sprTargetP
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   211
                                         (FileName:       'UFO.png'; Path: ptGraphics; Width:  32; Height: 32),// sprUFO
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   212
                                         (FileName:'SmokeTrace.png'; Path: ptGraphics; Width:  32; Height: 32),// sprSmokeTrace
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   213
                                         (FileName:  'RopeHook.png'; Path: ptGraphics; Width:  32; Height: 32) // sprRopeHook
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   214
                                         );
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   215
      Soundz: array[TSound] of record
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   216
                                       FileName: String[31];
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   217
                                       Path    : TPathType;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   218
                                       id      : PMixChunk;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   219
                                       end = (
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   220
                                       (FileName: 'grenadeimpact.ogg'; Path: ptSounds  ),// sndGrenadeImpact
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   221
                                       (FileName:     'explosion.ogg'; Path: ptSounds  ),// sndExplosion
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   222
                                       (FileName:  'throwpowerup.ogg'; Path: ptSounds  ),// sndThrowPowerUp
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   223
                                       (FileName:  'throwrelease.ogg'; Path: ptSounds  ),// sndThrowRelease
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   224
                                       (FileName:        'splash.ogg'; Path: ptSounds  ),// sndSplash
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   225
                                       (FileName: 'shotgunreload.ogg'; Path: ptSounds  ),// sndShotgunReload
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   226
                                       (FileName:   'shotgunfire.ogg'; Path: ptSounds  ),// sndShotgunFire
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   227
                                       (FileName:   'graveimpact.ogg'; Path: ptSounds  ) // sndGraveImpact
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   228
                                       );
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   229
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   230
      Ammoz: array [TAmmoType] of record
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   231
                                  Name: string[32];
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   232
                                  Ammo: TAmmo;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   233
                                  Slot: Longword;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   234
                                  TimeAfterTurn: Longword;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   235
                                  end = (
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   236
                                  (Name: 'Grenade';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   237
                                   Ammo: (Propz: ammoprop_Timerable or ammoprop_Power;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   238
                                          Count: AMMO_INFINITE;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   239
                                          NumPerTurn: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   240
                                          Timer: 3000;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   241
                                          AmmoType: amGrenade);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   242
                                   Slot: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   243
                                   TimeAfterTurn: 3000),
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   244
                                  (Name: 'Bazooka';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   245
                                   Ammo: (Propz: ammoprop_Power;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   246
                                          Count: AMMO_INFINITE;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   247
                                          NumPerTurn: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   248
                                          Timer: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   249
                                          AmmoType: amBazooka);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   250
                                   Slot: 1;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   251
                                   TimeAfterTurn: 3000),
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   252
                                  (Name: 'UFO';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   253
                                   Ammo: (Propz: ammoprop_Power or ammoprop_NeedTarget;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   254
                                          Count: 4;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   255
                                          NumPerTurn: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   256
                                          Timer: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   257
                                          AmmoType: amUFO);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   258
                                   Slot: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   259
                                   TimeAfterTurn: 3000),
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   260
                                  (Name: 'Shotgun';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   261
                                   Ammo: (Propz: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   262
                                          Count: AMMO_INFINITE;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   263
                                          NumPerTurn: 1;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   264
                                          Timer: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   265
                                          AmmoType: amShotgun);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   266
                                   Slot: 2;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   267
                                   TimeAfterTurn: 3000),
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   268
                                  (Name: 'Pneumatic pick';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   269
                                   Ammo: (Propz: ammoprop_ForwMsgs or ammoprop_AttackInFall or ammoprop_AttackInJump;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   270
                                          Count: 2;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   271
                                          NumPerTurn: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   272
                                          Timer: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   273
                                          AmmoType: amPickHammer);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   274
                                   Slot: 3;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   275
                                   TimeAfterTurn: 0),
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   276
                                  (Name: 'Skip turn';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   277
                                   Ammo: (Propz: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   278
                                          Count: AMMO_INFINITE;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   279
                                          NumPerTurn: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   280
                                          Timer: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   281
                                          AmmoType: amSkip);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   282
                                   Slot: 4;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   283
                                   TimeAfterTurn: 0),
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   284
                                  (Name: 'Rope';
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   285
                                   Ammo: (Propz: ammoprop_ForwMsgs or ammoprop_AttackInFall or ammoprop_AttackInJump;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   286
                                          Count: 5;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   287
                                          NumPerTurn: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   288
                                          Timer: 0;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   289
                                          AmmoType: amRope);
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   290
                                   Slot: 3;
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   291
                                   TimeAfterTurn: 0)
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   292
                                  );
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   293
                                  
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   294
      Resolutions: array[0..3] of String = (
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   295
                                           '640 480',
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   296
                                           '800 600',
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   297
                                           '1024 768',
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   298
                                           '1280 1024'
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   299
                                           );
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   300
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   301
implementation
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   302
30f2d1037d5d Add current sources.
unc0rr
parents:
diff changeset
   303
end.