Loading standard equipment for new characters.

  • Coffee
  • Coffee's Avatar Topic Author
  • Offline
  • Fresh Boarder
  • Fresh Boarder
More
4 years 3 weeks ago - 4 years 2 weeks ago #4871 by Coffee
Coffee created the topic: Loading standard equipment for new characters.

Attachment tbaMUD-Newbie-Equipment.txt not found


1. Change void do_start(struct char_data *ch); to void do_start(struct char_data *ch, int newbie); at class.h.

2. Change do_start(victim); to do_start(victim, NO); at the function ACMD(do_advance) in act.wizard.c.

3. Change do_start(d->character); to do_start(d->character, YES); at the function void nanny(struct descriptor_data *d, char *arg) in interpreter.c.

4. Change void do_start(struct char_data *ch); to void do_start(struct char_data *ch, int newbie); at class.c. Also add the following lines at the end of the function.

if (newbie == YES) {
obj_to_char(read_object(40000,VIRTUAL),ch);
obj_to_char(read_object(40001,VIRTUAL),ch);
obj_to_char(read_object(40002,VIRTUAL),ch);
obj_to_char(read_object(40003,VIRTUAL),ch);
obj_to_char(read_object(40004,VIRTUAL),ch);
obj_to_char(read_object(40005,VIRTUAL),ch);
obj_to_char(read_object(40006,VIRTUAL),ch);
obj_to_char(read_object(40007,VIRTUAL),ch);
}

Notes: 40000 to 40007 are the obj vnum for Newbie Equipment which I want new players to have on my tbaMUD.
Attachments:
Last Edit: 4 years 2 weeks ago by Coffee. Reason: adding attachment file
The following user(s) said Thank You: thomas

Please Log in or Create an account to join the conversation.

Time to create page: 1.341 seconds