hedgewars/uTypes.pas
author nemo
Sun, 21 Nov 2010 01:26:31 -0500
changeset 4392 95e27e12d0e9
parent 4379 6cd6b77df8b8
child 4420 6be946bcd17a
permissions -rw-r--r--
Fix koda's esc key binding so leaving rooms works correctly with it
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
4357
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
     1
{$INCLUDE "options.inc"}
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
     2
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
     3
unit uTypes;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
     4
interface
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
     5
4361
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
     6
uses SDLh, uFloat, GLunit, uConsts, Math;
4357
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
     7
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
     8
type
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
     9
    HwColor4f = record
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    10
        r, g, b, a: byte
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    11
        end;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    12
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    13
    TGameState = (gsLandGen, gsStart, gsGame, gsChat, gsConfirm, gsExit);
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    14
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    15
    TGameType = (gmtLocal, gmtDemo, gmtNet, gmtSave, gmtLandPreview, gmtSyntax);
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    16
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    17
    TPathType = (ptNone, ptData, ptGraphics, ptThemes, ptCurrTheme, ptTeams, ptMaps,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    18
            ptMapCurrent, ptDemos, ptSounds, ptGraves, ptFonts, ptForts,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    19
            ptLocale, ptAmmoMenu, ptHedgehog, ptVoices, ptHats, ptFlags, ptMissionMaps);
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    20
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    21
    TSprite = (sprWater, sprCloud, sprBomb, sprBigDigit, sprFrame,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    22
            sprLag, sprArrow, sprBazookaShell, sprTargetP, sprBee,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    23
            sprSmokeTrace, sprRopeHook, sprExplosion50, sprMineOff,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    24
            sprMineOn, sprMineDead, sprCase, sprFAid, sprDynamite, sprPower,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    25
            sprClusterBomb, sprClusterParticle, sprFlame, sprHorizont,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    26
            sprHorizontL, sprHorizontR, sprSky, sprSkyL,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    27
            sprSkyR, sprAMBorderHorizontal, sprAMBorderVertical, sprAMSlot, sprAMAmmos,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    28
            sprAMSlotKeys, sprAMCorners, sprFinger, sprAirBomb,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    29
            sprAirplane, sprAmAirplane, sprAmGirder, sprHHTelepMask,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    30
            sprSwitch, sprParachute, sprTarget, sprRopeNode,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    31
            sprQuestion, sprPowerBar, sprWindBar, sprWindL, sprWindR,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    32
            sprFlake, sprHandRope, sprHandBazooka, sprHandShotgun,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    33
            sprHandDEagle, sprHandAirAttack, sprHandBaseball, sprPHammer,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    34
            sprHandBlowTorch, sprBlowTorch, sprTeleport, sprHHDeath,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    35
            sprShotgun, sprDEagle, sprHHIdle, sprMortar, sprTurnsLeft,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    36
            sprKamikaze, sprWhip, sprKowtow, sprSad, sprWave,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    37
            sprHurrah, sprLemonade, sprShrug, sprJuggle, sprExplPart, sprExplPart2,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    38
            sprCakeWalk, sprCakeDown, sprAMAmmosBW, sprWatermelon,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    39
            sprEvilTrace, sprHellishBomb, sprSeduction, sprDress,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    40
            sprCensored, sprDrill, sprHandDrill, sprHandBallgun, sprBalls,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    41
            sprPlane, sprHandPlane, sprUtility, sprInvulnerable, sprVampiric, sprGirder,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    42
            sprSpeechCorner, sprSpeechEdge, sprSpeechTail,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    43
            sprThoughtCorner, sprThoughtEdge, sprThoughtTail,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    44
            sprShoutCorner, sprShoutEdge, sprShoutTail,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    45
            sprSniperRifle, sprBubbles, sprJetpack, sprHealth, sprHandMolotov, sprMolotov,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    46
            sprSmoke, sprSmokeWhite, sprShell, sprDust, sprExplosives, sprExplosivesRoll,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    47
            sprAmTeleport, sprSplash, sprDroplet, sprBirdy, sprHandCake, sprHandConstruction,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    48
            sprHandGrenade, sprHandMelon, sprHandMortar, sprHandSkip, sprHandCluster,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    49
            sprHandDynamite, sprHandHellish, sprHandMine, sprHandSeduction, sprHandVamp,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    50
            sprBigExplosion, sprSmokeRing, sprBeeTrace, sprEgg, sprTargetBee, sprHandBee,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    51
            sprFeather, sprPiano, sprHandSineGun, sprPortalGun, sprPortal,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    52
            sprCheese, sprHandCheese, sprHandFlamethrower, sprChunk, sprNote,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    53
            sprSMineOff, sprSMineOn, sprHandSMine, sprHammer,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    54
            sprHandResurrector, sprCross, sprAirDrill, sprNapalmBomb,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    55
            sprBulletHit
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    56
            );
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    57
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    58
    // Gears that interact with other Gears and/or Land
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    59
    TGearType = (gtBomb, gtHedgehog, gtShell, gtGrave, gtBee, // 4
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    60
            gtShotgunShot, gtPickHammer, gtRope, gtMine, gtCase, // 9
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    61
            gtDEagleShot, gtDynamite, gtClusterBomb, gtCluster, gtShover, // 14
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    62
            gtFlame, gtFirePunch, gtATStartGame, gtATSmoothWindCh, // 18
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    63
            gtATFinishGame, gtParachute, gtAirAttack, gtAirBomb, gtBlowTorch, // 23
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    64
            gtGirder, gtTeleport, gtSwitcher, gtTarget, gtMortar, // 28
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    65
            gtWhip, gtKamikaze, gtCake, gtSeduction, gtWatermelon, gtMelonPiece, // 34
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    66
            gtHellishBomb, gtWaterUp, gtDrill, gtBallGun, gtBall, gtRCPlane, // 40
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    67
            gtSniperRifleShot, gtJetpack, gtMolotov, gtExplosives, gtBirdy, // 45
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    68
            gtEgg, gtPortal, gtPiano, gtGasBomb, gtSineGunShot, gtFlamethrower, // 51
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    69
            gtSMine, gtPoisonCloud, gtHammer, gtHammerHit, gtResurrector, // 56
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    70
            gtNapalmBomb); // 57
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    71
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    72
    // Gears that are _only_ of visual nature (e.g. background stuff, visual effects, speechbubbles, etc.)
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    73
    TVisualGearType = (vgtFlake, vgtCloud, vgtExplPart, vgtExplPart2, vgtFire,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    74
            vgtSmallDamageTag, vgtTeamHealthSorter, vgtSpeechBubble, vgtBubble,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    75
            vgtSteam, vgtAmmo, vgtSmoke, vgtSmokeWhite, vgtHealth, vgtShell,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    76
            vgtDust, vgtSplash, vgtDroplet, vgtSmokeRing, vgtBeeTrace, vgtEgg,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    77
            vgtFeather, vgtHealthTag, vgtSmokeTrace, vgtEvilTrace, vgtExplosion,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    78
            vgtBigExplosion, vgtChunk, vgtNote, vgtLineTrail,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    79
            vgtBulletHit);
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    80
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    81
    TGearsType = set of TGearType;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    82
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    83
    TDamageSource = (dsUnknown, dsFall, dsBullet, dsExplosion, dsShove, dsPoison);
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    84
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    85
    TSound = (sndNone,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    86
            sndGrenadeImpact, sndExplosion, sndThrowPowerUp, sndThrowRelease,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    87
            sndSplash, sndShotgunReload, sndShotgunFire, sndGraveImpact,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    88
            sndMineTick, sndPickhammer, sndGun, sndBee, sndJump1, sndJump2,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    89
            sndJump3, sndYesSir, sndLaugh, sndIllGetYou, sndIncoming,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    90
            sndMissed, sndStupid, sndFirstBlood, sndBoring, sndByeBye,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    91
            sndSameTeam, sndNutter, sndReinforce, sndTraitor, sndRegret,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    92
            sndEnemyDown, sndCoward, sndHurry, sndWatchIt, sndKamikaze,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    93
            sndCake, sndOw1, sndOw2, sndOw3, sndOw4, sndFirePunch1, sndFirePunch2,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    94
            sndFirePunch3, sndFirePunch4, sndFirePunch5, sndFirePunch6,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    95
            sndMelon, sndHellish, sndYoohoo, sndRCPlane, sndWhipCrack,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    96
            sndRideOfTheValkyries, sndDenied, sndPlaced, sndBaseballBat,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    97
            sndVaporize, sndWarp, sndSuddenDeath, sndMortar, sndShutter,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    98
            sndHomerun, sndMolotov, sndCover, sndUhOh, sndOops,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
    99
            sndNooo, sndHello, sndRopeShot, sndRopeAttach, sndRopeRelease,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   100
            sndSwitchHog, sndVictory, sndSniperReload, sndSteps, sndLowGravity,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   101
            sndHellishImpact1, sndHellishImpact2, sndHellishImpact3, sndHellishImpact4,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   102
            sndMelonImpact, sndDroplet1, sndDroplet2, sndDroplet3, sndEggBreak, sndDrillRocket,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   103
            sndPoisonCough, sndPoisonMoan, sndBirdyLay, sndWhistle, sndBeeWater,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   104
            sndPiano0, sndPiano1, sndPiano2, sndPiano3, sndPiano4, sndPiano5, sndPiano6, sndPiano7, sndPiano8,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   105
            sndSkip, sndSineGun, sndOoff1, sndOoff2, sndOoff3, sndWhack,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   106
            sndComeonthen, sndParachute, sndBump, sndResurrector);
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   107
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   108
    TAmmoType  = (amNothing, amGrenade, amClusterBomb, amBazooka, amBee, amShotgun, amPickHammer, // 6
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   109
            amSkip, amRope, amMine, amDEagle, amDynamite, amFirePunch, amWhip, // 13
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   110
            amBaseballBat, amParachute, amAirAttack, amMineStrike, amBlowTorch, // 18
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   111
            amGirder, amTeleport, amSwitch, amMortar, amKamikaze, amCake, // 24
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   112
            amSeduction, amWatermelon, amHellishBomb, amNapalm, amDrill, amBallgun, // 30
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   113
            amRCPlane, amLowGravity, amExtraDamage, amInvulnerable, amExtraTime, // 35
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   114
            amLaserSight, amVampiric, amSniperRifle, amJetpack, amMolotov, amBirdy, amPortalGun, // 42
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   115
            amPiano, amGasBomb, amSineGun, amFlamethrower, amSMine, amHammer, // 48
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   116
            amResurrector, amDrillStrike);
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   117
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   118
    TCrateType = (HealthCrate, AmmoCrate, UtilityCrate);
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   119
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   120
    THWFont = (fnt16, fntBig, fntSmall {$IFNDEF IPHONEOS}, CJKfnt16, CJKfntBig, CJKfntSmall{$ENDIF});
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   121
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   122
    TCapGroup = (capgrpGameState, capgrpAmmoinfo, capgrpVolume,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   123
            capgrpMessage, capgrpAmmostate);
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   124
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   125
    TStatInfoType = (siGameResult, siMaxStepDamage, siMaxStepKills, siKilledHHs,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   126
            siClanHealth, siTeamStats, siPlayerKills, siMaxTeamDamage,
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   127
            siMaxTeamKills, siMaxTurnSkips );
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   128
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   129
    TWave = (waveRollup, waveSad, waveWave, waveHurrah, waveLemonade, waveShrug, waveJuggle);
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   130
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   131
    THHFont = record
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   132
            Handle: PTTF_Font;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   133
            Height: LongInt;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   134
            style: LongInt;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   135
            Name: string[21];
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   136
            end;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   137
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   138
    PAmmo = ^TAmmo;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   139
    TAmmo = record
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   140
            Propz: LongWord;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   141
            Count: LongWord;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   142
