Removed hometown and languages. --Rumble

This commit is contained in:
Rumble 2007-05-15 03:11:08 +00:00
parent bfa47111db
commit 2f24e37bb8
15 changed files with 24 additions and 42 deletions

View file

@ -1009,7 +1009,8 @@ int search_help(char *argument, int level)
while (level < help_table[mid].min_level && mid < (bot + top) / 2)
mid++;
if (strn_cmp(argument, help_table[mid].keywords, minlen) || level < help_table[mid].min_level)
// if (strn_cmp(argument, help_table[mid].keywords, minlen) || level < help_table[mid].min_level)
if (strn_cmp(argument, help_table[mid].keywords, minlen))
break;
return mid;
@ -1054,8 +1055,7 @@ ACMD(do_help)
for (i = 0; i <= top_of_h_table; i++) {
if (help_table[i].min_level > GET_LEVEL(ch))
continue;
/* to help narrow down results, if they don't
start with the same letters, move on */
/* To help narrow down results, if they don't start with the same letters, move on. */
if (*argument != *help_table[i].keywords)
continue;
if (levenshtein_distance(argument, help_table[i].keywords) <= 2) {

View file

@ -825,8 +825,7 @@ void do_stat_character(struct char_data *ch, struct char_data *k)
buf1, buf2, k->player.time.played / 3600,
((k->player.time.played % 3600) / 60), age(k)->year);
send_to_char(ch, "Hometown: [%d], Speaks: [%d/%d/%d], (STL[%d]/per[%d]/NSTL[%d])",
k->player.hometown, GET_TALK(k, 0), GET_TALK(k, 1), GET_TALK(k, 2),
send_to_char(ch, "STL[%d]/per[%d]/NSTL[%d]",
GET_PRACTICES(k), int_app[GET_INT(k)].learn,
wis_app[GET_WIS(k)].bonus);
/* Display OLC zone for immorts. */

View file

@ -2573,7 +2573,7 @@ char *act(const char *str, int hide_invisible, struct char_data *ch,
char buf[MAX_STRING_LENGTH];
for (i = descriptor_list; i; i = i->next) {
if (!IS_NPC(i->character) && !i->connected && i->character &&
if (!i->connected && i->character &&
!PRF_FLAGGED(i->character, PRF_NOGOSS) &&
!PLR_FLAGGED(i->character, PLR_WRITING) &&
!ROOM_FLAGGED(IN_ROOM(i->character), ROOM_SOUNDPROOF)) {

View file

@ -2901,12 +2901,8 @@ void init_char(struct char_data *ch)
ch->player.time.logon = time(0);
ch->player.time.played = 0;
GET_HOME(ch) = 1;
GET_AC(ch) = 100;
for (i = 0; i < MAX_TONGUE; i++)
GET_TALK(ch, i) = 0;
/* Bias the height and weight of the character depending on what gender
* they have chosen. While it is possible to have a tall, heavy female it's
* not as likely as a male. Height is in centimeters. Weight is in pounds.

View file

@ -371,7 +371,7 @@ ACMD(do_mload)
return;
}
char_to_room(mob, rnum);
if (SCRIPT(ch)) { // it _should_ have, but it might be detached.
if (SCRIPT(ch)) { /* It _should_ have, but it might be detached. */
char buf[MAX_INPUT_LENGTH];
sprintf(buf, "%c%ld", UID_CHAR, GET_ID(mob));
add_var(&(SCRIPT(ch)->global_vars), "lastloaded", buf, 0);
@ -384,7 +384,7 @@ ACMD(do_mload)
mob_log(ch, "mload: bad object vnum");
return;
}
if (SCRIPT(ch)) { // it _should_ have, but it might be detached.
if (SCRIPT(ch)) { /* It _should_ have, but it might be detached. */
char buf[MAX_INPUT_LENGTH];
sprintf(buf, "%c%ld", UID_CHAR, GET_ID(object));
add_var(&(SCRIPT(ch)->global_vars), "lastloaded", buf, 0);
@ -565,10 +565,7 @@ ACMD(do_mat)
char_to_room(ch, location);
command_interpreter(ch, argument);
/*
* See if 'ch' still exists before continuing!
* Handles 'at XXXX quit' case.
*/
/* See if 'ch' still exists before continuing! Handles 'at XXXX quit' case. */
if (IN_ROOM(ch) == location) {
char_from_room(ch);
char_to_room(ch, original);

View file

@ -480,7 +480,7 @@ OCMD(do_dgoload)
}
char_to_room(mob, rnum);
if (SCRIPT(obj)) { // it _should_ have, but it might be detached.
if (SCRIPT(obj)) { /* It _should_ have, but it might be detached. */
char buf[MAX_INPUT_LENGTH];
sprintf(buf, "%c%ld", UID_CHAR, GET_ID(mob));
add_var(&(SCRIPT(obj)->global_vars), "lastloaded", buf, 0);
@ -495,7 +495,7 @@ OCMD(do_dgoload)
return;
}
if (SCRIPT(obj)) { // it _should_ have, but it might be detached.
if (SCRIPT(obj)) { /* It _should_ have, but it might be detached. */
char buf[MAX_INPUT_LENGTH];
sprintf(buf, "%c%ld", UID_CHAR, GET_ID(object));
add_var(&(SCRIPT(obj)->global_vars), "lastloaded", buf, 0);

View file

@ -1529,7 +1529,7 @@ struct cmdlist_element *find_end(trig_data *trig, struct cmdlist_element *cl)
return c;
/* thanks to Russell Ryan for this fix */
if(!c->next) { //rryan: this is the last line, we didn't find an end
if(!c->next) { /* rryan: this is the last line, we didn't find an end. */
script_log("Trigger VNum %d has 'if' without 'end'. (error 2)", GET_TRIG_VNUM(trig));
return c;
}
@ -1573,7 +1573,7 @@ struct cmdlist_element *find_else_end(trig_data *trig,
return c;
/* thanks to Russell Ryan for this fix */
if(!c->next) { //rryan: this is the last line, return
if(!c->next) { /* rryan: this is the last line, return. */
script_log("Trigger VNum %d has 'if' without 'end'. (error 4)", GET_TRIG_VNUM(trig));
return c;
}

View file

@ -457,7 +457,7 @@ WCMD(do_wload)
return;
}
char_to_room(mob, rnum);
if (SCRIPT(room)) { // it _should_ have, but it might be detached.
if (SCRIPT(room)) { /* It _should_ have, but it might be detached. */
char buf[MAX_INPUT_LENGTH];
sprintf(buf, "%c%ld", UID_CHAR, GET_ID(mob));
add_var(&(SCRIPT(room)->global_vars), "lastloaded", buf, 0);
@ -473,7 +473,7 @@ WCMD(do_wload)
/* special handling to make objects able to load on a person/in a container/worn etc. */
if (!target || !*target) {
obj_to_room(object, real_room(room->number));
if (SCRIPT(room)) { // it _should_ have, but it might be detached.
if (SCRIPT(room)) { /* It _should_ have, but it might be detached. */
char buf[MAX_INPUT_LENGTH];
sprintf(buf, "%c%ld", UID_CHAR, GET_ID(object));
add_var(&(SCRIPT(room)->global_vars), "lastloaded", buf, 0);

View file

@ -728,12 +728,12 @@ void Crash_rentsave(struct char_data *ch, int cost)
int objsave_write_rentcode(FILE *fl, int rentcode, int cost_per_day, struct char_data *ch)
{
if (fprintf(fl, "%d %ld %d %d %d %d\r\n",
rentcode, // rentcode
(long) time(0), // time of save
cost_per_day, // cost per day
GET_GOLD(ch), // current gold balance
GET_BANK_GOLD(ch), // current account balance
0) // number of items - not used atm
rentcode,
(long) time(0),
cost_per_day,
GET_GOLD(ch),
GET_BANK_GOLD(ch),
0)
< 1)
{
perror("Syserr: Writing rent code");

View file

@ -12,7 +12,6 @@
#define PFDEF_SEX 0
#define PFDEF_CLASS 0
#define PFDEF_LEVEL 0
#define PFDEF_HOMETOWN 0
#define PFDEF_HEIGHT 0
#define PFDEF_WEIGHT 0
#define PFDEF_ALIGNMENT 0

View file

@ -224,7 +224,6 @@ int load_char(const char *name, struct char_data *ch)
GET_SEX(ch) = PFDEF_SEX;
GET_CLASS(ch) = PFDEF_CLASS;
GET_LEVEL(ch) = PFDEF_LEVEL;
GET_HOME(ch) = PFDEF_HOMETOWN;
GET_HEIGHT(ch) = PFDEF_HEIGHT;
GET_WEIGHT(ch) = PFDEF_WEIGHT;
GET_ALIGNMENT(ch) = PFDEF_ALIGNMENT;
@ -330,7 +329,6 @@ int load_char(const char *name, struct char_data *ch)
case 'H':
if (!strcmp(tag, "Hit ")) load_HMVS(ch, line, LOAD_HIT);
else if (!strcmp(tag, "Hite")) GET_HEIGHT(ch) = atoi(line);
else if (!strcmp(tag, "Home")) GET_HOME(ch) = atoi(line);
else if (!strcmp(tag, "Host")) GET_HOST(ch) = strdup(line);
else if (!strcmp(tag, "Hrol")) GET_HITROLL(ch) = atoi(line);
else if (!strcmp(tag, "Hung")) GET_COND(ch, HUNGER) = atoi(line);
@ -514,7 +512,6 @@ void save_char(struct char_data * ch)
if (GET_SEX(ch) != PFDEF_SEX) fprintf(fl, "Sex : %d\n", GET_SEX(ch));
if (GET_CLASS(ch) != PFDEF_CLASS) fprintf(fl, "Clas: %d\n", GET_CLASS(ch));
if (GET_LEVEL(ch) != PFDEF_LEVEL) fprintf(fl, "Levl: %d\n", GET_LEVEL(ch));
if (GET_HOME(ch) != PFDEF_HOMETOWN) fprintf(fl, "Home: %d\n", GET_HOME(ch));
fprintf(fl, "Id : %ld\n", GET_IDNUM(ch));
fprintf(fl, "Brth: %ld\n", ch->player.time.birth);

View file

@ -153,7 +153,7 @@ ASPELL(spell_summon)
/* Used by the locate object spell to check the alias list on objects */
int isname_obj(char *search, char *list)
{
char *found_in_list; //but could be something like 'ring' in 'shimmering'
char *found_in_list; /* But could be something like 'ring' in 'shimmering.' */
char searchname[128];
char namelist[MAX_STRING_LENGTH];
int found_pos = -1;

View file

@ -493,7 +493,6 @@
#define MAX_TITLE_LENGTH 80
#define HOST_LENGTH 40
#define PLR_DESC_LENGTH 512
#define MAX_TONGUE 3
#define MAX_SKILLS 200
#define MAX_AFFECT 32
#define MAX_OBJ_AFFECT 6 /* Used in obj_file_elem */
@ -702,7 +701,6 @@ struct char_player_data {
byte sex; /* PC / NPC's sex */
byte chclass; /* PC / NPC's class */
byte level; /* PC / NPC's level */
sh_int hometown; /* PC s Hometown (zone) */
struct time_data time; /* PC's AGE in days */
ubyte weight; /* PC / NPC's weight */
ubyte height; /* PC / NPC's height */
@ -766,7 +764,6 @@ struct char_special_data {
struct player_special_data_saved {
byte skills[MAX_SKILLS+1]; /* array of skills plus skill 0 */
byte PADDING0; /* used to be spells_to_learn */
bool talks[MAX_TONGUE]; /* PC s Tongues 0 for NPC */
int wimp_level; /* Below this # of hit points, flee! */
byte freeze_level; /* Level of god who froze char, if any */
sh_int invis_level; /* level of invisibility */

View file

@ -211,8 +211,6 @@ void convert(char *filename)
fprintf(outfile, "Clas: %d\n", (int)player.chclass);
if (player.level != PFDEF_LEVEL)
fprintf(outfile, "Levl: %d\n", (int)player.level);
if (player.hometown != PFDEF_HOMETOWN)
fprintf(outfile, "Home: %d\n", (int)player.hometown);
fprintf(outfile, "Brth: %d\n", (int)player.birth);
fprintf(outfile, "Plyd: %d\n", (int)player.played);
fprintf(outfile, "Last: %d\n", (int)player.last_logon);

View file

@ -263,7 +263,6 @@ void char_from_furniture(struct char_data *ch);
GET_LEVEL(ch))
#define GET_CLASS(ch) ((ch)->player.chclass)
#define GET_HOME(ch) ((ch)->player.hometown)
#define GET_HEIGHT(ch) ((ch)->player.height)
#define GET_WEIGHT(ch) ((ch)->player.weight)
#define GET_SEX(ch) ((ch)->player.sex)