Mercurial > mm7
annotate Monsters.h @ 1696:7d99124bccd8
Merge
author | Grumpy7 |
---|---|
date | Sun, 22 Sep 2013 10:51:08 +0200 |
parents | 33df22a5e376 |
children | 30c2b575d25c |
rev | line source |
---|---|
0 | 1 #pragma once |
2 | |
3 | |
4 | |
5 /* 334 */ | |
6 enum MONSTER_TYPE | |
7 { | |
8 MONSTER_DEVIL_1 = 0x16, | |
319 | 9 MONSTER_DEVIL_2 = 0x17, |
0 | 10 MONSTER_DEVIL_3 = 0x18, |
11 MONSTER_DRAGON_1 = 0x19, | |
319 | 12 MONSTER_DRAGON_2 = 0x1A, |
0 | 13 MONSTER_DRAGON_3 = 0x1B, |
14 MONSTER_ELEMENTAL_WATER_1 = 0x2E, | |
15 MONSTER_ELEMENTAL_WATER_3 = 0x30, | |
16 MONSTER_ELF_ARCHER_1 = 0x31, | |
17 MONSTER_ELF_ARCHER_3 = 0x33, | |
18 MONSTER_ELF_SPEARMAN_1 = 0x34, | |
19 MONSTER_ELF_SPEARMAN_3 = 0x36, | |
20 MONSTER_GHOST_1 = 0x46, | |
21 MONSTER_GHOST_3 = 0x48, | |
22 MONSTER_HARPY_1 = 0x55, | |
319 | 23 MONSTER_HARPY_2 = 0x56, |
0 | 24 MONSTER_HARPY_3 = 0x57, |
25 MONSTER_LICH_1 = 0x5B, | |
26 MONSTER_LICH_3 = 0x5D, | |
27 MONSTER_OOZE_1 = 0x70, | |
319 | 28 MONSTER_OOZE_2 = 0x71, |
0 | 29 MONSTER_OOZE_3 = 0x72, |
30 MONSTER_PEASANT_ELF_FEMALE_1_1 = 0x85, | |
31 MONSTER_PEASANT_ELF_MALE_3_3 = 0x96, | |
32 MONSTER_SKELETON_1 = 0xC7, | |
33 MONSTER_SKELETON_3 = 0xC9, | |
34 MONSTER_TITAN_1 = 0xD3, | |
35 MONSTER_TITAN_3 = 0xD5, | |
36 MONSTER_VAMPIRE_1 = 0xD9, | |
37 MONSTER_VAMPIRE_3 = 0xDB, | |
38 MONSTER_WIGHT_1 = 0xDF, | |
39 MONSTER_WIGHT_3 = 0xE1, | |
40 MONSTER_ZOMBIE_1 = 0xE5, | |
41 MONSTER_ZOMBIE_3 = 0xE7, | |
42 MONSTER_PEASANT_GOBLIN_MALE_3_3 = 0xF9, | |
319 | 43 MONSTER_TROLL_1 = 0xFA, |
44 MONSTER_TROLL_2 = 0xFB, | |
0 | 45 MONSTER_TROLL_3 = 0xFC, |
46 MONSTER_TREANT_1 = 0xFD, | |
47 MONSTER_TREANT_3 = 0xFF, | |
48 MONSTER_GHOUL_1 = 0x100, | |
49 MONSTER_GHOUL_3 = 0x102, | |
50 }; | |
51 | |
52 /* 335 */ | |
53 enum MONSTER_SPECIAL_ABILITY_TYPE | |
54 { | |
55 MONSTER_SPECIAL_ABILITY_NONE = 0x0, | |
56 MONSTER_SPECIAL_ABILITY_SHOT = 0x1, | |
57 MONSTER_SPECIAL_ABILITY_SUMMON = 0x2, | |
58 MONSTER_SPECIAL_ABILITY_EXPLODE = 0x3, | |
59 }; | |
60 | |
1456 | 61 enum MONSTER_MOVEMENT_TYPE |
62 { | |
63 MONSTER_MOVEMENT_TYPE_SHORT = 0x0, | |
64 MONSTER_MOVEMENT_TYPE_MEDIUM = 0x1, | |
65 MONSTER_MOVEMENT_TYPE_LONG = 0x2, | |
66 MONSTER_MOVEMENT_TYPE_GLOBAL = 0x3, | |
67 MONSTER_MOVEMENT_TYPE_FREE = 0x4, | |
68 MONSTER_MOVEMENT_TYPE_STAIONARY = 0x5, | |
69 }; | |
70 | |
71 | |
0 | 72 /* 336 */ |
73 enum MONSTER_SUPERTYPE | |
74 { | |
75 MONSTER_SUPERTYPE_UNDEAD = 0x1, | |
76 MONSTER_SUPERTYPE_KREEGAN = 0x2, | |
77 MONSTER_SUPERTYPE_DRAGON = 0x3, | |
78 MONSTER_SUPERTYPE_ELF = 0x4, | |
79 MONSTER_SUPERTYPE_WATER_ELEMENTAL = 0x5, | |
80 MONSTER_SUPERTYPE_TREANT = 0x6, | |
81 MONSTER_SUPERTYPE_TITAN = 0x7, | |
82 MONSTER_SUPERTYPE_8 = 0x8, | |
83 }; | |
84 | |
1695
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
85 enum SPECIAL_ATTACK_TYPE : unsigned __int8 |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
86 { |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
87 SPECIAL_ATTACK_NONE = 0, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
88 SPECIAL_ATTACK_CURSE = 1, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
89 SPECIAL_ATTACK_WEAK = 2, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
90 SPECIAL_ATTACK_SLEEP = 3, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
91 SPECIAL_ATTACK_DRUNK = 4, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
92 SPECIAL_ATTACK_INSANE = 5, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
93 SPECIAL_ATTACK_POISON1 = 6, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
94 SPECIAL_ATTACK_POISON2 = 7, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
95 SPECIAL_ATTACK_POISON3 = 8, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
96 SPECIAL_ATTACK_DISEASE1 = 9, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
97 SPECIAL_ATTACK_DISEASE2 = 10, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
98 SPECIAL_ATTACK_DISEASE3 = 11, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
99 SPECIAL_ATTACK_PARALYZED = 12, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
100 SPECIAL_ATTACK_UNCONSCIOUS = 13, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
101 SPECIAL_ATTACK_DEAD = 14, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
102 SPECIAL_ATTACK_PETRIFIED = 15, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
103 SPECIAL_ATTACK_ERADICATED = 16, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
104 SPECIAL_ATTACK_BREAK_ANY = 17, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
105 SPECIAL_ATTACK_BREAK_ARMOR = 18, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
106 SPECIAL_ATTACK_BREAK_WEAPON = 19, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
107 SPECIAL_ATTACK_STEAL = 20, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
108 SPECIAL_ATTACK_AGING = 21, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
109 SPECIAL_ATTACK_MANA_DRAIN = 22, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
110 SPECIAL_ATTACK_FEAR = 23, |
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
111 }; |
0 | 112 |
113 | |
114 /* 187 */ | |
115 #pragma pack(push, 1) | |
116 struct MonsterInfo | |
117 { | |
118 enum HostilityRadius: unsigned __int8 | |
119 { | |
120 Hostility_Friendly = 0, | |
121 Hostility_Close = 1, | |
122 Hostility_Short = 2, | |
123 Hostility_Medium = 3, | |
124 Hostility_Long = 4 | |
125 }; | |
126 | |
794 | 127 inline MonsterInfo(): |
128 pName(nullptr), pPictureName(nullptr) | |
129 {} | |
130 | |
0 | 131 char *pName; |
694 | 132 char *pPictureName; |
0 | 133 unsigned __int8 uLevel; |
134 unsigned __int8 uTreasureDropChance; | |
135 unsigned __int8 uTreasureDiceRolls; | |
136 unsigned __int8 uTreasureDiceSides; | |
137 unsigned __int8 uTreasureLevel; | |
138 unsigned __int8 uTreasureType; | |
139 unsigned __int8 uFlying; | |
140 unsigned __int8 uMovementType; | |
141 unsigned __int8 uAIType; | |
142 HostilityRadius uHostilityType; | |
143 char field_12; | |
1695
33df22a5e376
Player::ReceiveSpecialAttackEffect finishing cleanup, special attack type enum created
Grumpy7
parents:
1693
diff
changeset
|
144 SPECIAL_ATTACK_TYPE uSpecialAttackType; |
1693
861ede68187a
Player::_48DCF6 renamed to Player::ReceiveSpecialAttackEffect, some case reordering, fixing getting only disease3 instead of disease1 and ignoring disease2 and 3, uSpecialAttack to uSpecialAttackType, uSpecialAttackType to uSpecialAttackLevel
Grumpy7
parents:
1477
diff
changeset
|
145 unsigned __int8 uSpecialAttackLevel; |
0 | 146 unsigned __int8 uAttack1Type; |
147 unsigned __int8 uAttack1DamageDiceRolls; | |
148 unsigned __int8 uAttack1DamageDiceSides; | |
149 unsigned __int8 uAttack1DamageBonus; | |
150 unsigned __int8 uMissleAttack1Type; | |
151 unsigned __int8 uAttack2Chance; | |
152 unsigned __int8 uAttack2Type; | |
153 unsigned __int8 uAttack2DamageDiceRolls; | |
154 unsigned __int8 uAttack2DamageDiceSides; | |
155 unsigned __int8 uAttack2DamageBonus; | |
156 unsigned __int8 uMissleAttack2Type; | |
157 unsigned __int8 uSpell1UseChance; | |
158 unsigned __int8 uSpell1ID; | |
159 unsigned __int8 uSpell2UseChance; | |
160 unsigned __int8 uSpell2ID; | |
161 unsigned __int8 uResFire; | |
162 unsigned __int8 uResAir; | |
163 unsigned __int8 uResWater; | |
164 unsigned __int8 uResEarth; | |
165 unsigned __int8 uResMind; | |
166 unsigned __int8 uResSpirit; | |
167 unsigned __int8 uResBody; | |
168 unsigned __int8 uResLight; | |
169 unsigned __int8 uResDark; | |
170 unsigned __int8 uResPhysical; | |
735 | 171 unsigned __int8 uSpecialAbilityType; // 0 SPECIAL_ABILITY_TYPE_NONE |
172 // 1 SPECIAL_ABILITY_TYPE_SHOT | |
173 // 2 SPECIAL_ABILITY_TYPE_SUMMON | |
174 // 3 SPECIAL_ABILITY_TYPE_EXPLODE | |
0 | 175 unsigned __int8 uSpecialAbilityDamageDiceRolls; |
176 unsigned __int8 uSpecialAbilityDamageDiceSides; | |
177 unsigned __int8 uSpecialAbilityDamageDiceBonus; | |
178 unsigned __int8 uNumCharactersAttackedPerSpecialAbility; | |
179 char field_33; | |
180 unsigned __int16 uID; | |
181 unsigned __int16 bQuestMonster; | |
182 unsigned __int16 uSpellSkillAndMastery1; | |
183 unsigned __int16 uSpellSkillAndMastery2; | |
184 __int16 field_3C_some_special_attack; | |
185 __int16 field_3E; | |
186 unsigned int uHP; | |
187 unsigned int uAC; | |
188 unsigned int uExp; | |
189 unsigned int uBaseSpeed; | |
711 | 190 signed int uRecoveryTime; |
0 | 191 unsigned int uAttackPreference; |
192 }; | |
193 #pragma pack(pop) | |
194 | |
195 | |
237 | 196 |
0 | 197 /* 189 */ |
198 #pragma pack(push, 1) | |
199 struct MonsterStats | |
200 { | |
201 void Initialize(); | |
202 void InitializePlacements(); | |
751 | 203 signed int FindMonsterByTextureName(const char *Str2); |
0 | 204 |
205 static bool BelongsToSupertype(unsigned int uMonsterInfoID, enum MONSTER_SUPERTYPE eSupertype); | |
206 | |
237 | 207 MonsterInfo pInfos[265]; //0 - 5b18h |
694 | 208 char *pPlaceStrings[31]; //5B18h placement counts from 1 |
237 | 209 unsigned int uNumMonsters; //5B94h |
210 unsigned int uNumPlacements; //5B98h | |
0 | 211 int field_5B9C; |
212 }; | |
213 #pragma pack(pop) | |
214 | |
215 | |
216 | |
217 #pragma pack(push, 1) | |
1477
7ef4b64f6329
* LODFile::LoadBitmaps & LODFile::LoadIconsOrEvents are merged into LODFile::Load
Nomad
parents:
1456
diff
changeset
|
218 struct MonsterDesc_mm6 |
7ef4b64f6329
* LODFile::LoadBitmaps & LODFile::LoadIconsOrEvents are merged into LODFile::Load
Nomad
parents:
1456
diff
changeset
|
219 { |
7ef4b64f6329
* LODFile::LoadBitmaps & LODFile::LoadIconsOrEvents are merged into LODFile::Load
Nomad
parents:
1456
diff
changeset
|
220 unsigned __int16 uMonsterHeight; |
7ef4b64f6329
* LODFile::LoadBitmaps & LODFile::LoadIconsOrEvents are merged into LODFile::Load
Nomad
parents:
1456
diff
changeset
|
221 unsigned __int16 uMonsterRadius; |
7ef4b64f6329
* LODFile::LoadBitmaps & LODFile::LoadIconsOrEvents are merged into LODFile::Load
Nomad
parents:
1456
diff
changeset
|
222 unsigned __int16 uMovementSpeed; |
7ef4b64f6329
* LODFile::LoadBitmaps & LODFile::LoadIconsOrEvents are merged into LODFile::Load
Nomad
parents:
1456
diff
changeset
|
223 __int16 uToHitRadius; |
7ef4b64f6329
* LODFile::LoadBitmaps & LODFile::LoadIconsOrEvents are merged into LODFile::Load
Nomad
parents:
1456
diff
changeset
|
224 unsigned __int16 pSoundSampleIDs[4]; |
7ef4b64f6329
* LODFile::LoadBitmaps & LODFile::LoadIconsOrEvents are merged into LODFile::Load
Nomad
parents:
1456
diff
changeset
|
225 char pMonsterName[32]; |
7ef4b64f6329
* LODFile::LoadBitmaps & LODFile::LoadIconsOrEvents are merged into LODFile::Load
Nomad
parents:
1456
diff
changeset
|
226 char pSpriteNames[10][10]; |
7ef4b64f6329
* LODFile::LoadBitmaps & LODFile::LoadIconsOrEvents are merged into LODFile::Load
Nomad
parents:
1456
diff
changeset
|
227 }; |
7ef4b64f6329
* LODFile::LoadBitmaps & LODFile::LoadIconsOrEvents are merged into LODFile::Load
Nomad
parents:
1456
diff
changeset
|
228 |
0 | 229 struct MonsterDesc |
230 { | |
231 unsigned __int16 uMonsterHeight; | |
232 unsigned __int16 uMonsterRadius; | |
233 unsigned __int16 uMovementSpeed; | |
234 __int16 uToHitRadius; | |
235 unsigned int uTintColor; | |
236 unsigned __int16 pSoundSampleIDs[4]; | |
237 char pMonsterName[32]; | |
238 char pSpriteNames[10][10]; | |
239 }; | |
240 #pragma pack(pop) | |
241 | |
242 | |
243 #pragma pack(push, 1) | |
244 struct MonsterList | |
245 { | |
246 inline MonsterList(): //----- (00458429) | |
247 uNumMonsters(0), pMonsters(nullptr) | |
248 {} | |
751 | 249 signed __int16 GetMonsterIDByName(const char *pMonsterName); |
0 | 250 void ToFile(); |
1477
7ef4b64f6329
* LODFile::LoadBitmaps & LODFile::LoadIconsOrEvents are merged into LODFile::Load
Nomad
parents:
1456
diff
changeset
|
251 void FromFile(void *data_mm6, void *data_mm7, void *data_mm8); |
0 | 252 bool FromFileTxt(const char *Args); |
253 | |
751 | 254 signed int uNumMonsters; |
0 | 255 struct MonsterDesc *pMonsters; |
256 }; | |
257 #pragma pack(pop) | |
258 | |
259 | |
260 extern struct MonsterStats *pMonsterStats; | |
261 extern struct MonsterList *pMonsterList; |