(* Using for place hedgehogs mode, but for any other situation where the initial count would be needed I guess.
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   143
For example, say, a mode where the weaponset is reset each turn, or on sudden death *)
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   144
            NumPerTurn: LongWord;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   145
            Timer: LongWord;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   146
            Pos: LongWord;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   147
            AmmoType: TAmmoType;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   148
            AttackVoice: TSound;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   149
            end;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   150
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   151
    TVertex2f = record
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   152
        X, Y: GLfloat;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   153
        end;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   154
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   155
    TVertex2i = record
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   156
        X, Y: GLint;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   157
        end;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   158
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   159
    PTexture = ^TTexture;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   160
    TTexture = record
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   161
            id: GLuint;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   162
            w, h, scale: LongInt;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   163
            rx, ry: GLfloat;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   164
            priority: GLfloat;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   165
            vb, tb: array [0..3] of TVertex2f;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   166
            PrevTexture, NextTexture: PTexture;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   167
            end;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   168
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   169
    THogEffect = (heInvulnerable, heResurrectable, hePoisoned, heResurrected);
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   170
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   171
    TScreenFade = (sfNone, sfInit, sfToBlack, sfFromBlack, sfToWhite, sfFromWhite);
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   172
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   173
    PGear = ^TGear;
4361
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   174
    PHedgehog = ^THedgehog;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   175
    PTeam     = ^TTeam;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   176
    PClan     = ^TClan;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   177
