equal
deleted
inserted
replaced
17 *) |
17 *) |
18 |
18 |
19 {$INCLUDE "options.inc"} |
19 {$INCLUDE "options.inc"} |
20 |
20 |
21 unit uGears; |
21 unit uGears; |
|
22 (* |
|
23 * This unit defines the behavior of gears. |
|
24 * |
|
25 * Gears are "things"/"objects" that may be visible to the player or not, |
|
26 * but always have an effect on the course of the game. |
|
27 * |
|
28 * E.g.: weapons, hedgehogs, etc. |
|
29 * |
|
30 * Note: The visual appearance of gears is defined in the unit "uGearsRender". |
|
31 * |
|
32 * Note: Gears that do not have an effect on the game but are just visual |
|
33 * effects are called "Visual Gears" and defined in the respective unit! |
|
34 *) |
22 interface |
35 interface |
23 uses SDLh, uConsts, uFloat, uTypes; |
36 uses SDLh, uConsts, uFloat, uTypes; |
24 |
37 |
25 procedure initModule; |
38 procedure initModule; |
26 procedure freeModule; |
39 procedure freeModule; |
63 procedure ShotgunShot(Gear: PGear); forward; |
76 procedure ShotgunShot(Gear: PGear); forward; |
64 procedure PickUp(HH, Gear: PGear); forward; |
77 procedure PickUp(HH, Gear: PGear); forward; |
65 procedure HHSetWeapon(HHGear: PGear); forward; |
78 procedure HHSetWeapon(HHGear: PGear); forward; |
66 procedure doStepCase(Gear: PGear); forward; |
79 procedure doStepCase(Gear: PGear); forward; |
67 |
80 |
|
81 // For better maintainability the step handlers of gears are stored in |
|
82 // separate files. |
|
83 // Note: step handlers of gears that are hedgehogs are in a different file |
|
84 // than the handlers for all other gears. |
68 {$INCLUDE "GSHandlers.inc"} |
85 {$INCLUDE "GSHandlers.inc"} |
69 {$INCLUDE "HHHandlers.inc"} |
86 {$INCLUDE "HHHandlers.inc"} |
70 |
87 |
71 const doStepHandlers: array[TGearType] of TGearStepProcedure = ( |
88 const doStepHandlers: array[TGearType] of TGearStepProcedure = ( |
72 @doStepBomb, |
89 @doStepBomb, |