summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/birth.cc213
-rw-r--r--src/birth.hpp1
-rw-r--r--src/birther.hpp6
-rw-r--r--src/cmd5.cc24
-rw-r--r--src/defines.h22
-rw-r--r--src/dungeon.cc6
-rw-r--r--src/files.cc45
-rw-r--r--src/hiscore.hpp1
-rw-r--r--src/init1.cc48
-rw-r--r--src/loadsave.cc25
-rw-r--r--src/player_race.hpp13
-rw-r--r--src/player_race_mod.hpp13
-rw-r--r--src/player_sex.hpp17
-rw-r--r--src/player_sex_fwd.hpp3
-rw-r--r--src/player_type.hpp7
-rw-r--r--src/q_main.cc2
-rw-r--r--src/tables.cc23
-rw-r--r--src/tables.hpp2
-rw-r--r--src/traps.cc80
-rw-r--r--src/variable.cc1
-rw-r--r--src/variable.hpp2
21 files changed, 36 insertions, 518 deletions
diff --git a/src/birth.cc b/src/birth.cc
index f8b81e35..4c9ff06a 100644
--- a/src/birth.cc
+++ b/src/birth.cc
@@ -204,7 +204,6 @@ static void save_prev_data(void)
/*** Save the current data ***/
/* Save the data */
- previous_char.sex = p_ptr->psex;
previous_char.race = p_ptr->prace;
previous_char.rmod = p_ptr->pracem;
previous_char.pclass = p_ptr->pclass;
@@ -215,10 +214,6 @@ static void save_prev_data(void)
previous_char.god = p_ptr->pgod;
previous_char.grace = p_ptr->grace;
- previous_char.age = p_ptr->age;
- previous_char.wt = p_ptr->wt;
- previous_char.ht = p_ptr->ht;
- previous_char.sc = p_ptr->sc;
previous_char.au = p_ptr->au;
/* Save the stats */
@@ -249,10 +244,6 @@ static void load_prev_data(bool_ save)
/*** Save the current data ***/
/* Save the data */
- temp.age = p_ptr->age;
- temp.wt = p_ptr->wt;
- temp.ht = p_ptr->ht;
- temp.sc = p_ptr->sc;
temp.au = p_ptr->au;
/* Save the stats */
@@ -272,10 +263,6 @@ static void load_prev_data(bool_ save)
/*** Load the previous data ***/
/* Load the data */
- p_ptr->age = previous_char.age;
- p_ptr->wt = previous_char.wt;
- p_ptr->ht = previous_char.ht;
- p_ptr->sc = previous_char.sc;
p_ptr->au = previous_char.au;
/* Load the stats */
@@ -298,10 +285,6 @@ static void load_prev_data(bool_ save)
if (!save) return;
/* Save the data */
- previous_char.age = temp.age;
- previous_char.wt = temp.wt;
- previous_char.ht = temp.ht;
- previous_char.sc = temp.sc;
previous_char.au = temp.au;
/* Save the stats */
@@ -518,7 +501,7 @@ static void get_extra(void)
*/
static void get_history(void)
{
- int i, n, chart, roll, social_class;
+ int i, n, chart, roll;
char *s, *t;
@@ -531,9 +514,6 @@ static void get_history(void)
/* Clear the history text */
buf[0] = '\0';
- /* Initial social class */
- social_class = randint(4);
-
/* Starting place */
chart = rp_ptr->chart;
@@ -553,23 +533,10 @@ static void get_history(void)
/* Acquire the textual history */
(void)strcat(buf, bg[i].info);
- /* Add in the social class */
- social_class += (int)(bg[i].bonus) - 50;
-
/* Enter the next chart */
chart = bg[i].next;
}
-
-
- /* Verify social class */
- if (social_class > 100) social_class = 100;
- else if (social_class < 1) social_class = 1;
-
- /* Save the social class */
- p_ptr->sc = social_class;
-
-
/* Skip leading spaces */
for (s = buf; *s == ' '; s++) /* loop */;
@@ -655,89 +622,17 @@ static errr init_randart(void)
}
-/*
- * A helper function for get_ahw(), also called by polymorph code
- */
-void get_height_weight(void)
-{
- int h_mean, h_stddev;
-
- int w_mean, w_stddev;
-
-
- /* Extract mean and standard deviation -- Male */
- if (p_ptr->psex == SEX_MALE)
- {
- h_mean = rp_ptr->m_b_ht + rmp_ptr->m_b_ht;
- h_stddev = rp_ptr->m_m_ht + rmp_ptr->m_m_ht;
-
- w_mean = rp_ptr->m_b_wt + rmp_ptr->m_b_wt;
- w_stddev = rp_ptr->m_m_wt + rmp_ptr->m_m_wt;
- }
-
- /* Female */
- else if (p_ptr->psex == SEX_FEMALE)
- {
- h_mean = rp_ptr->f_b_ht + rmp_ptr->f_b_ht;
- h_stddev = rp_ptr->f_m_ht + rmp_ptr->f_m_ht;
-
- w_mean = rp_ptr->f_b_wt + rmp_ptr->f_b_wt;
- w_stddev = rp_ptr->f_m_wt + rmp_ptr->f_m_wt;
- }
-
- /* Neuter XXX */
- else
- {
- h_mean = (rp_ptr->m_b_ht + rmp_ptr->m_b_ht +
- rp_ptr->f_b_ht + rmp_ptr->f_b_ht) / 2,
- h_stddev = (rp_ptr->m_m_ht + rmp_ptr->m_m_ht +
- rp_ptr->f_m_ht + rmp_ptr->f_m_ht) / 2;
-
- w_mean = (rp_ptr->m_b_wt + rmp_ptr->m_b_wt +
- rp_ptr->f_b_wt + rmp_ptr->f_b_wt) / 2,
- w_stddev = (rp_ptr->m_m_wt + rmp_ptr->m_m_wt +
- rp_ptr->f_m_wt + rmp_ptr->f_m_wt) / 2;
- }
-
- /* Calculate height/weight */
- p_ptr->ht = randnor(h_mean, h_stddev);
- p_ptr->wt = randnor(w_mean, w_stddev);
-
- /* Weight/height shouldn't be negative */
- if (p_ptr->ht < 1) p_ptr->ht = 1;
- if (p_ptr->wt < 1) p_ptr->wt = 1;
-}
-
-
-/*
- * Computes character's age, height, and weight
- */
-static void get_ahw(void)
-{
- /* Calculate the age */
- p_ptr->age = rp_ptr->b_age + rmp_ptr->b_age +
- randint(rp_ptr->m_age + rmp_ptr->m_age);
-
- /* Calculate the height/weight */
- get_height_weight();
-}
-
-
-
/*
* Get the player's starting money
*/
static void get_money(void)
{
- int i, gold;
-
-
- /* Social Class determines starting gold */
- gold = (p_ptr->sc * 6) + randint(100) + 300;
+ /* Starting gold */
+ int gold = randint(100) + 300;
/* Process the stats */
- for (i = 0; i < 6; i++)
+ for (int i = 0; i < 6; i++)
{
/* Mega-Hack -- reduce gold for high stats */
if (stat_use[i] >= 18 + 50) gold -= 300;
@@ -1583,11 +1478,13 @@ static bool_ player_birth_aux_ask()
char c;
- char p2 = ')';
-
char buf[200];
char inp[200];
+ int const NAME_ROW = 2;
+ int const RACE_ROW = 3;
+ int const CLASS_ROW = 4;
+
s16b *class_types;
/*** Intro ***/
@@ -1596,14 +1493,12 @@ static bool_ player_birth_aux_ask()
Term_clear();
/* Title everything */
- put_str("Name :", 2, 1);
- put_str("Sex :", 3, 1);
- put_str("Race :", 4, 1);
- put_str("Class :", 5, 1);
+ put_str("Name :", NAME_ROW, 1);
+ c_put_str(TERM_L_BLUE, player_name, NAME_ROW, 9);
- /* Dump the default name */
- c_put_str(TERM_L_BLUE, player_name, 2, 9);
+ put_str("Race :", RACE_ROW, 1);
+ put_str("Class :", CLASS_ROW, 1);
/*** Instructions ***/
@@ -1649,63 +1544,6 @@ static bool_ player_birth_aux_ask()
/* Clean up */
clear_from(15);
- /*** Player sex ***/
-
- if (do_quick_start)
- {
- k = previous_char.sex;
- }
- else
- {
- /* Extra info */
- Term_putstr(5, 15, -1, TERM_WHITE,
- "Your 'sex' does not have any significant gameplay effects.");
-
- /* Prompt for "Sex" */
- for (n = 0; n < MAX_SEXES; n++)
- {
- /* Analyze */
- p_ptr->psex = n;
- sp_ptr = &sex_info[p_ptr->psex];
-
- /* Display */
- strnfmt(buf, 200, "%c%c %s", I2A(n), p2, sp_ptr->title);
- put_str(buf, 21 + (n / 5), 2 + 15 * (n % 5));
- }
-
- /* Choose */
- while (1)
- {
- strnfmt(buf, 200, "Choose a sex (%c-%c), * for random, = for options: ", I2A(0), I2A(n - 1));
- put_str(buf, 20, 2);
- c = inkey();
- if (c == 'Q') quit(NULL);
- if (c == 'S') return (FALSE);
- if (c == '*')
- {
- k = rand_int(MAX_SEXES);
- break;
- }
- k = (islower(c) ? A2I(c) : -1);
- if ((k >= 0) && (k < n)) break;
- if (c == '?') do_cmd_help();
- else if (c == '=')
- {
- screen_save();
- do_cmd_options_aux(6, "Startup Options", FALSE);
- screen_load();
- }
- else bell();
- }
- }
-
- /* Set sex */
- p_ptr->psex = k;
- sp_ptr = &sex_info[p_ptr->psex];
-
- /* Display */
- c_put_str(TERM_L_BLUE, sp_ptr->title, 3, 9);
-
/* Clean up */
clear_from(15);
@@ -1798,13 +1636,13 @@ static bool_ player_birth_aux_ask()
rp_ptr = &race_info[p_ptr->prace];
/* Display */
- c_put_str(TERM_L_BLUE, rp_ptr->title, 4, 9);
+ c_put_str(TERM_L_BLUE, rp_ptr->title, RACE_ROW, 9);
/* Get a random name */
if (!do_quick_start) create_random_name(p_ptr->prace, player_name);
/* Display */
- c_put_str(TERM_L_BLUE, player_name, 2, 9);
+ c_put_str(TERM_L_BLUE, player_name, NAME_ROW, 9);
/* Clean up */
clear_from(12);
@@ -1927,7 +1765,7 @@ static bool_ player_birth_aux_ask()
/* Display */
auto const race_name = get_player_race_name(p_ptr->prace, p_ptr->pracem);
- c_put_str(TERM_L_BLUE, race_name.c_str(), 4, 9);
+ c_put_str(TERM_L_BLUE, race_name.c_str(), RACE_ROW, 9);
}
}
@@ -2152,7 +1990,7 @@ static bool_ player_birth_aux_ask()
spp_ptr = &class_info[p_ptr->pclass].spec[p_ptr->pspec];
/* Display */
- c_put_str(TERM_L_BLUE, spp_ptr->title, 5, 9);
+ c_put_str(TERM_L_BLUE, spp_ptr->title, CLASS_ROW, 9);
/* Clean up */
clear_from(15);
@@ -2485,9 +2323,6 @@ static bool_ player_birth_aux_point(void)
/* Roll for base hitpoints */
get_extra();
- /* Roll for age/height/weight */
- get_ahw();
-
/* Roll for social class */
get_history();
@@ -2739,15 +2574,14 @@ static bool_ player_birth_aux_auto()
Term_clear();
put_str("Name :", 2, 1);
- put_str("Sex :", 3, 1);
- put_str("Race :", 4, 1);
- put_str("Class:", 5, 1);
-
c_put_str(TERM_L_BLUE, player_name, 2, 9);
- c_put_str(TERM_L_BLUE, sp_ptr->title, 3, 9);
+
+ put_str("Race :", 3, 1);
auto const player_race_name = get_player_race_name(p_ptr->prace, p_ptr->pracem);
- c_put_str(TERM_L_BLUE, player_race_name.c_str(), 4, 9);
- c_put_str(TERM_L_BLUE, spp_ptr->title, 5, 9);
+ c_put_str(TERM_L_BLUE, player_race_name.c_str(), 3, 9);
+
+ put_str("Class:", 4, 1);
+ c_put_str(TERM_L_BLUE, spp_ptr->title, 4, 9);
/* Label stats */
put_str("STR:", 2 + A_STR, 61);
@@ -2839,9 +2673,6 @@ static bool_ player_birth_aux_auto()
/* Roll for base hitpoints */
get_extra();
- /* Roll for age/height/weight */
- get_ahw();
-
/* Roll for social class */
get_history();
diff --git a/src/birth.hpp b/src/birth.hpp
index dd5ff850..af361499 100644
--- a/src/birth.hpp
+++ b/src/birth.hpp
@@ -5,6 +5,5 @@
extern void print_desc_aux(cptr txt, int y, int x);
extern void save_savefile_names(void);
extern bool_ begin_screen(void);
-extern void get_height_weight(void);
extern void player_birth(void);
extern bool_ no_begin_screen;
diff --git a/src/birther.hpp b/src/birther.hpp
index f517fb9d..566bcb42 100644
--- a/src/birther.hpp
+++ b/src/birther.hpp
@@ -7,7 +7,6 @@
*/
struct birther
{
- s16b sex;
s16b race;
s16b rmod;
s16b pclass;
@@ -19,11 +18,6 @@ struct birther
s32b grace;
s32b god_favor;
- s16b age;
- s16b wt;
- s16b ht;
- s16b sc;
-
s32b au;
s16b stat[6];
diff --git a/src/cmd5.cc b/src/cmd5.cc
index a1dd5cbf..9870f116 100644
--- a/src/cmd5.cc
+++ b/src/cmd5.cc
@@ -298,25 +298,6 @@ void do_poly_self(void)
/* Some form of racial polymorph... */
power -= 10;
- if ((power > rand_int(5)) && (rand_int(4) == 0))
- {
- /* sex change */
- power -= 2;
-
- if (p_ptr->psex == SEX_MALE)
- {
- p_ptr->psex = SEX_FEMALE;
- sp_ptr = &sex_info[p_ptr->psex];
- strcpy(effect_msg, "female");
- }
- else
- {
- p_ptr->psex = SEX_MALE;
- sp_ptr = &sex_info[p_ptr->psex];
- strcpy(effect_msg, "male");
- }
- }
-
if ((power > rand_int(30)) && (rand_int(5) == 0))
{
int tmp = 0;
@@ -398,10 +379,7 @@ void do_poly_self(void)
/* Experience factor */
p_ptr->expfact = rp_ptr->r_exp + rmp_ptr->r_exp + cp_ptr->c_exp;
- /* Calculate the height/weight */
- get_height_weight();
-
-
+ /* Level up if necessary */
check_experience();
p_ptr->max_plv = p_ptr->lev;
diff --git a/src/defines.h b/src/defines.h
index b722d29a..5309023f 100644
--- a/src/defines.h
+++ b/src/defines.h
@@ -130,11 +130,6 @@
#define STORE_GENERAL 0
#define STORE_HOME 7
-/*
- * Maximum number of player "sex" types (see "table.c", etc)
- */
-#define MAX_SEXES 3
-
/* Number of Random Artifacts */
#define MAX_RANDARTS 84
#define MAX_T_ACT 51
@@ -383,14 +378,6 @@
#define MAX_STACK_SIZE 100
-/*
- * Player sex constants (hard-coded by save-files, arrays, etc)
- */
-#define SEX_FEMALE 0
-#define SEX_MALE 1
-#define SEX_NEUTER 2
-
-
/* Race flags */
#define PR1_EXPERIMENTAL 0x00000001L /* Is still under developemnt */
/* XXX */
@@ -2234,15 +2221,8 @@
#define TRAP_OF_DROP_ALL_ITEMS 141
#define TRAP_OF_DROP_EVERYTHING 142
-/* -SC- */
-#define TRAP_OF_FEMINITY 150
-#define TRAP_OF_MASCULINITY 151
-#define TRAP_OF_NEUTRALITY 152
-#define TRAP_OF_AGING 153
-#define TRAP_OF_GROWING 154
-#define TRAP_OF_SHRINKING 155
#define TRAP_OF_ELDRITCH_HORROR 156
-/* XXX */
+
#define TRAP_OF_DIVINE_ANGER 158
#define TRAP_OF_DIVINE_WRATH 159
#define TRAP_OF_HALLUCINATION 160
diff --git a/src/dungeon.cc b/src/dungeon.cc
index 41aa6bf6..bf14926e 100644
--- a/src/dungeon.cc
+++ b/src/dungeon.cc
@@ -5460,12 +5460,6 @@ void play_game()
{
cheat_death = TRUE;
- /* Mark social class, reset age, if needed */
- if (p_ptr->sc) p_ptr->sc = p_ptr->age = 0;
-
- /* Increase age */
- p_ptr->age++;
-
/* Mark savefile */
noscore |= 0x0001;
msg_print("You invoke wizard mode and cheat death.");
diff --git a/src/files.cc b/src/files.cc
index be1e208a..576b8143 100644
--- a/src/files.cc
+++ b/src/files.cc
@@ -2190,41 +2190,20 @@ void display_player(int mode)
/* Name, Sex, Race, Class */
put_str("Name :", 2, 1);
- put_str("Sex :", 3, 1);
- put_str("Race :", 4, 1);
- put_str("Class :", 5, 1);
- put_str("Body :", 6, 1);
- put_str("God :", 7, 1);
c_put_str(TERM_L_BLUE, player_name, 2, 9);
- if (p_ptr->body_monster != 0)
- {
- monster_race *r_ptr = &r_info[p_ptr->body_monster];
- char tmp[12];
-
- if ((r_ptr->flags1 & RF1_MALE) != 0)
- strcpy(tmp, "Male");
- else if ((r_ptr->flags1 & RF1_FEMALE) != 0)
- strcpy(tmp, "Female");
- else
- strcpy(tmp, "Neuter");
- c_put_str(TERM_L_BLUE, tmp, 3, 9);
- }
- else
- {
- c_put_str(TERM_L_BLUE, sp_ptr->title, 3, 9);
- }
+ put_str("Race :", 3, 1);
auto const player_race_name = get_player_race_name(p_ptr->prace, p_ptr->pracem);
- c_put_str(TERM_L_BLUE, player_race_name.c_str(), 4, 9);
- c_put_str(TERM_L_BLUE, spp_ptr->title, 5, 9);
- c_put_str(TERM_L_BLUE, r_ptr->name, 6, 9);
- c_put_str(TERM_L_BLUE, deity_info[p_ptr->pgod].name, 7, 9);
+ c_put_str(TERM_L_BLUE, player_race_name.c_str(), 3, 9);
+
+ put_str("Class :", 4, 1);
+ c_put_str(TERM_L_BLUE, spp_ptr->title, 4, 9);
+
+ put_str("Body :", 5, 1);
+ c_put_str(TERM_L_BLUE, r_ptr->name, 5, 9);
- /* Age, Height, Weight, Social */
- prt_num("Age ", (int)p_ptr->age + bst(YEAR, turn), 2, 32, TERM_L_BLUE, " ");
- prt_num("Height ", (int)p_ptr->ht, 3, 32, TERM_L_BLUE, " ");
- prt_num("Weight ", (int)p_ptr->wt, 4, 32, TERM_L_BLUE, " ");
- prt_num("Social Class ", (int)p_ptr->sc, 5, 32, TERM_L_BLUE, " ");
+ put_str("God :", 6, 1);
+ c_put_str(TERM_L_BLUE, deity_info[p_ptr->pgod].name, 6, 9);
/* Display the stats */
for (i = 0; i < 6; i++)
@@ -4858,7 +4837,6 @@ static errr top_twenty(void)
sprintf(the_score.who, "%-.15s", player_name);
/* Save the player info XXX XXX XXX */
- sprintf(the_score.sex, "%c", (p_ptr->psex ? 'm' : 'f'));
sprintf(the_score.p_r, "%2d", p_ptr->prace);
sprintf(the_score.p_s, "%2d", p_ptr->pracem);
sprintf(the_score.p_c, "%2d", p_ptr->pclass);
@@ -4959,7 +4937,6 @@ static errr predict_score(void)
sprintf(the_score.who, "%-.15s", player_name);
/* Save the player info XXX XXX XXX */
- sprintf(the_score.sex, "%c", (p_ptr->psex ? 'm' : 'f'));
sprintf(the_score.p_r, "%2d", p_ptr->prace);
sprintf(the_score.p_s, "%2d", p_ptr->pracem);
sprintf(the_score.p_c, "%2d", p_ptr->pclass);
@@ -5106,7 +5083,7 @@ static void kingly(void)
/* Display a message */
put_str("Veni, Vidi, Vici!", 15, 26);
put_str("I came, I saw, I conquered!", 16, 21);
- put_str(format("All Hail the Mighty %s!", sp_ptr->winner), 17, 22);
+ put_str(format("All Hail the Mighty %s!", player_name), 17, 22);
/* Flush input */
flush();
diff --git a/src/hiscore.hpp b/src/hiscore.hpp
index 0b1b713d..990c91aa 100644
--- a/src/hiscore.hpp
+++ b/src/hiscore.hpp
@@ -36,7 +36,6 @@ struct high_score
char unused_1[8]; /* Kept for compatibility only */
- char sex[2]; /* Player Sex (string) */
char p_r[3]; /* Player Race (number) */
char p_s[3]; /* Player Subrace (number) */
char p_c[3]; /* Player Class (number) */
diff --git a/src/init1.cc b/src/init1.cc
index 9d221c01..31e8c55a 100644
--- a/src/init1.cc
+++ b/src/init1.cc
@@ -2026,30 +2026,6 @@ errr init_player_info_txt(FILE *fp)
continue;
}
- /* Process 'M' for "Mods" */
- if ((buf[0] == 'R') && (buf[2] == 'M'))
- {
- int s[10];
-
- /* Scan for the values */
- if (10 != sscanf(buf + 4, "%d:%d:%d:%d:%d:%d:%d:%d:%d:%d",
- &s[0], &s[1], &s[2], &s[3], &s[4], &s[5], &s[6], &s[7], &s[8], &s[9])) return (1);
-
- rp_ptr->b_age = s[0];
- rp_ptr->m_age = s[1];
- rp_ptr->m_b_ht = s[2];
- rp_ptr->m_m_ht = s[3];
- rp_ptr->m_b_wt = s[4];
- rp_ptr->m_m_wt = s[5];
- rp_ptr->f_b_ht = s[6];
- rp_ptr->f_m_ht = s[7];
- rp_ptr->f_b_wt = s[8];
- rp_ptr->f_m_wt = s[9];
-
- /* Next... */
- continue;
- }
-
/* Process 'P' for "xtra" */
if ((buf[0] == 'R') && (buf[2] == 'P'))
{
@@ -2392,30 +2368,6 @@ errr init_player_info_txt(FILE *fp)
continue;
}
- /* Process 'M' for "Mods" */
- if ((buf[0] == 'S') && (buf[2] == 'M'))
- {
- int s[10];
-
- /* Scan for the values */
- if (10 != sscanf(buf + 4, "%d:%d:%d:%d:%d:%d:%d:%d:%d:%d",
- &s[0], &s[1], &s[2], &s[3], &s[4], &s[5], &s[6], &s[7], &s[8], &s[9])) return (1);
-
- rmp_ptr->b_age = s[0];
- rmp_ptr->m_age = s[1];
- rmp_ptr->m_b_ht = s[2];
- rmp_ptr->m_m_ht = s[3];
- rmp_ptr->m_b_wt = s[4];
- rmp_ptr->m_m_wt = s[5];
- rmp_ptr->f_b_ht = s[6];
- rmp_ptr->f_m_ht = s[7];
- rmp_ptr->f_b_wt = s[8];
- rmp_ptr->f_m_wt = s[9];
-
- /* Next... */
- continue;
- }
-
/* Process 'P' for "xtra" */
if ((buf[0] == 'S') && (buf[2] == 'P'))
{
diff --git a/src/loadsave.cc b/src/loadsave.cc
index 4c313901..d358e271 100644
--- a/src/loadsave.cc
+++ b/src/loadsave.cc
@@ -259,7 +259,6 @@ static void do_quick_start(ls_flag_t flag)
u32b tmp32u;
int i;
- do_s16b(&previous_char.sex, flag);
do_s16b(&previous_char.race, flag);
do_s16b(&previous_char.rmod, flag);
do_s16b(&previous_char.pclass, flag);
@@ -267,10 +266,6 @@ static void do_quick_start(ls_flag_t flag)
do_byte(&previous_char.quests, flag);
do_byte(&previous_char.god, flag);
do_s32b(&previous_char.grace, flag);
- do_s16b(&previous_char.age, flag);
- do_s16b(&previous_char.wt, flag);
- do_s16b(&previous_char.ht, flag);
- do_s16b(&previous_char.sc, flag);
do_s32b(&previous_char.au, flag);
for (i = 0; i < 6; i++) do_s16b(&(previous_char.stat[i]), flag);
@@ -334,19 +329,6 @@ static void do_subrace(ls_flag_t flag)
do_byte((byte*)&sr_ptr->r_mhp, flag);
do_s16b(&sr_ptr->r_exp, flag);
- do_byte((byte*)&sr_ptr->b_age, flag);
- do_byte((byte*)&sr_ptr->m_age, flag);
-
- do_byte((byte*)&sr_ptr->m_b_ht, flag);
- do_byte((byte*)&sr_ptr->m_m_ht, flag);
- do_byte((byte*)&sr_ptr->f_b_ht, flag);
- do_byte((byte*)&sr_ptr->f_m_ht, flag);
-
- do_byte((byte*)&sr_ptr->m_b_wt, flag);
- do_byte((byte*)&sr_ptr->m_m_wt, flag);
- do_byte((byte*)&sr_ptr->f_b_wt, flag);
- do_byte((byte*)&sr_ptr->f_m_wt, flag);
-
do_byte((byte*)&sr_ptr->infra, flag);
for (i = 0; i < 4; i++)
@@ -513,7 +495,6 @@ static bool_ do_extra(ls_flag_t flag)
do_byte(&p_ptr->pracem, flag);
do_byte(&p_ptr->pclass, flag);
do_byte(&p_ptr->pspec, flag);
- do_byte(&p_ptr->psex, flag);
do_u16b(&tmp16b, flag);
do_u16b(&tmp16b, flag);
do_byte(&p_ptr->mimic_form, flag);
@@ -523,10 +504,6 @@ static bool_ do_extra(ls_flag_t flag)
do_byte(&p_ptr->hitdie, flag);
do_u16b(&p_ptr->expfact, flag);
- do_s16b(&p_ptr->age, flag);
- do_s16b(&p_ptr->ht, flag);
- do_s16b(&p_ptr->wt, flag);
-
/* Dump the stats (maximum and current) */
for (i = 0; i < 6; ++i) do_s16b(&p_ptr->stat_max[i], flag);
for (i = 0; i < 6; ++i) do_s16b(&p_ptr->stat_cur[i], flag);
@@ -696,7 +673,6 @@ static bool_ do_extra(ls_flag_t flag)
/* More info */
tmp16s = 0;
- do_s16b(&p_ptr->sc, flag);
do_s16b(&p_ptr->blind, flag);
do_s16b(&p_ptr->paralyzed, flag);
do_s16b(&p_ptr->confused, flag);
@@ -2261,7 +2237,6 @@ static void junkinit(void)
static void morejunk(void)
{
- sp_ptr = &sex_info[p_ptr->psex]; /* Sex */
rp_ptr = &race_info[p_ptr->prace]; /* Raceclass */
rmp_ptr = &race_mod_info[p_ptr->pracem];
cp_ptr = &class_info[p_ptr->pclass];
diff --git a/src/player_race.hpp b/src/player_race.hpp
index edb304f2..3be39bdf 100644
--- a/src/player_race.hpp
+++ b/src/player_race.hpp
@@ -29,19 +29,6 @@ struct player_race
byte r_mhp; /* Race hit-dice modifier */
u16b r_exp; /* Race experience factor */
- byte b_age; /* base age */
- byte m_age; /* mod age */
-
- byte m_b_ht; /* base height (males) */
- byte m_m_ht; /* mod height (males) */
- byte m_b_wt; /* base weight (males) */
- byte m_m_wt; /* mod weight (males) */
-
- byte f_b_ht; /* base height (females) */
- byte f_m_ht; /* mod height (females) */
- byte f_b_wt; /* base weight (females) */
- byte f_m_wt; /* mod weight (females) */
-
byte infra; /* Infra-vision range */
u32b choice[2]; /* Legal class choices */
diff --git a/src/player_race_mod.hpp b/src/player_race_mod.hpp
index ed48356e..9f21b253 100644
--- a/src/player_race_mod.hpp
+++ b/src/player_race_mod.hpp
@@ -29,19 +29,6 @@ struct player_race_mod
char r_mhp; /* (+) Race mod hit-dice modifier */
s16b r_exp; /* (+) Race mod experience factor */
- char b_age; /* (+) base age */
- char m_age; /* (+) mod age */
-
- char m_b_ht; /* (+) base height (males) */
- char m_m_ht; /* (+) mod height (males) */
- char m_b_wt; /* (+) base weight (males) */
- char m_m_wt; /* (+) mod weight (males) */
-
- char f_b_ht; /* (+) base height (females) */
- char f_m_ht; /* (+) mod height (females) */
- char f_b_wt; /* (+) base weight (females) */
- char f_m_wt; /* (+) mod weight (females) */
-
char infra; /* (+) Infra-vision range */
u32b choice[2]; /* Legal race choices */
diff --git a/src/player_sex.hpp b/src/player_sex.hpp
deleted file mode 100644
index 5722f1a4..00000000
--- a/src/player_sex.hpp
+++ /dev/null
@@ -1,17 +0,0 @@
-#pragma once
-
-/**
- * Player sex descriptor.
- */
-struct player_sex
-{
- /**
- * Type of sex.
- */
- char const *title;
-
- /**
- * Winner title.
- */
- char const *winner;
-};
diff --git a/src/player_sex_fwd.hpp b/src/player_sex_fwd.hpp
deleted file mode 100644
index eabea488..00000000
--- a/src/player_sex_fwd.hpp
+++ /dev/null
@@ -1,3 +0,0 @@
-#pragma once
-
-struct player_sex;
diff --git a/src/player_type.hpp b/src/player_type.hpp
index d9410dcb..4caa1e7b 100644
--- a/src/player_type.hpp
+++ b/src/player_type.hpp
@@ -32,7 +32,6 @@ struct player_type
s16b py; /* Player location */
s16b px; /* Player location */
- byte psex; /* Sex index */
byte prace; /* Race index */
byte pracem; /* Race Mod index */
byte pclass; /* Class index */
@@ -50,12 +49,6 @@ struct player_type
byte special; /* Special levels */
byte allow_one_death; /* Blood of life */
- s16b age; /* Characters age */
- s16b ht; /* Height */
- s16b wt; /* Weight */
- s16b sc; /* Social Class */
-
-
s32b au; /* Current Gold */
s32b max_exp; /* Max experience */
diff --git a/src/q_main.cc b/src/q_main.cc
index ed11b9dc..b81ba9b3 100644
--- a/src/q_main.cc
+++ b/src/q_main.cc
@@ -105,7 +105,7 @@ static bool_ quest_morgoth_dump_hook(void *, void *in_, void *)
if (quest[QUEST_MORGOTH].status >= QUEST_STATUS_COMPLETED)
{
if (quest[QUEST_ONE].status == QUEST_STATUS_FINISHED)
- fprintf(f, "\n You saved Arda and became a famed %s.", sp_ptr->winner);
+ fprintf(f, "\n You saved Arda and became a famed hero.");
else
fprintf(f, "\n You became a new force of darkness and enslaved all free people.");
}
diff --git a/src/tables.cc b/src/tables.cc
index 09e6c18c..24328ac9 100644
--- a/src/tables.cc
+++ b/src/tables.cc
@@ -1144,29 +1144,6 @@ s32b player_exp[PY_MAX_LEVEL] =
/*
- * Player Sexes
- *
- * Title,
- * Winner
- */
-player_sex sex_info[MAX_SEXES] =
-{
- {
- "Female",
- "Queen"
- },
-
-{
-"Male",
-"King"
-},
-{
-"Neuter",
-"Ruler"
-}
-};
-
-/*
* Hack -- the "basic" color names (see "TERM_xxx")
*/
cptr color_names[16] =
diff --git a/src/tables.hpp b/src/tables.hpp
index 4a3e33d6..aee776bd 100644
--- a/src/tables.hpp
+++ b/src/tables.hpp
@@ -15,7 +15,6 @@
#include "move_info_type.hpp"
#include "option_type.hpp"
#include "player_defs.hpp"
-#include "player_sex.hpp"
#include "power_type.hpp"
#include "powers.hpp"
#include "quest_type.hpp"
@@ -49,7 +48,6 @@ extern byte adj_con_mhp[];
extern byte blows_table[12][12];
extern byte extract_energy[300];
extern s32b player_exp[PY_MAX_LEVEL];
-extern player_sex sex_info[MAX_SEXES];
extern cptr color_names[16];
extern cptr stat_names[6];
extern cptr stat_names_reduced[6];
diff --git a/src/traps.cc b/src/traps.cc
index 99428cf9..9c9f2b64 100644
--- a/src/traps.cc
+++ b/src/traps.cc
@@ -461,16 +461,6 @@ static bool_ player_handle_breath_trap(s16b rad, s16b type, u16b trap)
}
/*
- * This function damages the player by a trap
- */
-static void trap_hit(s16b trap)
-{
- trap_type *t_ptr = &t_info[trap];
- s16b dam = damroll(t_ptr->dd, t_ptr->ds);
- take_hit(dam, t_ptr->name);
-}
-
-/*
* this function activates one trap type, and returns
* a bool_ indicating if this trap is now identified
*/
@@ -1823,76 +1813,6 @@ bool_ player_activate_trap_type(s16b y, s16b x, object_type *i_ptr, s16b item)
ident = player_handle_breath_trap(3, GF_GRAVITY, TRAP_OF_GRAVITY_BALL);
break;
- /* -SC- */
- case TRAP_OF_FEMINITY:
- {
- msg_print("Gas sprouts out... you feel yourself transmute.");
- p_ptr->psex = SEX_FEMALE;
- sp_ptr = &sex_info[p_ptr->psex];
- ident = TRUE;
- trap_hit(trap);
- break;
- }
-
- case TRAP_OF_MASCULINITY:
- {
- msg_print("Gas sprouts out... you feel yourself transmute.");
- p_ptr->psex = SEX_MALE;
- sp_ptr = &sex_info[p_ptr->psex];
- ident = TRUE;
- trap_hit(trap);
- break;
- }
-
- case TRAP_OF_NEUTRALITY:
- {
- msg_print("Gas sprouts out... you feel yourself transmute.");
- p_ptr->psex = SEX_NEUTER;
- sp_ptr = &sex_info[p_ptr->psex];
- ident = TRUE;
- trap_hit(trap);
- break;
- }
-
- case TRAP_OF_AGING:
- {
- msg_print("Colors are scintillating around you. "
- "You see your past running before your eyes.");
- p_ptr->age += randint((rp_ptr->b_age + rmp_ptr->b_age) / 2);
- ident = TRUE;
- trap_hit(trap);
- break;
- }
-
- case TRAP_OF_GROWING:
- {
- s16b tmp;
-
- msg_print("Heavy fumes sprout out... you feel yourself transmute.");
- if (p_ptr->psex == SEX_FEMALE) tmp = rp_ptr->f_b_ht + rmp_ptr->f_b_ht;
- else tmp = rp_ptr->m_b_ht + rmp_ptr->m_b_ht;
-
- p_ptr->ht += randint(tmp / 4);
- ident = TRUE;
- trap_hit(trap);
- break;
- }
-
- case TRAP_OF_SHRINKING:
- {
- s16b tmp;
-
- msg_print("Heavy fumes sprout out... you feel yourself transmute.");
- if (p_ptr->psex == SEX_FEMALE) tmp = rp_ptr->f_b_ht + rmp_ptr->f_b_ht;
- else tmp = rp_ptr->m_b_ht + rmp_ptr->m_b_ht;
-
- p_ptr->ht -= randint(tmp / 4);
- if (p_ptr->ht <= tmp / 4) p_ptr->ht = tmp / 4;
- ident = TRUE;
- trap_hit(trap);
- break;
- }
-
/* Trap of Divine Anger */
case TRAP_OF_DIVINE_ANGER:
{
diff --git a/src/variable.cc b/src/variable.cc
index f0d18111..98d2c1c0 100644
--- a/src/variable.cc
+++ b/src/variable.cc
@@ -469,7 +469,6 @@ player_type *p_ptr = nullptr;
* Pointer to the player tables
* (sex, race, race mod, class, magic)
*/
-player_sex *sp_ptr;
player_race *rp_ptr;
player_race_mod *rmp_ptr;
player_class *cp_ptr;
diff --git a/src/variable.hpp b/src/variable.hpp
index 877a5597..3723a8fb 100644
--- a/src/variable.hpp
+++ b/src/variable.hpp
@@ -24,7 +24,6 @@
#include "player_defs.hpp"
#include "player_race_fwd.hpp"
#include "player_race_mod_fwd.hpp"
-#include "player_sex_fwd.hpp"
#include "player_spec_fwd.hpp"
#include "player_type_fwd.hpp"
#include "randart_gen_type_fwd.hpp"
@@ -184,7 +183,6 @@ extern byte tval_to_attr[128];
extern char tval_to_char[128];
extern char *keymap_act[KEYMAP_MODES][256];
extern player_type *p_ptr;
-extern player_sex *sp_ptr;
extern player_race *rp_ptr;
extern player_race_mod *rmp_ptr;
extern player_class *cp_ptr;