4357
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   178
    TGearStepProcedure = procedure (Gear: PGear);
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   179
    TGear = record
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   180
            NextGear, PrevGear: PGear;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   181
            Active: Boolean;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   182
            AdvBounce: Longword;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   183
            Invulnerable: Boolean;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   184
            RenderTimer: Boolean;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   185
            AmmoType : TAmmoType;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   186
            State : Longword;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   187
            X : hwFloat;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   188
            Y : hwFloat;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   189
            dX: hwFloat;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   190
            dY: hwFloat;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   191
            Kind: TGearType;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   192
            Pos: Longword;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   193
            doStep: TGearStepProcedure;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   194
            Radius: LongInt;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   195
            Angle, Power : Longword;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   196
            DirAngle: real;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   197
            Timer : LongWord;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   198
            Elasticity: hwFloat;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   199
            Friction  : hwFloat;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   200
            Message, MsgParam : Longword;
4361
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   201
            Hedgehog: PHedgehog;
4357
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   202
            Health, Damage, Karma: LongInt;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   203
            CollisionIndex: LongInt;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   204
            Tag: LongInt;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   205
            Tex: PTexture;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   206
            Z: Longword;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   207
            IntersectGear: PGear;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   208
            FlightTime: Longword;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   209
            uid: Longword;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   210
            ImpactSound: TSound; // first sound, others have to be after it in the sounds def.
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   211
            nImpactSounds: Word; // count of ImpactSounds
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   212
            SoundChannel: LongInt;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   213
            PortalCounter: LongWord  // Hopefully temporary, but avoids infinite portal loops in a guaranteed fashion.
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   214
        end;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   215
    TPGearArray = Array of PGear;
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   216
4361
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   217
    PVisualGear = ^TVisualGear;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   218
    TVGearStepProcedure = procedure (Gear: PVisualGear; Steps: Longword);
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   219
    TVisualGear = record
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   220
        NextGear, PrevGear: PVisualGear;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   221
        Frame,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   222
        FrameTicks: Longword;
