phantstruct.h 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131
  1. /* $NetBSD: phantstruct.h,v 1.5 2005/02/15 12:58:21 jsm Exp $ */
  2. #define bool char
  3. /* phbool is used when we need this version of bool after <curses.h>. */
  4. #define phbool char
  5. /*
  6. * phantstruct.h - structure definitions for Phantasia
  7. */
  8. struct player /* player statistics */
  9. {
  10. double p_experience; /* experience */
  11. double p_level; /* level */
  12. double p_strength; /* strength */
  13. double p_sword; /* sword */
  14. double p_might; /* effect strength */
  15. double p_energy; /* energy */
  16. double p_maxenergy; /* maximum energy */
  17. double p_shield; /* shield */
  18. double p_quickness; /* quickness */
  19. double p_quksilver; /* quicksilver */
  20. double p_speed; /* effective quickness */
  21. double p_magiclvl; /* magic level */
  22. double p_mana; /* mana */
  23. double p_brains; /* brains */
  24. double p_poison; /* poison */
  25. double p_gold; /* gold */
  26. double p_gems; /* gems */
  27. double p_sin; /* sin */
  28. double p_x; /* x coord */
  29. double p_y; /* y coord */
  30. double p_1scratch,
  31. p_2scratch; /* variables used for decree, player battle */
  32. struct
  33. {
  34. short ring_type; /* type of ring */
  35. short ring_duration; /* duration of ring */
  36. bool ring_inuse; /* ring in use flag */
  37. } p_ring; /* ring stuff */
  38. long p_age; /* age of player */
  39. int p_degenerated; /* age/3000 last degenerated */
  40. short p_type; /* character type */
  41. short p_specialtype; /* special character type */
  42. short p_lives; /* multiple lives for council, valar */
  43. short p_crowns; /* crowns */
  44. short p_charms; /* charms */
  45. short p_amulets; /* amulets */
  46. short p_holywater; /* holy water */
  47. short p_lastused; /* day of year last used */
  48. short p_status; /* playing, cloaked, etc. */
  49. short p_tampered; /* decree'd, etc. flag */
  50. short p_istat; /* used for inter-terminal battle */
  51. bool p_palantir; /* palantir */
  52. bool p_blessing; /* blessing */
  53. bool p_virgin; /* virgin */
  54. bool p_blindness; /* blindness */
  55. char p_name[SZ_NAME]; /* name */
  56. char p_password[SZ_PASSWORD];/* password */
  57. char p_login[SZ_LOGIN]; /* login */
  58. };
  59. struct monster /* monster stats */
  60. {
  61. double m_strength; /* strength */
  62. double m_brains; /* brains */
  63. double m_speed; /* speed */
  64. double m_energy; /* energy */
  65. double m_experience; /* experience */
  66. double m_flock; /* % chance of flocking */
  67. double m_o_strength; /* original strength */
  68. double m_o_speed; /* original speed */
  69. double m_maxspeed; /* maximum speed */
  70. double m_o_energy; /* original energy */
  71. double m_melee; /* melee damage */
  72. double m_skirmish; /* skirmish damage */
  73. int m_treasuretype; /* treasure type */
  74. int m_type; /* special type */
  75. char m_name[26]; /* name */
  76. };
  77. struct energyvoid /* energy void */
  78. {
  79. double ev_x; /* x coordinate */
  80. double ev_y; /* y coordinate */
  81. bool ev_active; /* active or not */
  82. };
  83. struct scoreboard /* scoreboard entry */
  84. {
  85. double sb_level; /* level of player */
  86. char sb_type[4]; /* character type of player */
  87. char sb_name[SZ_NAME]; /* name of player */
  88. char sb_login[SZ_LOGIN]; /* login of player */
  89. };
  90. struct charstats /* character type statistics */
  91. {
  92. double c_maxbrains; /* max brains per level */
  93. double c_maxmana; /* max mana per level */
  94. double c_weakness; /* how strongly poison affects player */
  95. double c_goldtote; /* how much gold char can carry */
  96. int c_ringduration; /* bad ring duration */
  97. struct
  98. {
  99. double base; /* base for roll */
  100. double interval; /* interval for roll */
  101. double increase; /* increment per level */
  102. } c_quickness, /* quickness */
  103. c_strength, /* strength */
  104. c_mana, /* mana */
  105. c_energy, /* energy level */
  106. c_brains, /* brains */
  107. c_magiclvl; /* magic level */
  108. };
  109. struct menuitem /* menu item for purchase */
  110. {
  111. const char *item; /* menu item name */
  112. double cost; /* cost of item */
  113. };