00001 // player.h 00004 00005 #ifndef PLAYER_H 00006 #define PLAYER_H 00007 00008 #define NUM_SKILLS 8 00009 00020 #define NUM_STATS 22 00021 00022 #define STAT_STRENGTH 0 00023 #define STAT_DEXTERITY 1 00024 #define STAT_TOUGHNESS 2 00025 #define STAT_MANA 3 00026 #define STAT_WILLPOWER 4 00027 #define STAT_DV 5 00028 #define STAT_PV 6 00029 #define STAT_TOHIT 7 00030 #define STAT_DAMAGE_MIN 8 00031 #define STAT_DAMAGE_MAX 9 00032 #define STAT_MISSILEDAM_MIN 10 00033 #define STAT_MISSILEDAM_MAX 11 00034 #define STAT_MISSILE_TOHIT 12 00035 #define STAT_LIGHTRADIUS 13 00036 #define STAT_SPEED 14 00037 #define STAT_REGEN 15 00038 #define STAT_PPREGEN 16 00039 #define STAT_MISSILES 17 00040 #define STAT_FLAGS 18 00041 #define STAT_FLAG_SEEINVIS 1 00042 #define STAT_FLAG_RESIST_POISON 2 00043 #define STAT_FLAG_CONFUSED 4 00044 #define STAT_FLAG_HALLUCINATING 8 00045 #define STAT_FLAG_PARALYZED 16 00046 #define STAT_FLAG_DRAIN 32 00047 #define STAT_FLAG_ENTANGLED 64 00048 #define STAT_FLAG_NUMB 128 00049 #define STAT_FLAG_TIMER 256 00050 #define STAT_FLAG_SLIPPERY 512 00051 #define STAT_DIGESTION 19 00052 #define STAT_WEAPON_TYPE 20 00053 #define STAT_COMPONENTS 21 00054 #define STAT_COMPONENT_STAFF 1 00055 #define STAT_COMPONENT_DAGGER 2 00056 #define STAT_COMPONENT_SNAKETOOTH 4 00057 #define STAT_COMPONENT_BLANKSCROLL 8 00058 #define STAT_COMPONENT_GLOVES 16 00059 #define STAT_COMPONENT_AM_YENDOR 32 00060 00061 00062 #define NUM_STATMOD_TIMERS 10 00063 00065 struct player 00066 { 00067 sshort x; 00068 sshort y; 00069 00070 sshort class; 00071 00073 sshort hps; 00074 00079 sshort hps_max; 00080 00086 sshort hps_max_mod; 00087 00089 sshort pps; 00090 00095 sshort pps_max; 00096 00100 sshort pps_max_mod; 00101 00105 ushort partialhps; 00106 00110 ushort partialpps; 00111 00113 ushort level; 00114 00115 schar facing_forced; 00116 schar facing; 00117 ushort velocity; 00118 00119 00120 struct stat_timer stat_timers[NUM_STATMOD_TIMERS]; 00121 00128 sshort intrinsic[NUM_STATS]; 00135 sshort extrinsic[NUM_STATS]; 00136 00137 sshort maximum[NUM_STATS]; 00138 00139 ushort skill[NUM_SKILLS+1]; 00140 ushort skill_marks[NUM_SKILLS+1]; 00141 00144 ulong xp; 00145 00146 slong satiation; 00147 00148 ulong debt; 00149 00150 struct item inventory[PLRINVSIZE]; 00151 00152 slong *spellknowledge; 00153 00154 ulong score; 00155 }; 00156 00157 00158 #endif //PLAYER_H 00159
1.3.6