4379
6cd6b77df8b8 No need for Extended data type just to draw some visual gears. It's a shame we have Math unit dependency
unC0Rr
parents: 4367
diff changeset
   223
        X : real;
6cd6b77df8b8 No need for Extended data type just to draw some visual gears. It's a shame we have Math unit dependency
unC0Rr
parents: 4367
diff changeset
   224
        Y : real;
6cd6b77df8b8 No need for Extended data type just to draw some visual gears. It's a shame we have Math unit dependency
unC0Rr
parents: 4367
diff changeset
   225
        dX: real;
6cd6b77df8b8 No need for Extended data type just to draw some visual gears. It's a shame we have Math unit dependency
unC0Rr
parents: 4367
diff changeset
   226
        dY: real;
6cd6b77df8b8 No need for Extended data type just to draw some visual gears. It's a shame we have Math unit dependency
unC0Rr
parents: 4367
diff changeset
   227
        tdX: real;
6cd6b77df8b8 No need for Extended data type just to draw some visual gears. It's a shame we have Math unit dependency
unC0Rr
parents: 4367
diff changeset
   228
        tdY: real;
4361
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   229
        State : Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   230
        Timer: Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   231
        Angle, dAngle: real;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   232
        Kind: TVisualGearType;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   233
        doStep: TVGearStepProcedure;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   234
        Tex: PTexture;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   235
        alpha, scale: GLfloat;
