Angband
player.h
Go to the documentation of this file.
1 
21 #ifndef PLAYER_H
22 #define PLAYER_H
23 
24 #include "guid.h"
25 #include "obj-properties.h"
26 #include "object.h"
27 #include "option.h"
28 
32 enum {
33  #define STAT(a) STAT_##a,
34  #include "list-stats.h"
35  #undef STAT
36 
37  STAT_MAX
38 };
39 
43 enum
44 {
45  #define PF(a,b,c) PF_##a,
46  #include "list-player-flags.h"
47  #undef PF
48  PF_MAX
49 };
50 
51 #define PF_SIZE FLAG_SIZE(PF_MAX)
52 
53 #define pf_has(f, flag) flag_has_dbg(f, PF_SIZE, flag, #f, #flag)
54 #define pf_next(f, flag) flag_next(f, PF_SIZE, flag)
55 #define pf_is_empty(f) flag_is_empty(f, PF_SIZE)
56 #define pf_is_full(f) flag_is_full(f, PF_SIZE)
57 #define pf_is_inter(f1, f2) flag_is_inter(f1, f2, PF_SIZE)
58 #define pf_is_subset(f1, f2) flag_is_subset(f1, f2, PF_SIZE)
59 #define pf_is_equal(f1, f2) flag_is_equal(f1, f2, PF_SIZE)
60 #define pf_on(f, flag) flag_on_dbg(f, PF_SIZE, flag, #f, #flag)
61 #define pf_off(f, flag) flag_off(f, PF_SIZE, flag)
62 #define pf_wipe(f) flag_wipe(f, PF_SIZE)
63 #define pf_setall(f) flag_setall(f, PF_SIZE)
64 #define pf_negate(f) flag_negate(f, PF_SIZE)
65 #define pf_copy(f1, f2) flag_copy(f1, f2, PF_SIZE)
66 #define pf_union(f1, f2) flag_union(f1, f2, PF_SIZE)
67 #define pf_inter(f1, f2) flag_inter(f1, f2, PF_SIZE)
68 #define pf_diff(f1, f2) flag_diff(f1, f2, PF_SIZE)
69 
70 #define player_has(p, flag) (pf_has(p->race->pflags, (flag)) || pf_has(p->class->pflags, (flag)))
71 
76 #define STAT_RANGE 38
77 
81 #define PY_MAX_EXP 99999999L /* Maximum exp */
82 #define PY_KNOW_LEVEL 30 /* Level to know all runes */
83 #define PY_MAX_LEVEL 50 /* Maximum level */
84 
88 #define PY_SPELL_LEARNED 0x01 /* Spell has been learned */
89 #define PY_SPELL_WORKED 0x02 /* Spell has been successfully tried */
90 #define PY_SPELL_FORGOTTEN 0x04 /* Spell has been forgotten */
91 
92 #define BTH_PLUS_ADJ 3 /* Adjust BTH per plus-to-hit */
93 
97 #define NOSCORE_WIZARD 0x0002
98 #define NOSCORE_DEBUG 0x0008
99 #define NOSCORE_JUMPING 0x0010
100 
104 enum {
110 
112 };
113 
117 enum {
118  SKILL_DISARM_PHYS, /* Disarming - physical */
119  SKILL_DISARM_MAGIC, /* Disarming - magical */
120  SKILL_DEVICE, /* Magic Devices */
121  SKILL_SAVE, /* Saving throw */
122  SKILL_SEARCH, /* Searching ability */
123  SKILL_STEALTH, /* Stealth factor */
124  SKILL_TO_HIT_MELEE, /* To hit (normal) */
125  SKILL_TO_HIT_BOW, /* To hit (shooting) */
126  SKILL_TO_HIT_THROW, /* To hit (throwing) */
127  SKILL_DIGGING, /* Digging */
128 
130 };
131 
135 struct quest
136 {
137  struct quest *next;
139  char *name;
140  byte level; /* Dungeon level */
141  struct monster_race *race; /* Monster race */
142  int cur_num; /* Number killed (unused) */
143  int max_num; /* Number required (unused) */
144 };
145 
149 struct equip_slot {
150  struct equip_slot *next;
151 
153  char *name;
154  struct object *obj;
155 };
156 
160 struct player_body {
161  struct player_body *next;
162 
163  char *name;
165  struct equip_slot *slots;
166 };
167 
171 struct player_race {
172  struct player_race *next;
173  const char *name;
174 
175  unsigned int ridx;
176 
177  int r_mhp;
178  int r_exp;
180  int b_age;
181  int m_age;
183  int base_hgt;
184  int mod_hgt;
185  int base_wgt;
186  int mod_wgt;
188  int infra;
190  int body;
200 
202 };
203 
208 struct start_item {
209  struct object_kind *kind;
210  int min;
211  int max;
213  struct start_item *next;
214 };
215 
219 struct magic_realm {
220  struct magic_realm *next;
221  char *code;
222  char *name;
223  int stat;
224  char *verb;
225  char *spell_noun;
226  char *book_noun;
227 };
228 
232 struct class_spell {
233  char *name;
234  char *text;
235 
236  struct effect *effect;
238  int sidx;
239  int bidx;
240  int slevel;
241  int smana;
242  int sfail;
243  int sexp;
244 };
245 
249 struct class_book {
250  int tval;
251  int sval;
252  int realm;
254  struct class_spell *spells;
255 };
256 
260 struct class_magic {
263  const struct magic_realm *spell_realm;
264  int num_books;
265  struct class_book *books;
267 };
268 
272 struct player_class {
274  const char *name;
275  unsigned int cidx;
276 
277  const char *title[10];
284  int c_mhp;
285  int c_exp;
296 };
297 
324  int isucc;
325  int roll;
326  char *text;
327 };
328 
332  unsigned int idx;
333 };
334 
342  size_t next;
343  size_t length;
344 };
345 
351 struct player_state {
359  int speed;
361  int num_blows;
362  int num_shots;
364  int ammo_mult;
365  int ammo_tval;
367  int ac;
368  int to_a;
369  int to_h;
370  int to_d;
372  int see_infra;
374  int cur_light;
376  bool heavy_wield;
377  bool heavy_shoot;
378  bool icky_wield;
386 };
387 
394  bool playing; /* True if player is playing */
395  bool autosave; /* True if autosave is pending */
396  bool generate_level; /* True if level needs regenerating */
397  bool only_partial; /* True if only partial updates are needed */
398  bool dropping; /* True if auto-drop is in progress */
399 
400  int energy_use; /* Energy use this turn */
401  int new_spells; /* Number of spells available */
402 
403  struct monster *health_who; /* Health bar trackee */
404  struct monster_race *monster_race; /* Monster race trackee */
405  struct object *object; /* Object trackee */
406  struct object_kind *object_kind; /* Object kind trackee */
407 
408  u32b notice; /* Bit flags for pending actions such as
409  * reordering inventory, ignoring, etc. */
410  u32b update; /* Bit flags for recalculations needed
411  * such as HP, or visible area */
412  u32b redraw; /* Bit flags for things that /have/ changed,
413  * and just need to be redrawn by the UI,
414  * such as HP, Speed, etc.*/
415 
416  int command_wrk; /* Used by the UI to decide whether
417  * to start off showing equipment or
418  * inventory listings when offering
419  * a choice. See obj-ui.c */
420 
421  bool create_up_stair; /* Create up stair on next level */
422  bool create_down_stair; /* Create down stair on next level */
423  bool light_level; /* Create down stair on next level */
424 
425  int resting; /* Resting counter */
426 
427  int running; /* Running counter */
428  bool running_withpathfind; /* Are we using the pathfinder ? */
429  bool running_firststep; /* Is this our first step running? */
430 
431  struct object **quiver; /* Quiver objects */
432  struct object **inven; /* Inventory objects */
433  int total_weight; /* Total weight being carried */
434  int inven_cnt; /* Number of items in inventory */
435  int equip_cnt; /* Number of items in equipment */
436  int quiver_cnt; /* Number of items in the quiver */
437 };
438 
450 struct player {
451  const struct player_race *race;
452  const struct player_class *class;
453 
454  s16b py; /* Player location */
455  s16b px; /* Player location */
456 
457  byte hitdie; /* Hit dice (sides) */
458  byte expfact; /* Experience factor */
459 
460  s16b age; /* Characters age */
461  s16b ht; /* Height */
462  s16b wt; /* Weight */
463 
464  s32b au; /* Current Gold */
465 
466  s16b max_depth; /* Max depth */
467  s16b depth; /* Cur depth */
468 
469  s16b max_lev; /* Max level */
470  s16b lev; /* Cur level */
471 
472  s32b max_exp; /* Max experience */
473  s32b exp; /* Cur experience */
474  u16b exp_frac; /* Cur exp frac (times 2^16) */
475 
476  s16b mhp; /* Max hit pts */
477  s16b chp; /* Cur hit pts */
478  u16b chp_frac; /* Cur hit frac (times 2^16) */
479 
480  s16b msp; /* Max mana pts */
481  s16b csp; /* Cur mana pts */
482  u16b csp_frac; /* Cur mana frac (times 2^16) */
483 
484  s16b stat_max[STAT_MAX]; /* Current "maximal" stat values */
485  s16b stat_cur[STAT_MAX]; /* Current "natural" stat values */
486  s16b stat_map[STAT_MAX]; /* Tracks remapped stats from temp stat swap */
487 
488  s16b *timed; /* Timed effects */
489 
490  s16b word_recall; /* Word of recall counter */
491  s16b deep_descent; /* Deep Descent counter */
492 
493  s16b energy; /* Current energy */
494  u32b total_energy; /* Total energy used (including resting) */
495  u32b resting_turn; /* Number of player turns spent resting */
496 
497  s16b food; /* Current nutrition */
498 
499  byte confusing; /* Glowing hands */
500  byte unignoring; /* Unignoring */
501 
502  byte *spell_flags; /* Spell flags */
503  byte *spell_order; /* Spell order */
504  byte searching; /* Currently searching */
505 
506  char full_name[PLAYER_NAME_LEN]; /* Full name */
507  char died_from[80]; /* Cause of death */
508  char *history; /* Player history */
509  struct quest *quests; /* Quest history */
510  u16b total_winner; /* Total winner */
511 
512  u16b noscore; /* Cheating flags */
513 
514  bool is_dead; /* Player is dead */
515 
516  bool wizard; /* Player is in wizard mode */
517 
518  s16b player_hp[PY_MAX_LEVEL]; /* HP gained per level */
519 
520  /* Saved values for quickstart */
521  s32b au_birth; /* Birth gold when option birth_money is false */
522  s16b stat_birth[STAT_MAX]; /* Birth "natural" stat values */
523  s16b ht_birth; /* Birth Height */
524  s16b wt_birth; /* Birth Weight */
525 
526  struct player_options opts; /* Player options */
527  struct player_history hist; /* Player history (see player-history.c) */
528 
529  struct player_body body; /* Equipment slots available */
530 
531  struct object *gear; /* Real gear */
532  struct object *gear_k; /* Known gear */
533 
534  struct object *obj_k; /* Object knowledge ("runes") */
535  struct chunk *cave; /* Known version of current level */
536 
537  struct player_state state; /* Calculatable state */
538  struct player_state known_state; /* What the player can know of the above */
539  struct player_upkeep *upkeep; /* Temporary player-related values */
540 };
541 
542 
548 extern struct player_body *bodies;
549 extern struct player_race *races;
550 extern struct player_class *classes;
551 extern struct magic_realm *realms;
552 
553 extern const s32b player_exp[PY_MAX_LEVEL];
554 extern struct player *player;
555 
556 /* player-class.c */
557 struct player_class *player_id2class(guid id);
558 
559 /* player.c */
560 int stat_name_to_idx(const char *name);
561 const char *stat_idx_to_name(int type);
562 const struct magic_realm *lookup_realm(const char *code);
563 bool player_stat_inc(struct player *p, int stat);
564 bool player_stat_dec(struct player *p, int stat, bool permanent);
565 void player_exp_gain(struct player *p, s32b amount);
566 void player_exp_lose(struct player *p, s32b amount, bool permanent);
567 void player_flags(struct player *p, bitflag f[OF_SIZE]);
568 byte player_hp_attr(struct player *p);
569 byte player_sp_attr(struct player *p);
570 bool player_restore_mana(struct player *p, int amt);
571 void player_safe_name(char *safe, size_t safelen, const char *name, bool strip_suffix);
572 
573 /* player-race.c */
574 struct player_race *player_id2race(guid id);
575 
576 #endif /* !PLAYER_H */
struct quest * quests
Definition: player.h:509
struct monster * health_who
Definition: player.h:403
uint16_t u16b
Definition: h-basic.h:169
void player_safe_name(char *safe, size_t safelen, const char *name, bool strip_suffix)
Return a version of the player's name safe for use in filesystems.
Definition: player.c:345
struct object * obj_k
Definition: player.h:534
int bidx
The index into the player's books array.
Definition: player.h:239
int infra
Infra-vision range.
Definition: player.h:188
const char * title[10]
Titles.
Definition: player.h:277
struct history_chart * history
Definition: player.h:199
Definition: player.h:56
int stat_top[STAT_MAX]
Maximal modified stats.
Definition: player.h:355
int to_d
Bonus to dam.
Definition: player.h:370
struct object * object
Definition: player.h:405
struct object * gear
Definition: player.h:531
struct player_body * next
Definition: player.h:161
const char * stat_idx_to_name(int type)
Definition: player.c:119
definitions and functions for object flags and modifiers
Monster "race" information, including racial memories.
Definition: monster.h:265
Player race info.
Definition: player.h:171
struct history_chart * next
Definition: player.h:330
int sidx
The index of this spell for this class.
Definition: player.h:238
u32b total_energy
Definition: player.h:494
int cur_num
Definition: player.h:142
s16b stat_max[STAT_MAX]
Definition: player.h:484
s16b stat_cur[STAT_MAX]
Definition: player.h:485
struct monster_race * monster_race
Definition: player.h:404
int equip_cnt
Definition: player.h:435
A structure to hold class-dependent information on spell books.
Definition: player.h:249
char * spell_noun
Definition: player.h:225
int command_wrk
Definition: player.h:416
int isucc
Definition: player.h:324
int sfail
Base chance of failure.
Definition: player.h:242
Structure for magic realms.
Definition: player.h:219
struct history_chart * succ
Definition: player.h:323
struct magic_realm * next
Definition: player.h:220
Monster information, for a specific monster.
Definition: monster.h:323
s16b lev
Definition: player.h:470
int new_spells
Definition: player.h:401
uint32_t u32b
Definition: h-basic.h:172
struct effect * effect
The spell's effect.
Definition: player.h:236
Player history information.
Definition: player.h:340
struct player_state known_state
Definition: player.h:538
int num_shots
Number of shots.
Definition: player.h:362
Information about object kinds, including player knowledge.
Definition: object.h:157
char * book_noun
Definition: player.h:226
void player_exp_lose(struct player *p, s32b amount, bool permanent)
Definition: player.c:274
u32b redraw
Definition: player.h:412
Definition: player.h:107
struct player_race * player_id2race(guid id)
Definition: player-race.c:21
struct element_info el_info[ELEM_MAX]
Resists from race and items.
Definition: player.h:385
s16b ht_birth
Definition: player.h:523
keycode_t code
Definition: ui-event.c:25
char full_name[PLAYER_NAME_LEN]
Definition: player.h:506
void player_flags(struct player *p, bitflag f[OF_SIZE])
Obtain object flags for the player.
Definition: player.c:287
int num_books
Number of spellbooks.
Definition: player.h:264
int x_skills[SKILL_MAX]
Extra skills.
Definition: player.h:282
char died_from[80]
Definition: player.h:507
Information about class magic knowledge.
Definition: player.h:260
Definition: player.h:127
bool player_restore_mana(struct player *p, int amt)
Definition: player.c:326
struct player_class * classes
Definition: player.c:39
Definition: player.h:108
u16b type
Definition: player.h:152
struct equip_slot * next
Definition: player.h:150
u16b exp_frac
Definition: player.h:474
int r_mhp
Hit-dice modifier.
Definition: player.h:177
s16b ht
Definition: player.h:461
void player_exp_gain(struct player *p, s32b amount)
Definition: player.c:266
s16b stat_map[STAT_MAX]
Definition: player.h:486
Definition: player.h:118
struct player_body body
Definition: player.h:529
Entity guids.
player race and class flags
s16b * timed
Definition: player.h:488
Structure for the "quests".
Definition: player.h:135
const struct magic_realm * lookup_realm(const char *code)
Definition: player.c:127
struct monster_race * race
Definition: player.h:141
bitflag pflags[PF_SIZE]
Racial (player) flags.
Definition: player.h:197
int c_skills[SKILL_MAX]
Class skills.
Definition: player.h:281
int stat_name_to_idx(const char *name)
Definition: player.c:108
bitflag flags[OF_SIZE]
Racial (object) flags.
Definition: player.h:196
Definition: player.h:120
s16b food
Definition: player.h:497
uint8_t byte
Definition: h-basic.h:167
s16b max_depth
Definition: player.h:466
int max
Maximum starting amount.
Definition: player.h:211
char * text
Definition: player.h:326
bool cumber_armor
Mana draining armor.
Definition: player.h:380
int spell_first
Level of first spell.
Definition: player.h:261
Options table and definitions.
u16b count
Definition: player.h:164
int max_attacks
Maximum possible attacks.
Definition: player.h:289
Definition: player.h:122
const s32b player_exp[PY_MAX_LEVEL]
Base experience levels, may be adjusted up for race and/or class.
Definition: player.c:45
size_t length
Current length.
Definition: player.h:343
int min_weight
Minimum weapon weight for calculations.
Definition: player.h:290
unsigned int idx
Definition: player.h:332
s16b deep_descent
Definition: player.h:491
struct player_options opts
Definition: player.h:526
Write value lines for a set of modifiers.
Definition: player.h:124
int slevel
Required level (to learn)
Definition: player.h:240
int r_adj[STAT_MAX]
Stat bonuses.
Definition: player.h:192
s32b au_birth
Definition: player.h:521
Definition: cave.h:153
int realm
The magic realm of this book.
Definition: player.h:252
bool autosave
Definition: player.h:395
bool wizard
Definition: player.h:516
struct object ** inven
Definition: player.h:432
int num_blows
Number of blows x100.
Definition: player.h:361
All the variable state that changes when you put on/take off equipment.
Definition: player.h:351
char * code
Definition: player.h:221
Player history table.
Definition: player-history.h:47
int max_num
Definition: player.h:143
s16b msp
Definition: player.h:480
s16b px
Definition: player.h:455
struct element_info el_info[ELEM_MAX]
Resists.
Definition: player.h:201
bool playing
Definition: player.h:394
char * name
Definition: player.h:163
Object information, for a specific object.
Definition: object.h:393
struct player_state state
Definition: player.h:537
struct equip_slot * slots
Definition: player.h:165
int stat_ind[STAT_MAX]
Indexes into stat tables.
Definition: player.h:353
s32b au
Definition: player.h:464
char * text
Definition: player.h:234
bool is_dead
Definition: player.h:514
bool running_withpathfind
Definition: player.h:428
s32b max_exp
Definition: player.h:472
Player class info.
Definition: player.h:272
int sexp
Encoded experience bonus.
Definition: player.h:243
#define PF_SIZE
Definition: player.h:51
u32b update
Definition: player.h:410
int mod_wgt
Mod weight.
Definition: player.h:186
int ac
Base ac.
Definition: player.h:367
Definition: player.h:111
int ammo_mult
Ammo multiplier.
Definition: player.h:364
int total_weight
Definition: player.h:433
const char * name
Definition: player.h:173
struct player_class * next
Definition: player.h:273
int running
Definition: player.h:427
int cur_light
Radius of light (if any)
Definition: player.h:374
int roll
Definition: player.h:325
s16b py
Definition: player.h:454
int base_wgt
Base weight.
Definition: player.h:185
s16b age
Definition: player.h:460
int tval
Item type of the book.
Definition: player.h:250
int type
Definition: mon-msg.c:80
s16b mhp
Definition: player.h:476
unsigned int ridx
Definition: player.h:175
s16b csp
Definition: player.h:481
u16b chp_frac
Definition: player.h:478
Definition: player.h:121
byte unignoring
Definition: player.h:500
struct player_race * races
Definition: player.c:38
struct object_kind * kind
Definition: player.h:209
int stat_use[STAT_MAX]
Current modified stats.
Definition: player.h:354
byte player_hp_attr(struct player *p)
Definition: player.c:298
#define PLAYER_NAME_LEN
Definition: option.h:23
int b_age
Base age.
Definition: player.h:180
int att_multiply
Multiplier for attack calculations.
Definition: player.h:291
const struct player_race * race
Definition: player.h:451
byte confusing
Definition: player.h:499
const char ** p[]
Definition: name.c:40
byte bitflag
Definition: z-bitflag.h:27
char * name
Definition: player.h:153
Definition: object.h:56
s32b exp
Definition: player.h:473
int stat_add[STAT_MAX]
Equipment stat bonuses.
Definition: player.h:352
byte index
Definition: player.h:138
const char * name
Definition: player.h:274
bool cumber_glove
Mana draining gloves.
Definition: player.h:381
Items the player starts with.
Definition: player.h:208
byte * spell_order
Definition: player.h:503
bool generate_level
Definition: player.h:396
byte expfact
Definition: player.h:458
Definition: player.h:329
int16_t s16b
Definition: h-basic.h:170
int skills[SKILL_MAX]
Skills.
Definition: player.h:357
const struct magic_realm * spell_realm
Primary spellcasting realm.
Definition: player.h:263
int body
Race body.
Definition: player.h:190
Temporary, derived, player-related variables used during play but not saved.
Definition: player.h:393
u16b noscore
Definition: player.h:512
Definition: player.h:109
s16b stat_birth[STAT_MAX]
Definition: player.h:522
int num_spells
Number of spells in this book.
Definition: player.h:253
bitflag pflags[PF_SIZE]
Player intrinsic flags.
Definition: player.h:384
unsigned int cidx
Definition: player.h:275
struct start_item * start_items
Starting inventory.
Definition: player.h:293
int stat
Definition: player.h:223
int r_exp
Experience factor.
Definition: player.h:178
Element info type.
Definition: object.h:108
int total_spells
Number of spells for this class.
Definition: player.h:266
bool icky_wield
Icky weapon shooter.
Definition: player.h:378
byte * spell_flags
Definition: player.h:502
bool heavy_shoot
Heavy shooter.
Definition: player.h:377
Definition: player.h:123
s16b word_recall
Definition: player.h:490
s16b player_hp[PY_MAX_LEVEL]
Definition: player.h:518
A structure to hold class-dependent information on spells.
Definition: player.h:232
struct object ** quiver
Definition: player.h:431
bool running_firststep
Definition: player.h:429
int see_infra
Infravision range.
Definition: player.h:372
char * history
Definition: player.h:508
#define OF_SIZE
Definition: obj-properties.h:120
struct object * obj
Definition: player.h:154
int c_exp
Experience factor.
Definition: player.h:285
s16b max_lev
Definition: player.h:469
struct player_history hist
Definition: player.h:527
struct history_info * entries
List of entries.
Definition: player.h:341
int base_hgt
Base height.
Definition: player.h:183
int c_mhp
Hit-dice adjustment.
Definition: player.h:284
unsigned int guid
Definition: guid.h:22
byte player_sp_attr(struct player *p)
Definition: player.c:312
struct class_magic magic
Magic spells.
Definition: player.h:295
basic object structs and enums
int smana
Required mana (to cast)
Definition: player.h:241
int r_skills[SKILL_MAX]
Skills.
Definition: player.h:194
byte hitdie
Definition: player.h:457
int speed
Current speed.
Definition: player.h:359
u32b notice
Definition: player.h:408
int ammo_tval
Ammo variety.
Definition: player.h:365
bool player_stat_inc(struct player *p, int stat)
Definition: player.c:142
A single equipment slot.
Definition: player.h:149
bitflag flags[OF_SIZE]
Status flags from race and items.
Definition: player.h:383
bitflag pflags[PF_SIZE]
(Player) flags
Definition: player.h:287
struct object_kind * object_kind
Definition: player.h:406
Histories are a graph of charts; each chart contains a set of individual entries for that chart...
Definition: player.h:321
bool heavy_wield
Heavy weapon.
Definition: player.h:376
bool light_level
Definition: player.h:423
byte searching
Definition: player.h:504
struct object * gear_k
Definition: player.h:532
u32b resting_turn
Definition: player.h:495
Definition: player.h:106
bool create_down_stair
Definition: player.h:422
struct magic_realm * realms
Definition: player.c:40
int32_t s32b
Definition: h-basic.h:173
bool player_stat_dec(struct player *p, int stat, bool permanent)
Definition: player.c:168
Effect.
Definition: object.h:52
s16b chp
Definition: player.h:477
bool dropping
Definition: player.h:398
struct class_book * books
Details of spellbooks.
Definition: player.h:265
char * name
Definition: player.h:233
s16b wt
Definition: player.h:462
s16b wt_birth
Definition: player.h:524
s16b depth
Definition: player.h:467
Definition: player.h:125
int min
Minimum starting amount.
Definition: player.h:210
struct player_class * player_id2class(guid id)
Definition: player-class.c:22
struct history_entry * entries
Definition: player.h:331
Intialize random names
Definition: init.c:664
int spell_weight
Max armour weight to avoid mana penalties.
Definition: player.h:262
int m_age
Mod age.
Definition: player.h:181
char * verb
Definition: player.h:224
char * name
Definition: player.h:139
u16b csp_frac
Definition: player.h:482
int resting
Definition: player.h:425
s16b energy
Definition: player.h:493
bool create_up_stair
Definition: player.h:421
Most of the "player" information goes here.
Definition: player.h:450
The option data structures.
Definition: option.h:62
struct start_item * next
Definition: player.h:213
struct player_upkeep * upkeep
Definition: player.h:539
int quiver_cnt
Definition: player.h:436
int mod_hgt
Mod height.
Definition: player.h:184
Definition: player.h:105
struct player * player
Pointer to the player struct.
Definition: list-options.h:50
struct quest * next
Definition: player.h:137
struct player_body * bodies
Externs
Definition: player.c:37
int to_a
Bonus to ac.
Definition: player.h:368
#define PY_MAX_LEVEL
Definition: player.h:83
struct class_spell * spells
Spells in the book.
Definition: player.h:254
Definition: player.h:75
struct history_entry * next
Definition: player.h:322
Definition: player.h:129
byte level
Definition: player.h:140
int sval
Item sub-type for book (book number)
Definition: player.h:251
Definition: player.h:119
int inven_cnt
Definition: player.h:434
int to_h
Bonus to hit.
Definition: player.h:369
struct chunk * cave
Definition: player.h:535
struct player_race * next
Definition: player.h:172
A player 'body'.
Definition: player.h:160
char * name
Definition: player.h:222
int energy_use
Definition: player.h:400
int c_adj[STAT_MAX]
Stat modifier.
Definition: player.h:279
size_t next
First unused entry.
Definition: player.h:342
Definition: player.h:126
bool only_partial
Definition: player.h:397
u16b total_winner
Definition: player.h:510