[SUMMARY] continuation of set_title

From: Crimson Wizard (cwizard@GIBLETS.COM)
Date: 07/09/97


For those of you that where interested, I removed the GET_NAME variable
from do_who and the look routines, so that players could set their title
to something that didn't have to look like it was starting with their
name... but this of course breaks the part of class.c that sets your title
to NULL when you raise a level (if you are using the arrays in class.c
that define xp needed, and title).  The following is a workaround to that
problem, it may be messy but it works for me:

This is laid on in a patch type fasion, you need to modify set_title in
limits.c to do this:

  void set_title(struct char_data * ch, char *title)
  {
+   char title2[60]; /* I haven't checked if MAX_TITLE_LENGTH works */

    if (title == NULL)
-     title = READ_TITLE(ch);
+     sprintf(title2,"%s %s", GET_NAME(ch), READ_TITLE(ch));
+     title = title2;

    if (strlen(title) > MAX_TITLE_LENGTH)
      title[MAX_TITLE_LENGTH] = '\0';

    if (GET_TITLE(ch) != NULL)
      free(GET_TITLE(ch));

    GET_TITLE(ch) = str_dup(title);
  }

Thanks to everyone that replied, I hope this helps someone else.

Crimson Wizard, National Association of Gibbed Players
Clan Bong: Phear It
------------------------------------------------------
Email: cwizard@giblets.com
Web: http://www.giblets.com


      +-----------------------------------------------------------+
      | Ensure that you have read the CircleMUD Mailing List FAQ: |
      |   http://cspo.queensu.ca/~fletcher/Circle/list-faq.html   |
      +-----------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/08/00 PST