home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Devil's Doorknob BBS Capture (1996-2003)
/
devilsdoorknobbbscapture1996-2003.iso
/
Dloads
/
WWIVMODS
/
MODSUNKN.ZIP
/
USERRANK.MOD
< prev
next >
Wrap
Text File
|
1990-06-17
|
3KB
|
104 lines
Yellow Man #48 @2367
Sat Jun 09 08:38:37 1990
Caramon Majere #3 @8412
Fri Jun 23 21:42:36 1989
/****************************************************************************
Fantasy - Adds Character Ranks w/out Screwing up USER.LST
By: Caramon Majere
3@8412 The Alliance (804)598-7659 5@8413 The Empire (804)276-4798
****************************************************************************/
This is the second edition of the USER RANK mod. It was beta-tested on the
Alliance (And from this beta-test, I saw the need of a version that doesn't
screw around with the USER.LST file). You can call up the user's rank just
by the string RANK. (ie: print("Rank: ",rank,"");)
<****> STEP 1 <*************************************************************>
Load up your VARS.H file, and add this to the end:
char rank[31];
<****> STEP 2 <*************************************************************>
Now, this step is a bit of a pain. Load up each of the C files (All files
listed in your BBS.PRJ), and add this to the end of the 'extern' listing
(If there is no extern listing, add it just below the '#include')
extern char rank[31];
<****> STEP 3 <*************************************************************>
Block-Read (Control-K-R) the following code at the end of BBSUTL.C.
void user_rank()
{
strcpy(rank,"");
if ((thisuser.sl<=20) && (thisuser.sl>=1)) {
strcpy(rank,"Peasant");
return;
} else
if ((thisuser.sl>=21) && (thisuser.sl<=30)) {
strcpy(rank,"Yeoman");
return;
} else
if ((thisuser.sl>=31) && (thisuser.sl<=40)) {
strcpy(rank,"Esquire");
return;
} else
if ((thisuser.sl>=41) && (thisuser.sl<=50)) {
strcpy(rank,"Viscount");
return;
} else
if ((thisuser.sl>=51) && (thisuser.sl<=60)) {
strcpy(rank,"Baron");
return;
} else
if ((thisuser.sl>=61) && (thisuser.sl<=70)) {
strcpy(rank,"Elder");
return;
} else
if ((thisuser.sl>=71) && (thisuser.sl<=80)) {
strcpy(rank,"High Elder");
return;
} else
if ((thisuser.sl>=81) && (thisuser.sl<=90)) {
strcpy(rank,"Earl");
return;
} else
if ((thisuser.sl>=91) && (thisuser.sl<=99)) {
strcpy(rank,"Mayor");
return;
} else
if ((thisuser.sl>=100) && (thisuser.sl<=254)) {
switch(usernum) {
case 3:
strcpy(rank,"Highlord");
break;
case 4:
strcpy(rank,"Magistrate");
break;
}
}
switch(usernum) {
case 1:
strcpy(rank,"High King");
break;
case 2:
strcpy(rank,"Court's High Archmage");
break;
}
}
That's just about it...Press F9 and grab a snack....
Caramon Majere: 'Virtute et Armis'
3@8412 The Alliance (804)598-7659
5@8413 The Empire (804)276-479