DEADSOFTWARE

game: switch textures in more abstract way
[flatwaifu.git] / src / monster.h
1 /*
2 Copyright (C) Prikol Software 1996-1997
3 Copyright (C) Aleksey Volynskov 1996-1997
5 This file is part of the Doom2D:Rembo project.
7 Doom2D:Rembo is free software; you can redistribute it and/or modify
8 it under the terms of the GNU General Public License version 2 as
9 published by the Free Software Foundation.
11 Doom2D:Rembo is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with this program; if not, see <http://www.gnu.org/licenses/> or
18 write to the Free Software Foundation, Inc.,
19 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
20 */
22 #ifndef MONSTER_H_INLUDED
23 #define MONSTER_H_INLUDED
25 #include "glob.h"
26 #include "view.h" // obj_t
28 #define MAXMN 200
30 enum {
31 MN_NONE, MN_DEMON, MN_IMP, MN_ZOMBY, MN_SERG, MN_CYBER, MN_CGUN,
32 MN_BARON, MN_KNIGHT, MN_CACO, MN_SOUL, MN_PAIN, MN_SPIDER, MN_BSP,
33 MN_MANCUB, MN_SKEL, MN_VILE, MN_FISH, MN_BARREL, MN_ROBO, MN_MAN,
34 MN__LAST,
35 MN_PL_DEAD = 100,
36 MN_PL_MESS
37 };
39 #define MN_TN (MN__LAST-MN_DEMON)
41 typedef struct {
42 obj_t o;
43 byte t, d, st, ftime;
44 int fobj;
45 int s;
46 char *ap;
47 int aim, life, pain, ac, tx, ty, ammo;
48 short atm;
49 } mn_t;
51 extern byte nomon;
52 extern int hit_xv, hit_yv;
53 extern mn_t mn[MAXMN];
55 void MN_savegame (FILE *h);
56 void MN_loadgame (FILE *h);
57 void MN_alloc (void);
58 void MN_init (void);
59 int MN_spawn (int x, int y, byte d, int t);
60 int MN_spawn_deadpl (obj_t *o, byte c, int t);
61 int Z_getobjpos (int i, obj_t *o);
62 void MN_act (void);
63 void MN_mark (void);
64 int MN_hit (int n, int d, int o, int t);
65 int Z_gunhit (int x, int y, int o, int xv, int yv);
66 int Z_hit (obj_t *o, int d, int own, int t);
67 void MN_killedp (void);
68 void Z_explode (int x, int y, int rad, int own);
69 void Z_bfg9000 (int x, int y, int own);
70 int Z_chktrap (int t, int d, int o, int ht);
71 void Z_teleobj (int o, int x, int y);
72 void MN_warning (int l, int t, int r, int b);
74 #endif /* MONSTER_H_INLUDED */