summaryrefslogtreecommitdiff
path: root/src/monster_ego.hpp
blob: 1154c5377821bd1168df95bb511c6efa83d308c0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
#pragma once

#include "h-basic.h"
#include "monster_blow.hpp"

#include <array>

/**
 * Monster ego descriptors.
 */
struct monster_ego
{
	const char *name = nullptr;              /* Name */
	bool_ before = false;                    /* Display ego before or after */

	std::array<monster_blow, 4> blow { };    /* Up to four blows per round */
	byte blowm[4][2] = {
		{ 0, 0 },
		{ 0, 0 },
		{ 0, 0 },
		{ 0, 0 }
	};

	s16b hdice = 0;                          /* Creatures hit dice count */
	s16b hside = 0;                          /* Creatures hit dice sides */

	s16b ac = 0;                             /* Armour Class */

	s16b sleep = 0;                          /* Inactive counter (base) */
	s16b aaf = 0;                            /* Area affect radius (1-100) */
	s16b speed = 0;                          /* Speed (normally 110) */

	s32b mexp = 0;                           /* Exp value for kill */

	s32b weight = 0;                         /* Weight of the monster */

	byte freq_inate = 0;                     /* Inate spell frequency */
	byte freq_spell = 0;                     /* Other spell frequency */

	/* Ego flags */
	u32b flags1 = 0;
	u32b flags2 = 0;
	u32b flags3 = 0;
	u32b flags7 = 0;
	u32b flags8 = 0;
	u32b flags9 = 0;
	u32b hflags1 = 0;
	u32b hflags2 = 0;
	u32b hflags3 = 0;
	u32b hflags7 = 0;
	u32b hflags8 = 0;
	u32b hflags9 = 0;

	/* Monster flags */
	u32b mflags1 = 0;
	u32b mflags2 = 0;
	u32b mflags3 = 0;
	u32b mflags4 = 0;
	u32b mflags5 = 0;
	u32b mflags6 = 0;
	u32b mflags7 = 0;
	u32b mflags8 = 0;
	u32b mflags9 = 0;

	/* Negative Flags, to be removed from the monster flags */
	u32b nflags1 = 0;
	u32b nflags2 = 0;
	u32b nflags3 = 0;
	u32b nflags4 = 0;
	u32b nflags5 = 0;
	u32b nflags6 = 0;
	u32b nflags7 = 0;
	u32b nflags8 = 0;
	u32b nflags9 = 0;

	s16b level = 0;                          /* Level of creature */
	s16b rarity = 0;                         /* Rarity of creature */

	byte d_attr = 0;                         /* Default monster attribute */
	char d_char = '\0';                      /* Default monster character */

	byte g_attr = 0;                         /* Overlay graphic attribute */
	char g_char = '\0';                      /* Overlay graphic character */

	char r_char[5] = { '\0' };               /* Monster race allowed */
	char nr_char[5] = { '\0' };              /* Monster race not allowed */
};