home *** CD-ROM | disk | FTP | other *** search
/ The Devil's Doorknob BBS Capture (1996-2003) / devilsdoorknobbbscapture1996-2003.iso / Dloads / WWIVMODS / PRE412.ZIP / GOLDSYS.MOD < prev    next >
Text File  |  1990-03-24  |  8KB  |  234 lines

  1. Tony Godfrey #1 @18
  2. Thu Mar 22 08:59:39 1990
  3.                               GoldSys
  4.                               Version 1.5
  5.                               by Tony Godfrey
  6.                               March 22, 1990
  7.                               Turbo C 2.0
  8.                               WWIV v4.11
  9.  
  10.                               Explanation
  11.                               -----------
  12.      This modification to WWIV v4.11 (*) is an alternative to the
  13. S.A.L.T. II modification by "Slick the Slickster".  S.A.L.T. II
  14. works with WWIV, however, when using WWIVnetted subs, the S.A.L.T.
  15. II system corrupts the SUBS.DAT files, and all WWIVnet messages
  16. will disappear into nothingness.  I thank "Slick the Slickster" for
  17. his brilliant idea, as I have made a new gold system that follows
  18. his, without losing WWIVnet messages.
  19.      Here's how it works:  the SysOp (or his remote SysOps) can
  20. configure the amount of gold given per post on individual message
  21. bases, and can configure the amount of gold taken away per play of
  22. individual online chains.  For example, if the SysOp(s) configure
  23. message base 1 to give 5 gold per post and message base 2 to give
  24. 7 gold per post, that is exactly what happens.  If the SysOp(s)
  25. configure online chain 1 to take 3 gold per play and online chain
  26. 2 to take 8 gold per play, that is exactly what happens.  The
  27. finished product will look something like this, when the "*" key
  28. is pressed for a sub listing:
  29.  
  30. 1. (5) - General Discussion
  31. 2. (7) - Computer Discussion
  32.  
  33. A chain listing looks like this:
  34.  
  35. 1. (3) Leech
  36. 2. (8) King of the Hill Trivia
  37.  
  38.      Also taken into account is how much gold is taken back if a
  39. user removes his/her post.  If a user removes a post from a message
  40. base that gives 5 gold per post, 5 gold will be taken away.
  41.      The SysOp can edit gold using "//GOLDEDIT" at the main menu or
  42. by pressing "$" at the "Waiting For Caller" screen.
  43.  
  44.                          Additions to Version 1.2
  45.                          ------------------------
  46.      In version 1.2 of GoldSys, the SysOp does not need to rearrage
  47. gold
  48. when he/she inserts and deletes chains and subs.  When the SysOp
  49. inserts
  50. or deletes chains and subs, gold amounts of zero are also inserted,
  51. keeping the amounts of gold per sub/chain in their correct order.
  52.  
  53.  
  54.                               Installation
  55.                               ------------
  56.      Included with this documentation file are five files: 
  57. GOLDSYS1.C," "GOLDSYS2.C," "GOLDSYS3.C," "GOLDSYS4.C" and
  58. "GOLDSYS5.C"  Be sure you have these files, as they are required to
  59. completely install GoldSys.  In order to install GoldSys, you must
  60. complete the following steps:
  61.  
  62.      1) Load Turbo C
  63.      2) Load the "VARS.H" file
  64.      3) At the end of this file, add the following line:
  65.  
  66.  int rewardgold[64],costgold[64];
  67.  
  68.      4) Save the "VARS.H" file
  69.      6) Load the "BBS.C" file
  70.      7) In "void sublist()" do the following:
  71.  
  72. FIND:     int i,abort;
  73. CHANGE:   char s[80],s1[80];
  74. ADD:      goldload();
  75. FIND:     if (s[1]==0)
  76. EXIST:      s[1]=32;
  77. ADD:      itoa(rewardgold[usub[i].subnum],s1,10);
  78. ADD:      strcat(s," (");
  79. ADD:      strcat(s,s1);
  80. ADD:      strcat(s,")");
  81. EXIST:    strcat(s," - ");
  82. EXIST:    if (syscfg.systemnumber)
  83.  
  84.      8) In "void mainmenu()" do the following:
  85.  
  86. FIND:     if ((strcmp(s,"CHAINEDIT")==0) && (so())) {
  87. EXIST:      sysoplog("@ Ran Chainedit");
  88. EXIST:      chainedit();
  89. EXIST:    }
  90. ADD:      if ((strcmp(s,"GOLDEDIT")==0) && (so())) {
  91. ADD:        sysoplog("@ Ran Goldedit");
  92. ADD:        goldedit();
  93. ADD:      }
  94.  
  95.      9) In "void answer_phone()" do the following:
  96.  
  97. FIND:     outs("Answering phone, 'H' to abort.\r\n");
  98. ADD:      goldload();
  99. EXIST:    pr1(syscfg.answer);
  100.  
  101.      10) In "void getcaller()" do the following:
  102.  
  103. FIND:         gfileedit();
  104. EXIST:        holdphone(0);
  105. EXIST:      }
  106. EXIST:      okskey=0;
  107. EXIST:      break;
  108. ADD:      case '$':
  109. ADD:        okskey=1;
  110. ADD:        if (ok_local()) {
  111. ADD:          holdphone(1);
  112. ADD:          goldedit();
  113. ADD:          holdphone(0);
  114. ADD:        }
  115. ADD:        okskey=0;
  116. ADD:        break;
  117.  
  118.      11) Save the "BBS.C" file
  119.      12) Load the "BBSUTL.C" file
  120.      13) Do the following:
  121.  
  122. FIND:     extern char ctypes[NUM_CTYPES][18];
  123. ADD:      extern int rewardgold[64],costgold[64];
  124.  
  125.      14) At the very end of the "BBSUTL.C" file, read in the     
  126.          "GOLDSYS1.C" file
  127.      15) Save the "BBSUTL.C" file
  128.      16) Load the "BBSUTL1.C" file
  129.      17) Do the following:
  130.  
  131. FIND:     extern chainfilerec *chains;
  132. ADD:      extern int rewardgold[64],costgold[64];
  133.  
  134.      18) In "void show_chains(int *mapp, int *map)" do the     
  135.          following:
  136.  
  137. FIND:     int abort,i,i1;
  138. CHANGE:   char s[81],s1[81];
  139. ADD:      goldload();
  140. EXIST:    abort=0;
  141. EXIST:    nl();
  142. EXIST:    for (i=0; (i<*mapp) && (!abort) && (!hangup); i++) {
  143. EXIST:      itoa(i+1,s,10);
  144. CHANGE:     strcat(s,". (");
  145. ADD:        itoa(costgold[i],s1,10);
  146. ADD:        strcat(s,s1);
  147. ADD:        strcat(s,") ");
  148. EXIST:      strcat(s,(chains[map[i]].description));
  149. EXIST:      pla(s,&abort);
  150.  
  151.      19) Replace the "void run_chain(int cn)" procedure with the  
  152.    
  153.          "GOLDSYS3.C" file
  154.      20) Save the "BBSUTL1.C" file
  155.      21) Load the "SYSOPF.C" file
  156.      22) Do the following:
  157.  
  158. FIND:     extern unsigned char realsl;
  159. ADD:      extern int rewardgold[64],costgold[64];
  160.  
  161.      23) Replace the "void boardedit()" procedure with the
  162. "GOLDSYS4.C"
  163.          file
  164.      24) Replace the "void chainedit()" procedure with the
  165. "GOLDSYS5.C"
  166.          file
  167.      29) At the very end of the "SYSOPF.C" file read in the
  168.          "GOLDSYS2.C" file
  169.      30) Save the "SYSOPF.C" file
  170.      31) Load the "MSGBASE1.C" file
  171.      32) Do the following:
  172.  
  173. FIND:     extern int checked[50];
  174. ADD:      extern int rewardgold[64],costgold[64];
  175.  
  176.      33) Do the following:
  177.  
  178. FIND:     strcpy(s,"Posted on ");
  179. EXIST:    strcat(s,subboards[curlsub].name);
  180. EXIST:    save_status();
  181. EXIST:    pl(s);
  182. ADD:      goldload();
  183. ADD:      thisuser.gold += rewardgold[curlsub];
  184. ADD:      itoa(rewardgold[curlsub],s,10);
  185. ADD:      nl();
  186. ADD:      prt(3,"You receive ");
  187. ADD:      prt(6,s);
  188. ADD:      prt(3," gold for that post.");
  189. ADD:      nl();
  190. EXIST:    if ((subboards[curlsub].type) && (syscfg.systemnumber))
  191. {
  192.  
  193.      34) Do the following:
  194.  
  195. FIND:         pl("Message removed.");
  196. EXIST:        nl();
  197. ADD:          goldload();
  198. ADD:          thisuser.gold -= rewardgold[curlsub];
  199. ADD:          itoa(rewardgold[curlsub],s,10);
  200. ADD:          nl();
  201. ADD:          prt(3,"You lost ");
  202. ADD:          prt(6,s);
  203. ADD:          prt(3," gold for removing that post.");
  204. ADD:          nl();
  205. EXIST:      }
  206. EXIST:    }
  207.  
  208.      35) Save the "MSGBASE1.C" file
  209.      36) Load the "BBSUTL.C" file (NEW IN VERSION 1.3)
  210.      37) In "void yourinfo()" do the following:
  211.  
  212. FIND:       print("Time spent on  : ",s," Minutes","");
  213. ADD:        itoa((int)thisuser.gold,s,10);
  214. ADD:        print("Gold           : ",s,"");
  215. EXIST:      nl();
  216. EXIST:    }
  217.  
  218.      38) Save the "BBSUTL.C" file
  219.      37) Compile WWIV and run
  220.  
  221.  
  222.                               Further Information
  223.                               -------------------
  224.      If you have any problems installing or running this
  225. modification, please contact me through the WWIVnet, or call my
  226. bulletin board directly.  I would like to hear comments and/or
  227. suggestions, so if you have them, I encourage you to send them.
  228. Please remember to include the version of GoldSys that you are
  229. using.
  230.  
  231.  
  232. Tony Godfrey 1@18 "The Federation" (818) 407-0419
  233.  
  234. (*) May work with earlier or later versions of WWIV