diff options
Diffstat (limited to 'src/d_items.c')
-rw-r--r-- | src/d_items.c | 140 |
1 files changed, 140 insertions, 0 deletions
diff --git a/src/d_items.c b/src/d_items.c new file mode 100644 index 0000000..5adc28d --- /dev/null +++ b/src/d_items.c | |||
@@ -0,0 +1,140 @@ | |||
1 | /* Emacs style mode select -*- C++ -*- | ||
2 | *----------------------------------------------------------------------------- | ||
3 | * | ||
4 | * | ||
5 | * PrBoom: a Doom port merged with LxDoom and LSDLDoom | ||
6 | * based on BOOM, a modified and improved DOOM engine | ||
7 | * Copyright (C) 1999 by | ||
8 | * id Software, Chi Hoang, Lee Killough, Jim Flynn, Rand Phares, Ty Halderman | ||
9 | * Copyright (C) 1999-2000 by | ||
10 | * Jess Haas, Nicolas Kalkhof, Colin Phipps, Florian Schulze | ||
11 | * Copyright 2005, 2006 by | ||
12 | * Florian Schulze, Colin Phipps, Neil Stevens, Andrey Budko | ||
13 | * | ||
14 | * This program is free software; you can redistribute it and/or | ||
15 | * modify it under the terms of the GNU General Public License | ||
16 | * as published by the Free Software Foundation; either version 2 | ||
17 | * of the License, or (at your option) any later version. | ||
18 | * | ||
19 | * This program is distributed in the hope that it will be useful, | ||
20 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
21 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
22 | * GNU General Public License for more details. | ||
23 | * | ||
24 | * You should have received a copy of the GNU General Public License | ||
25 | * along with this program; if not, write to the Free Software | ||
26 | * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA | ||
27 | * 02111-1307, USA. | ||
28 | * | ||
29 | * DESCRIPTION: | ||
30 | * Something to do with weapon sprite frames. Don't ask me. | ||
31 | * | ||
32 | *----------------------------------------------------------------------------- | ||
33 | */ | ||
34 | |||
35 | // We are referring to sprite numbers. | ||
36 | #include "doomtype.h" | ||
37 | #include "info.h" | ||
38 | |||
39 | #ifdef __GNUG__ | ||
40 | #pragma implementation "d_items.h" | ||
41 | #endif | ||
42 | #include "d_items.h" | ||
43 | |||
44 | |||
45 | // | ||
46 | // PSPRITE ACTIONS for waepons. | ||
47 | // This struct controls the weapon animations. | ||
48 | // | ||
49 | // Each entry is: | ||
50 | // ammo/amunition type | ||
51 | // upstate | ||
52 | // downstate | ||
53 | // readystate | ||
54 | // atkstate, i.e. attack/fire/hit frame | ||
55 | // flashstate, muzzle flash | ||
56 | // | ||
57 | weaponinfo_t weaponinfo[NUMWEAPONS] = | ||
58 | { | ||
59 | { | ||
60 | // fist | ||
61 | am_noammo, | ||
62 | S_PUNCHUP, | ||
63 | S_PUNCHDOWN, | ||
64 | S_PUNCH, | ||
65 | S_PUNCH1, | ||
66 | S_NULL | ||
67 | }, | ||
68 | { | ||
69 | // pistol | ||
70 | am_clip, | ||
71 | S_PISTOLUP, | ||
72 | S_PISTOLDOWN, | ||
73 | S_PISTOL, | ||
74 | S_PISTOL1, | ||
75 | S_PISTOLFLASH | ||
76 | }, | ||
77 | { | ||
78 | // shotgun | ||
79 | am_shell, | ||
80 | S_SGUNUP, | ||
81 | S_SGUNDOWN, | ||
82 | S_SGUN, | ||
83 | S_SGUN1, | ||
84 | S_SGUNFLASH1 | ||
85 | }, | ||
86 | { | ||
87 | // chaingun | ||
88 | am_clip, | ||
89 | S_CHAINUP, | ||
90 | S_CHAINDOWN, | ||
91 | S_CHAIN, | ||
92 | S_CHAIN1, | ||
93 | S_CHAINFLASH1 | ||
94 | }, | ||
95 | { | ||
96 | // missile launcher | ||
97 | am_misl, | ||
98 | S_MISSILEUP, | ||
99 | S_MISSILEDOWN, | ||
100 | S_MISSILE, | ||
101 | S_MISSILE1, | ||
102 | S_MISSILEFLASH1 | ||
103 | }, | ||
104 | { | ||
105 | // plasma rifle | ||
106 | am_cell, | ||
107 | S_PLASMAUP, | ||
108 | S_PLASMADOWN, | ||
109 | S_PLASMA, | ||
110 | S_PLASMA1, | ||
111 | S_PLASMAFLASH1 | ||
112 | }, | ||
113 | { | ||
114 | // bfg 9000 | ||
115 | am_cell, | ||
116 | S_BFGUP, | ||
117 | S_BFGDOWN, | ||
118 | S_BFG, | ||
119 | S_BFG1, | ||
120 | S_BFGFLASH1 | ||
121 | }, | ||
122 | { | ||
123 | // chainsaw | ||
124 | am_noammo, | ||
125 | S_SAWUP, | ||
126 | S_SAWDOWN, | ||
127 | S_SAW, | ||
128 | S_SAW1, | ||
129 | S_NULL | ||
130 | }, | ||
131 | { | ||
132 | // super shotgun | ||
133 | am_shell, | ||
134 | S_DSGUNUP, | ||
135 | S_DSGUNDOWN, | ||
136 | S_DSGUN, | ||
137 | S_DSGUN1, | ||
138 | S_DSGUNFLASH1 | ||
139 | }, | ||
140 | }; | ||