4365
4f2b1a152979 Remove ugly PHedgehog(Gear^.Hedgehog) cast
unc0rr
parents: 4361
diff changeset
   236
        Hedgehog: PHedgehog;
4361
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   237
        Text: shortstring;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   238
        Tint: Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   239
        end;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   240
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   241
    TStatistics = record
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   242
        DamageRecv,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   243
        DamageGiven: Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   244
        StepDamageRecv,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   245
        StepDamageGiven,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   246
        StepKills: Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   247
        MaxStepDamageRecv,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   248
        MaxStepDamageGiven,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   249
        MaxStepKills: Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   250
        FinishedTurns: Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   251
        end;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   252
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   253
    TTeamStats = record
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   254
        Kills : Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   255
        AIKills : Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   256
        TeamKills : Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   257
        TurnSkips : Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   258
        TeamDamage : Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   259
        end;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   260
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   261
    TBinds = array[0..cKeyMaxIndex] of shortstring;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   262
    TKeyboardState = array[0..cKeyMaxIndex] of Byte;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   263
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   264
    PVoicepack = ^TVoicepack;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   265
    TVoicepack = record
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   266
        name: shortstring;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   267
        chunks: array [TSound] of PMixChunk;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   268
        end;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   269
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   270
    PHHAmmo = ^THHAmmo;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   271
    THHAmmo = array[0..cMaxSlotIndex, 0..cMaxSlotAmmoIndex] of TAmmo;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   272
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   273
    THedgehog = record
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   274
            Name: string[MAXNAMELEN];
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   275
            Gear: PGear;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   276
            SpeechGear: PVisualGear;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   277
            NameTagTex,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   278
            HealthTagTex,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   279
            HatTex: PTexture;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   280
            Ammo: PHHAmmo;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   281
            CurAmmoType: TAmmoType;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   282
            AmmoStore: Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   283
            Team: PTeam;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   284
            MultiShootAttacks: Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   285
            visStepPos: LongWord;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   286
            BotLevel  : Byte; // 0 - Human player
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   287
            HatVisibility: GLfloat;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   288
            stats: TStatistics;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   289
            Hat: shortstring;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   290
            InitialHealth: LongInt; // used for gfResetHealth
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   291
            King: boolean;  // Flag for a bunch of hedgehog attributes
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   292
            Unplaced: boolean;  // Flag for hog placing mode
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   293
            Timer: Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   294
            Effects: Array[THogEffect] of boolean;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   295
            end;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   296
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   297
    TTeam = record
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   298
            Clan: PClan;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   299
            TeamName: string[MAXNAMELEN];
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   300
            ExtDriven: boolean;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   301
            Binds: TBinds;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   302
            Hedgehogs: array[0..cMaxHHIndex] of THedgehog;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   303
            CurrHedgehog: LongWord;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   304
            NameTagTex: PTexture;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   305
            CrosshairTex,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   306
            GraveTex,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   307
            HealthTex,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   308
            AIKillsTex,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   309
            FlagTex: PTexture;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   310
            Flag: shortstring;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   311
            GraveName: shortstring;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   312
            FortName: shortstring;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   313
            TeamHealth: LongInt;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   314
            TeamHealthBarWidth,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   315
            NewTeamHealthBarWidth: LongInt;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   316
            DrawHealthY: LongInt;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   317
            AttackBar: LongWord;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   318
            HedgehogsNumber: Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   319
            hasGone: boolean;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   320
            voicepack: PVoicepack;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   321
            PlayerHash: shortstring;   // md5 hash of player name. For temporary enabling of hats as thank you. Hashed for privacy of players
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   322
            stats: TTeamStats;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   323
            end;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   324
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   325
    TClan = record
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   326
            Color: Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   327
            Teams: array[0..Pred(cMaxTeams)] of PTeam;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   328
            TeamsNumber: Longword;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   329
            CurrTeam: LongWord;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   330
            ClanHealth: LongInt;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   331
            ClanIndex: LongInt;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   332
            TurnNumber: LongWord;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   333
            end;
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   334
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   335
     TAmmoStrId = (sidNothing, sidGrenade, sidClusterBomb, sidBazooka, sidBee, sidShotgun,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   336
            sidPickHammer, sidSkip, sidRope, sidMine, sidDEagle,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   337
            sidDynamite, sidBaseballBat, sidFirePunch, sidSeconds,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   338
            sidParachute, sidAirAttack, sidMineStrike, sidBlowTorch,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   339
            sidGirder, sidTeleport, sidSwitch, sidMortar, sidWhip,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   340
            sidKamikaze, sidCake, sidSeduction, sidWatermelon,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   341
            sidHellishBomb, sidDrill, sidBallgun, sidNapalm, sidRCPlane,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   342
            sidLowGravity, sidExtraDamage, sidInvulnerable, sidExtraTime,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   343
            sidLaserSight, sidVampiric, sidSniperRifle, sidJetpack,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   344
            sidMolotov, sidBirdy, sidPortalGun, sidPiano, sidGasBomb, sidSineGun, sidFlamethrower,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   345
            sidSMine, sidHammer, sidResurrector, sidDrillStrike);
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   346
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   347
    TMsgStrId = (sidStartFight, sidDraw, sidWinner, sidVolume, sidPaused,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   348
            sidConfirm, sidSuddenDeath, sidRemaining, sidFuel, sidSync,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   349
            sidNoEndTurn, sidNotYetAvailable, sidRoundSD, sidRoundsSD, sidReady);
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   350
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   351
    TEventId = (eidDied, eidDrowned, eidRoundStart, eidRoundWin, eidRoundDraw,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   352
            eidNewHealthPack, eidNewAmmoPack, eidNewUtilityPack, eidTurnSkipped, eidHurtSelf,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   353
            eidHomerun, eidGone);
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   354
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   355
    TGoalStrId = (gidCaption, gidSubCaption, gidForts, gidLowGravity, gidInvulnerable,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   356
            gidVampiric, gidKarma, gidKing, gidPlaceHog, gidArtillery,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   357
            gidSolidLand, gidSharedAmmo, gidMineTimer, gidNoMineTimer, gidRandomMineTimer,
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   358
            gidDamageModifier, gidResetHealth, gidAISurvival, gidInfAttack, gidResetWeps, gidPerHogAmmo);
64ea345ab655 Move variables from uConsts to uVariables
unc0rr
parents: 4357
diff changeset
   359
4367
f4a0ec067601 uLand isn't that important to them
unc0rr
parents: 4365
diff changeset
   360
    TLandArray = packed array of array of LongWord;
f4a0ec067601 uLand isn't that important to them
unc0rr
parents: 4365
diff changeset
   361
    TCollisionArray = packed array of array of Word;
f4a0ec067601 uLand isn't that important to them
unc0rr
parents: 4365
diff changeset
   362
    TPreview  = packed array[0..127, 0..31] of byte;
f4a0ec067601 uLand isn't that important to them
unc0rr
parents: 4365
diff changeset
   363
    TDirtyTag = packed array of array of byte;
f4a0ec067601 uLand isn't that important to them
unc0rr
parents: 4365
diff changeset
   364
f4a0ec067601 uLand isn't that important to them
unc0rr
parents: 4365
diff changeset
   365
4357
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   366
implementation
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   367
a1fcfc341a52 Introduce unit uTypes in order to remove some cyclic unit dependencies
unC0Rr
parents:
diff changeset
   368
end.