1 /* $NetBSD: phantdefs.h,v 1.4 2001/09/16 16:34:25 wiz Exp $ */ 2 3 /* 4 * phantdefs.h - important constants for Phantasia 5 */ 6 7 /* ring constants */ 8 #define R_NONE 0 /* no ring */ 9 #define R_NAZREG 1 /* regular Nazgul ring (expires) */ 10 #define R_DLREG 2 /* regular Dark Lord ring (does not expire) */ 11 #define R_BAD 3 /* bad ring */ 12 #define R_SPOILED 4 /* ring which has gone bad */ 13 14 /* status constants */ 15 #define S_NOTUSED 0 /* record not in use */ 16 #define S_OFF 1 /* not playing */ 17 #define S_PLAYING 2 /* playing - nothing else */ 18 #define S_CLOAKED 3 /* playing - cloaked */ 19 #define S_INBATTLE 4 /* playing - in battle */ 20 #define S_MONSTER 5 /* playing - fighting monster */ 21 #define S_TRADING 6 /* playing - at a trading post */ 22 #define S_HUNGUP 7 /* error occurred with character */ 23 24 /* tampered constants */ 25 #define T_OFF 0 /* nothing */ 26 #define T_NRGVOID 1 /* hit an energy void */ 27 #define T_GRAIL 2 /* landed on the holy grail */ 28 #define T_TRANSPORT 3 /* transported by king */ 29 #define T_BESTOW 4 /* gold bestowed by king */ 30 #define T_CURSED 5 /* cursed by king */ 31 #define T_MONSTER 6 /* monster lobbed by valar */ 32 #define T_BLESSED 7 /* blessed by valar */ 33 #define T_RELOCATE 8 /* moved by valar */ 34 #define T_HEAL 9 /* healed by valar */ 35 #define T_VAPORIZED 10 /* vaporized by wizard */ 36 #define T_EXVALAR 11 /* no longer valar */ 37 38 /* inter-terminal battle status constants */ 39 #define I_OFF 0 /* nothing */ 40 #define I_RAN 1 /* ran away */ 41 #define I_STUCK 2 /* tried to run unsuccessfully */ 42 #define I_BLEWIT 3 /* tried to luckout unsuccessfully */ 43 #define I_KILLED 4 /* killed foe */ 44 45 /* constants for altering coordinates */ 46 #define A_SPECIFIC 0 /* coordinates specified */ 47 #define A_FORCED 1 /* coordinates specified, ignore Beyond */ 48 #define A_NEAR 2 /* coordinates not specified, move near */ 49 #define A_FAR 3 /* coordinates not specified, move far */ 50 51 /* constants for character types */ 52 #define C_MAGIC 0 /* magic user */ 53 #define C_FIGHTER 1 /* fighter */ 54 #define C_ELF 2 /* elf */ 55 #define C_DWARF 3 /* dwarf */ 56 #define C_HALFLING 4 /* halfling */ 57 #define C_EXPER 5 /* experimento */ 58 #define C_SUPER 6 /* super being */ 59 60 /* constants for special character types */ 61 #define SC_NONE 0 /* not a special character */ 62 #define SC_KING 1 /* king */ 63 #define SC_COUNCIL 2 /* council of the wise */ 64 #define SC_VALAR 3 /* valar */ 65 #define SC_EXVALAR 4 /* ex-valar */ 66 67 /* special monster constants */ 68 #define SM_NONE 0 /* nothing special */ 69 #define SM_UNICORN 1 /* unicorn */ 70 #define SM_MODNAR 2 /* Modnar */ 71 #define SM_MIMIC 3 /* mimic */ 72 #define SM_DARKLORD 4 /* Dark Lord */ 73 #define SM_LEANAN 5 /* Leanan-Sidhe */ 74 #define SM_SARUMAN 6 /* Saruman */ 75 #define SM_THAUMATURG 7 /* thaumaturgist */ 76 #define SM_BALROG 8 /* balrog */ 77 #define SM_VORTEX 9 /* vortex */ 78 #define SM_NAZGUL 10 /* nazgul */ 79 #define SM_TIAMAT 11 /* Tiamat */ 80 #define SM_KOBOLD 12 /* kobold */ 81 #define SM_SHELOB 13 /* Shelob */ 82 #define SM_FAERIES 14 /* assorted faeries */ 83 #define SM_LAMPREY 15 /* lamprey */ 84 #define SM_SHRIEKER 16 /* shrieker */ 85 #define SM_BONNACON 17 /* bonnacon */ 86 #define SM_SMEAGOL 18 /* Smeagol */ 87 #define SM_SUCCUBUS 19 /* succubus */ 88 #define SM_CERBERUS 20 /* Cerberus */ 89 #define SM_UNGOLIANT 21 /* Ungoliant */ 90 #define SM_JABBERWOCK 22 /* jabberwock */ 91 #define SM_MORGOTH 23 /* Morgoth */ 92 #define SM_TROLL 24 /* troll */ 93 #define SM_WRAITH 25 /* wraith */ 94 95 /* constants for spells */ 96 #define ML_ALLORNOTHING 0.0 /* magic level for 'all or nothing' */ 97 #define MM_ALLORNOTHING 1.0 /* mana used for 'all or nothing' */ 98 #define ML_MAGICBOLT 5.0 /* magic level for 'magic bolt' */ 99 #define ML_FORCEFIELD 15.0 /* magic level for 'force field' */ 100 #define MM_FORCEFIELD 30.0 /* mana used for 'force field' */ 101 #define ML_XFORM 25.0 /* magic level for 'transform' */ 102 #define MM_XFORM 50.0 /* mana used for 'transform' */ 103 #define ML_INCRMIGHT 35.0 /* magic level for 'increase might' */ 104 #define MM_INCRMIGHT 75.0 /* mana used for 'increase might' */ 105 #define ML_INVISIBLE 45.0 /* magic level for 'invisibility' */ 106 #define MM_INVISIBLE 90.0 /* mana used for 'invisibility' */ 107 #define ML_XPORT 60.0 /* magic level for 'transport' */ 108 #define MM_XPORT 125.0 /* mana used for 'transport' */ 109 #define ML_PARALYZE 75.0 /* magic level for 'paralyze' */ 110 #define MM_PARALYZE 150.0 /* mana used for 'paralyze' */ 111 #define MM_SPECIFY 1000.0 /* mana used for 'specify' */ 112 #define ML_CLOAK 20.0 /* magic level for 'cloak' */ 113 #define MEL_CLOAK 7.0 /* experience level for 'cloak' */ 114 #define MM_CLOAK 35.0 /* mana used for 'cloak' */ 115 #define ML_TELEPORT 40.0 /* magic level for 'teleport' */ 116 #define MEL_TELEPORT 12.0 /* experience level for 'teleport' */ 117 #define MM_INTERVENE 1000.0 /* mana used to 'intervene' */ 118 119 /* some miscellaneous constants */ 120 #define SZ_DATABUF 100 /* size of input buffer */ 121 #define SZ_PLAYERSTRUCT sizeof(struct player) /* size of player structure */ 122 #define SZ_VOIDSTRUCT sizeof(struct energyvoid) /* size of energy void struct */ 123 #define SZ_SCORESTRUCT sizeof(struct scoreboard) /* size of score board entry */ 124 #define SZ_MONSTERSTRUCT sizeof(struct monster) /* size of monster structure */ 125 #define SZ_NAME 21 /* size of player name (incl. trailing nul) */ 126 #define SZ_PASSWORD 9 /* size of password (incl. trailing nul) */ 127 #define SZ_LOGIN 9 /* size of login (incl. trailing nul) */ 128 129 #define N_DAYSOLD 21 /* number of days old for purge */ 130 #define N_AGE 500 /* age to degenerate ratio */ 131 #define N_GEMVALUE (1000.0) /* number of gold pieces to gem ratio */ 132 #define N_TAXAMOUNT (7.0) /* tax percent */ 133 134 #define D_BEYOND (1.1e6) /* distance to beyond point of no return */ 135 #define D_EXPER (2000.0) /* distance experimentos are allowed */ 136 137 #define CH_MARKDELETE '\001' /* used to alter name of deleted players */ 138 #define CH_KILL '\030' /* kill character (ctrl-X) */ 139 #define CH_ERASE '\010' /* erase character (ctrl-H) */ 140 #define CH_NEWLINE '\n' /* newline */ 141 #define CH_REDRAW '\014' /* redraw screen character (ctrl-L) */ 142