This ARC file SLICK3.ARC, contains this file, SLICK3.MOD.
This is a mod that will effect your users on the BBS. It will setup a new
gold system. A gold system is a system, in which the user uses his gold for
things that you want it to be charge to his gold. Like for instant, you want
an on-liner to cost 5 gold pieces, and the user has 100 gold pieces, so when
he runs that on-liner, and ends the on-liner. He will have 95 gold pieces,
because you set up 5 gold pieces for that on-liner. You can set up other
mods to use it with my gold system. The best ones I recommend are: LOGOFF
LOTTERY (LOGLOT10.C) , SELL GOLD FOR TIME/UPLOAD CREDIT (GOLD.C), AND MR.BILL'S CASINO. They are very useful in a gold system, they will let the user spend their gold, or earn some gold.
What my gold system does, is to let the sysop configure how much a external program will cost to the user's gold. And will also let the sysop configure
how much a message base will give gold to the user when he/she post. It will
also remove the gold, if perhaps a user remove his/her message!
The first thing you should do is read over this documentation throug(lp and make sure you understand it. Then you should install it using these
instructions.
+------+
| NOTE |
+------+
This mod contain some symbols, and may be mistaken as if it was the
included in the mod, please understand these symbols, before going on any
farther.
┌─────────────────────────┐
│ LEGEND: * = Change Line │
│ - = Delete Line │
│ + = Add Line │
└─────────────────────────┘
In some places, I might put this:
┌─┐
│.│
│.│
│.│
└─┘
The first block, is the legend of the symbols. The symbols will show up as
the first character on the line. The second block is a group of three dots.
It means that the source code continues, and is not written in. Usually, after the three dots, there will be a piece of the source code which you can search for, so when you find it. You'll know where to continue. Now let's start!!
FIRST
+--------------+
| NAME CALLING |
+--------------+
First, let's declare some needed variables! In your VARDEC.H file, you should search for "/* MESSAGE BASE INFORMATION */", (without quotes) and add this line at the end of this variable structure.
float rewardgold;
Now search for "/* DATA FOR OTHER PROGRAMS AVAILABLE */", and add this line at the end of this variable structure.
float costgold;
SECOND
+---------------+
| THE EXTERNALS |
+---------------+
We now are finish with declaring the variables needed. Now, we are going
to modify some existing procedures so that we can edit the gold requirement
for each external game. Now, in your SYSOPF.C file, you should search for
"void chaindata(int n, char *s)", and modify/add the following lines...
void chaindata(int n, char *s) /* LEGEND: * = Change Line */
Next go down to "void modify_chain(int n)", (it should be after the above
procedure) and modify/add the following lines...
void modify_chain(int n);
{
.
.
.
pl("F. DOS Interrupt: Used");
+ itoa(c.costgold,s,10);
+ strcpy(s1,"G. Gold Required: ");
+ strcat(s1,s);
+ strcat(s1," Pieces");
+ print(s1,"");
if (c.ansir & ansir_no_300)
* pl("H. 300 Baud : Not allowed");
else
* pl("H. 300 Baud : Allowed");
nl();
* prt(2,"Which (A-H,Q) ? ");
* ch=onek("QABCDEFGH");
.
.
.
else
c.ansir |= ansir_no_DOS;
break;
+ case 'G':
+ nl();
+ prt(5,"New gold requirement? ");
+ input(s,5);
+ c.costgold=atoi(s);
+ break;
* case 'H':
nl();
prt(5,"Allow 300 baud users to run? ");
.
.
.
}
chains[n]=c;
}
Next go down to "void insert_chain(int n)", (it should be the next procedure
under the above procedure) and add a this next line after "c.ansir=0;".
c.costgold=0;
THIRD
+-------------+
| THE WRITERS |
+-------------+
We now are finish with adding in the gold requirement for the external programs, let's now go to edit the board editor, so we can award our fellow posters for posting! OK, go to the beginning of your SYSOPF.C file.
Do a search for "void boarddata(int n, char *s)", and modify/add the following lines...
Next go down to "void modify_sub(int n)", (should be below the above procedure) and add/modify the following lines...
void modify_sub(int n)
{
.
.
.
print("K. Storage typ: ",s,"");
+ itoa(r.rewardgold,s,10);
+ print("L. Reward Gold: ",s,"");
nl();
* prt(2,"Which (A-L,Q) ? ");
* ch=onek("QABCDEFGHIJKL");
.
.
.
r.storage_type=i;
break;
+ case 'L':
+ nl();
+ prt(2,"New Reward Gold? ");
+ input(s,5);
+ i=atoi(s);
+ r.rewardgold=i;
+ break;
.
.
.
} while ((!done) && (!hangup));
subboards[n]=r;
if (!wfc)
changedsl();
}
Next go down to "void insert_sub(int n)", (it should be the next procedure
under the above procedure) and add a this next line after
"r\storage_type=2;".
r.rewardgold=3;
FOURTH
+-----------------+
| THE LAST BATTLE |
+-----------------+
We now are finish with adding in the gold requirement for the message
base editor, let's now go to edit the complete the misson. We're going
to load your MSGBASE1.C file. Now, do that, load it! OK, search for
"posted on", it should be somewhere in the "void post()". Now we're gonna
start...
void post()
{
.
.
.
topscreen();
strcpy(s,"+");
strcat(s,p.title);
strcat(s," posted on ");
strcat(s,subboards[curlsub].name);
sysoplog(s);
+ nl();
+ prt(3,"Hey, thanks for posting that 'interesting'");
+ prt(3,"post, you just earn yourself ");
+ itoa(subboards[curlsub].rewardgold,s,10);
+ prt(6,s);
+ prt(3," gold pieces!");
+ nl();
+ thisuser.gold+=subboards[curlsub].rewardgold;
save_status();
.
.
}
Now, that's the code to reward the user for posting, let's go on... OK, search for "void remove_post()". Now, do another search for "Message removed.", when you get there, you should still be in remove_post(). Now enter the following lines...
prt(3,"Sorry, when you remove a post, you're");
nl();
prt(3,"removing the gold you earn for posting");
prt(3,"that message!!");
thisuser.gold-=subboards[curlsub].rewardgold;
nl();
Hold on, we're almost finish. Now, load your BBSUTL1.C file, search for
"void show_chains(int *mapp, int *map)", and enter the following lines...
void show_chains(int *mapp, int *map)
{
int abort,i,i1;
* char s1[81],s[81];
abort=0;
nl();
for (i=0; (i<*mapp) && (!abort) && (!hangup); i++) {
itoa(i+1,s,10);
strcat(s,". ");
+ strcat(s,"(");
+ itoa(chains[map[i]].costgold,s1,10);
+ strcat(s,s1);
+ strcat(s,") ");
strcat(s,(chains[map[i]].description));
pla(s,&abort);
}
nl();
}
Now search for "void run_chain(int cn)", and enter the following lines...
void run_chain(int cn)
{
char s[81],s1[81],s2[81];
int oc;
+ if (thisuser.gold<(chains[cn].costgold)) {
+ nl();
+ ansic(6);
+ print("Sorry, not enough gold...","");
+ ansic(3);
+ print("Try posting a message or two in","");
+ ansic(3);
+ print("the message base!!","");
+ return;
+ }
strcpy(s1,chains[cn].filename);
strcpy(s2,create_chain_file("CHAIN.TXT"));
.
.
.
chatcall=oc;
+ thisuser.gold-=chains[cn].costgold;
}
Next, go down to "void do_chains()", (it should be below the above procedure)
and add/modify the following lines...
void do_chains()
{
int map[50],mapp,i,i1,ok,done;
+ int pf;
* char s[81],s1[81],*ss;
chainfilerec c;
.
.
.
}
}
if (mapp==0) {
nl();
nl();
pl("Sorry, no external programs available.");
nl();
return;
}
+ if (thisuser.gold<=0) { /* FROM HERE TO THE END */
+ nl(); /* PASTE THIS IN DO_CHAINS() */
+ ansic(6); /* AND REMOVE THE OLD PART */
+ print("Sorry, not enough gold...","");
+ ansic(3);
+ print("Try posting a message or two in","");
+ ansic(3);
+ print("the message base!!","");
+ return;
+ }
+ if (mapp==1) {
+ if (thisuser.gold<(chains[map[0]].costgold))
+ {
+ nl();
+ ansic(6);
+ print("Sorry, not enough gold...","");
+ ansic(3);
+ print("Try posting a message or two in","");
+ ansic(3);
+ print("the message base!!","");
+ return;
+ }
+ run_chain(map[0]);
+ return;
+ }
+ pf=0;
+ if (okansi()) {
+ strcpy(s,syscfg.gfilesdir);
+ strcat(s,"CHAINS.TXT");
+ if (exist(s))
+ pf=1;
+ }
+ if (!pf)
+ show_chains(&mapp,map);
+ done=0;
+ do {
+ if (!pf) {
+ prt(2,"Which (Q=Quit, ?=List) : ");
+ } else {
+ ansic(0);
+ printfile("CHAINS.TXT");
+ }
+ ss=mmkey(2);
+ i=atoi(ss);
+ if ((i>0) && (i<=mapp)) {
+ done=1;
+ run_chain(map[i-1]);
+ } else
+ if (strcmp(ss,"Q")==0)
+ done=1;
+ else
+ if ((strcmp(ss,"?")==0) && !pf)
+ show_chains(&mapp,map);
+ } while ((!hangup) && (!done));
+ ansic(0);
+ }
Now load in the BBS.C file, search for "void sublist()", and add/modify the