new_prompt.diff update for bpl14?

From: Advanced Computer Services (acs@avsia.com)
Date: 06/08/00


I am currently trying to add new_prompt.diff to a copy of bpl14 and it seems
that everything is in and working except a small portion in comm.c
make_prompt. since there has been a good deal of change in this area since
bpl11, could anyone clue me in as to how this portion of the patch can be
shimmed in there? If someone could please spare a few mins and help me out
with this one...

Code Follows...

make_prompt portion of new_prompt.diff:

***************
*** 831,854 ****
            d->showstr_page, d->showstr_count);
      write_to_descriptor(d->descriptor, prompt);
    } else if (!d->connected) {
!     char prompt[MAX_INPUT_LENGTH];
!
!     *prompt = '\0';
!
!     if (GET_INVIS_LEV(d->character))
!       sprintf(prompt, "i%d ", GET_INVIS_LEV(d->character));

--- snip ---

!     if (PRF_FLAGGED(d->character, PRF_DISPMOVE))
!       sprintf(prompt, "%s%dV ", prompt, GET_MOVE(d->character));
!
!     strcat(prompt, "> ");
!     write_to_descriptor(d->descriptor, prompt);
    }
  }

--- 1060,1066 ----
            d->showstr_page, d->showstr_count);
      write_to_descriptor(d->descriptor, prompt);
    } else if (!d->connected) {
!     write_to_descriptor(d->descriptor, prompt_str(d->character));
    }
  }

comm.c  make_prompt
char *make_prompt(struct descriptor_data *d)
{
  static char prompt[256];

  /* Note, prompt is truncated at MAX_PROMPT_LENGTH chars (structs.h )*/

  if (d->showstr_count)
    sprintf(prompt,
            "\r[ Return to continue, (q)uit, (r)efresh, (b)ack, or page
number (%d/%d) ]",
            d->showstr_page, d->showstr_count);
  else if (d->str)
    strcpy(prompt, "] ");
  else if (STATE(d) == CON_PLAYING && !IS_NPC(d->character)) {
    *prompt = '\0';

    if (GET_INVIS_LEV(d->character))
      sprintf(prompt, "i%d ", GET_INVIS_LEV(d->character));

--- snip ---

    if (PRF_FLAGGED(d->character, PRF_DISPMOVE))
      sprintf(prompt + strlen(prompt), "%dV ", GET_MOVE(d->character));

    strcat(prompt, "> ");
  } else if (STATE(d) == CON_PLAYING && IS_NPC(d->character))
    sprintf(prompt, "%s> ", GET_NAME(d->character));
  else
    *prompt = '\0';

  return prompt;
}



thanx in advance for any help on this one...

P Ahrens


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



This archive was generated by hypermail 2b30 : 04/10/01 PDT