Crossfire Server, Trunk  R20513
living.h
Go to the documentation of this file.
1 
6 #ifndef LIVING_H
7 #define LIVING_H
8 
10 enum {
11  STRENGTH = 0,
12  DEXTERITY = 1,
14  WISDOM = 3,
15  CHARISMA = 4,
17  POWER = 6,
18  NUM_STATS = 7
19 };
20 
22 #define MAXLEVEL 115
23 
24 extern const char *const attacks[NROFATTACKS];
25 
26 extern const char *const restore_msg[NUM_STATS];
27 extern const char *const statname[NUM_STATS];
28 extern const char *const short_stat_name[NUM_STATS];
29 extern const char *const lose_msg[NUM_STATS];
30 
34 typedef struct liv {
48 } living;
49 
50 int get_cha_bonus(int stat);
51 int get_dex_bonus(int stat);
52 int get_thaco_bonus(int stat);
53 uint32_t get_weight_limit(int stat);
54 int get_learn_spell(int stat);
55 int get_cleric_chance(int stat);
56 int get_turn_bonus(int stat);
57 int get_dam_bonus(int stat);
58 float get_speed_bonus(int stat);
59 int get_fear_bonus(int stat);
60 
61 #endif /* LIVING_H */
int get_learn_spell(int stat)
Definition: living.c:2259
int8_t Int
Definition: living.h:35
int8_t ac
Armour Class, how hard to hit, the lower the better.
Definition: living.h:37
struct liv living
Various statistics of objects.
int get_dex_bonus(int stat)
Definition: living.c:2247
int get_cha_bonus(int stat)
Definition: living.c:2243
Definition: living.h:14
int16_t maxgrace
Maximum grace.
Definition: living.h:44
Definition: living.h:17
const char *const statname[NUM_STATS]
Name of stats.
Definition: living.c:183
int64_t exp
Experience.
Definition: living.h:46
Various statistics of objects.
Definition: living.h:34
int16_t sp
Spell points.
Definition: living.h:41
const char *const restore_msg[NUM_STATS]
Message when a player has a stat restored.
Definition: living.c:150
int16_t maxsp
Max spell points.
Definition: living.h:42
int8_t Con
Definition: living.h:35
int16_t hp
Hit Points.
Definition: living.h:39
uint32_t get_weight_limit(int stat)
Definition: living.c:2255
int get_turn_bonus(int stat)
Definition: living.c:2267
int16_t maxhp
Max hit points.
Definition: living.h:40
signed short int16_t
Definition: win32.h:160
int8_t Wis
Definition: living.h:35
int16_t dam
How much damage this object does when hitting.
Definition: living.h:45
const char *const short_stat_name[NUM_STATS]
Short name of stats.
Definition: living.c:194
int8_t Cha
Definition: living.h:35
Number of statistics.
Definition: living.h:18
int get_thaco_bonus(int stat)
Definition: living.c:2251
int8_t luck
Affects thaco and ac from time to time.
Definition: living.h:38
int get_cleric_chance(int stat)
Definition: living.c:2263
int8_t wc
Weapon Class, how skilled, the lower the better.
Definition: living.h:36
signed __int64 int64_t
Definition: win32.h:168
int8_t Str
Definition: living.h:35
unsigned int uint32_t
Definition: win32.h:162
float get_speed_bonus(int stat)
Definition: living.c:2275
int get_fear_bonus(int stat)
Definition: living.c:2279
int16_t grace
Grace.
Definition: living.h:43
signed char int8_t
Type definitions for fixed-size integer types.
Definition: win32.h:158
const char *const lose_msg[NUM_STATS]
Message when a player decreases permanently a stat.
Definition: living.c:172
int8_t Dex
Definition: living.h:35
#define NROFATTACKS
Definition: attack.h:17
signed int int32_t
Definition: win32.h:159
int8_t Pow
Definition: living.h:35
int get_dam_bonus(int stat)
Definition: living.c:2271
const char *const attacks[NROFATTACKS]
Attack type names.
Definition: living.c:129
int32_t food
How much food in stomach.
Definition: living.h:47