-
Notifications
You must be signed in to change notification settings - Fork 0
/
BLOOD.HXX
209 lines (175 loc) · 5.47 KB
/
BLOOD.HXX
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
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
/* ========================================================================
Copyright (c) 1990,1996 Synergistic Software
All Rights Reserved
========================================================================
Filename: BLOOD.HXX - Collection of Bloodline Abilities for characters
Author: Gary Powell
======================================================================== */
#ifndef _BLOOD_HXX
#define _BLOOD_HXX
/* ------------------------------------------------------------------------
Sub Includes
------------------------------------------------------------------------ */
#include <stdio.h>
#if !defined(_TYPEDEFS_H)
#include "typedefs.h"
#endif
#if !defined(_DICE_H)
#include "dice.h"
#endif
//#include "gamestr.h"
#if !defined(_STRENUM_H)
#include "strenum.h"
#endif
/* ------------------------------------------------------------------------
Defines and Compile Flags
------------------------------------------------------------------------ */
/* ------------------------------------------------------------------------
Enums
------------------------------------------------------------------------ */
/* ------------------------------------------------------------------------
Typedefs
------------------------------------------------------------------------ */
// Note: Order is important because this array is autofilled.
// If you change this structure be sure to change RAbility.c
class BLOODLINE_STRENGTH_INFO {
public:
typedef enum {
TAINTED = 0,
MINOR,
MAJOR,
GREAT,
// This is it, don't add more!
MAX_BLOOD_STRENGTH
} TYPE;
class BLOODLINE_STRENGTH_DATA {
public:
GAME_STRING Name;
DICE Score; // Unknown usefulness of this value.
};
static char const * const mfGetName(const TYPE);
static const DICE *mfGetScore(const TYPE);
private:
static BLOODLINE_STRENGTH_DATA fpBloodlineStrengthInfo[];
};
typedef BLOODLINE_STRENGTH_INFO *PTR_BLOODLINE_STRENGTH_INFO;
// Note: This enum type is used as an index into several arrays
// which track Bloodline Derivation information. Don't re-order it!
// This structure is to hold information about the bloodline
// derivations needed while the game is in progress.
class BLOODLINE_DERIVATION_INFO {
public:
typedef enum {
ANDUIRAS = 0,
REYNIR,
BRENNA,
BASAIA,
MASELA,
VORYNN,
AZRAI,
// This is it, don't add more!
MAX_DERIVATION
} TYPE;
static char const * const mfGetName(const TYPE);
private:
static GAME_STRING fpBloodlineDerivationInfo[];
};
typedef BLOODLINE_DERIVATION_INFO *PTR_BLOODLINE_DERIVATION_INFO;
// Note: This enum type is used as an index into several arrays
// which track Blood Ability information. Don't re-order it!
// This structure is to hold information about the Blood Abilities
// derivations needed while the game is in progress.
class BLOOD_ABILITY_INFO {
public:
typedef enum {
ALERTNESS = 0,
ALTER_APPEARANCE,
ANIMAL_AFFINITY,
BATTLEWISE,
BLOOD_HISTORY,
BLOODMARK,
CHARACTER_READING,
COURAGE,
DETECT_LIE,
DETECT_ILLUSION,
DIRECTION_SENSE,
DIVINE_AURA,
DEVINE_WRATH,
ELEMENTAL_CONTROL,
ENHANCED_SENSE,
FEAR,
HEALING_MINOR,
HEALING_MAJOR,
HEALING_GREAT,
HEIGHTENED_ABILITY,
IRON_WILL,
PERSUASION,
POISON_SENSE,
PROTECTION_FROM_EVIL,
REGENERATION,
RESISTANCE,
SHADOW_FORM,
TOUCH_OF_DECAY,
TRAVEL,
UNREADABLE_THOUGHTS,
// Don't add to this list, that's all there are.
MAX_ABILITIES
} BLOOD_ABILITY;
static char const * const mfGetName(const BLOOD_ABILITY);
private:
static GAME_STRING fpBloodAbilityInfo[];
};
typedef BLOOD_ABILITY_INFO *PTR_BLOOD_ABILITY_INFO;
// Every blooded player gets a list of abilities, this is
// how its stored.
typedef SHORT HDL_BLOOD_ABILITY;
class BLOOD_ABILITIES_LIST {
public:
HDL_BLOOD_ABILITY next;
BLOOD_ABILITY_INFO::BLOOD_ABILITY BloodAbility;
};
typedef BLOOD_ABILITIES_LIST *PTR_BLOOD_ABILITIES_LIST;
// This structure is used in the game to track
// the Bloodline information.
class PLAYER_BLOOD_INFO {
public:
BLOODLINE_STRENGTH_INFO::TYPE Type;
BLOODLINE_DERIVATION_INFO::TYPE DerivationType;
SHORT sStrengthValue;
};
typedef PLAYER_BLOOD_INFO *PTR_PLAYER_BLOOD_INFO;
/* ------------------------------------------------------------------------
Macros
------------------------------------------------------------------------ */
/* ------------------------------------------------------------------------
Prototypes
------------------------------------------------------------------------ */
/* ------------------------------------------------------------------------
Global Variables
------------------------------------------------------------------------ */
// Get the name of this bloodline strength.
inline char const * const BLOODLINE_STRENGTH_INFO::mfGetName(
const BLOODLINE_STRENGTH_INFO::TYPE type)
{
return STRMGR_GetStr(fpBloodlineStrengthInfo[type].Name);
}
// Get the score dice for this bloodline strength.
inline const DICE *BLOODLINE_STRENGTH_INFO::mfGetScore(
const BLOODLINE_STRENGTH_INFO::TYPE type)
{
return &fpBloodlineStrengthInfo[type].Score;
}
// Get the name of this bloodline derivation.
inline char const * const BLOODLINE_DERIVATION_INFO::mfGetName(
const BLOODLINE_DERIVATION_INFO::TYPE type)
{
return STRMGR_GetStr(fpBloodlineDerivationInfo[type]);
}
// Get the name of this blood ability.
inline char const * const BLOOD_ABILITY_INFO::mfGetName(
const BLOOD_ABILITY_INFO::BLOOD_ABILITY bloodAbility)
{
return STRMGR_GetStr(fpBloodAbilityInfo[bloodAbility]);
}
#endif // _BLOOD_H