Greet progs with titles

For builders to discuss and ask building questions.
Post Reply
Elwin
Sword Master
Sword Master
Posts: 171
Joined: Wed Dec 31, 2003 8:28 pm
Location: Ardeep
Contact:

Greet progs with titles

Post by Elwin » Sun Dec 18, 2005 6:13 pm

I was thinking about this a while back, but I'm not quite sure how it would be done. I was wanting to make sort of a title system for the fighter's guild in Zhentil Keep. The way it would work would be that when a fighter walks into the recruiter's office, based on his level, he will get a certain greeting, like "Here comes another noname whelp" or "says waveringly "Hello there, sir" or even a type of title system. My basic question is how this would work, especially if they're given a certain title because it would need to say their name in the prog. For example "Hello, Henchman Johnny" or "Good evening, General Bob". Any suggestions would be appreciated.
From your friendly neighborhood ranger :)
Dalvyn
Sword Grand Master
Sword Grand Master
Posts: 4708
Joined: Tue Jul 15, 2003 9:26 pm
Location: House of Wonder, Waterdeep

Post by Dalvyn » Sun Dec 18, 2005 7:07 pm

$n is the triggering character's name. So you could use something like

Code: Select all

>greet_prog 100~
if level($n) < 15
  mpechoat $n $I glances at you.
  mpechoaround $n $I glances at $N.
  say Here comes another noname whelp.
else
  if level ($n) < 35
    if sex($n) == 1
      sayto $n Hello, Henchman $n!
    else
      if sex($n) == 2
        sayto $n Hello, Henchwoman $n!
      else
        sayto $n Hello, Henchthingy $n!
      endif
    endif
  else
    sayto $n Good day, General $n!
  endif
endif
Image
Elwin
Sword Master
Sword Master
Posts: 171
Joined: Wed Dec 31, 2003 8:28 pm
Location: Ardeep
Contact:

Post by Elwin » Sun Dec 18, 2005 7:38 pm

Alright, that's what I thought. Just wasn't quite sure on it. Thanks, Dalvyn.
From your friendly neighborhood ranger :)
Post Reply