home *** CD-ROM | disk | FTP | other *** search
/ The Devil's Doorknob BBS Capture (1996-2003) / devilsdoorknobbbscapture1996-2003.iso / Dloads / SYSOP / SUP_CHAT.ZIP / SUP_CHAT.MOD < prev   
Text File  |  1997-06-07  |  6KB  |  150 lines

  1. /*****************************************************************************
  2.  *                                                                           *
  3.  *  Mod Filename : SUP_CHAT.MOD                                              *
  4.  *  Mod Name     : Super Chat Request with System Help                       *
  5.  *                                                                           *
  6.  *  Level of Difficulty Installing : ██░░░░░░░░  (2 of 10)                   *
  7.  *  Level of Difficulty Designing  : █████████░  (9 of 10)                   *
  8.  *                                                                           *
  9.  *  Designed by : ßlack Ωmen                                                 *
  10.  *                                                                           *
  11.  *  What it Does : When someone trys to page you for chat, instead of just   *
  12.  *                 typing the reason, this mod will first ask them if they   *
  13.  *                 could be helped by the system... for example... lets say  *
  14.  *                 a user is having transfer problems, then they try to chat *
  15.  *                 and one of the options is "help with transfers", they     *
  16.  *                 choose that option, and then they don't need to bug you   *
  17.  *                 over something as simple as using the correct transfer    *
  18.  *                 protocol, or not being able to select something from lack *
  19.  *                 of time or ratio...    this mod is extremely versetile in *
  20.  *                 what options you give people, so, you may wish to plan    *
  21.  *                 how many options you are going to make available...       *
  22.  *                                                                           *
  23.  *****************************************************************************/
  24. /*
  25.  
  26. Legal Disclaimer : If you decide to use this mod, and you add it, and it fucks
  27.                    your system over, your fault, not mine, you were the one
  28.                    who chose to add it...  if you use the mod exactly how I
  29.                    wrote it, you may have an easier time doing this, but, if
  30.                    you are smart, and customize, you will have a slightly more
  31.                    difficult time installing this mod, but, the mod will be
  32.                    suited more to what you want...
  33. */
  34.  
  35. /* Step Zero...  optional step... alter this mod to your liking, then procede
  36.    with the rest of the steps... */
  37.  
  38. /* Step One...  add the entire contents of "ADDME.C" to the begining of the
  39.    same file as the one containing "void reqchat(void)", anywhere before
  40.    that function, but after the variable declarations */
  41.  
  42. /* Step Two...  replace the old  "void reqchat(void)" with the one below */
  43.  
  44. /* Step Three... Copy *.MSG to your g-files directory */
  45.  
  46. /* Step four... Recompile */
  47.  
  48. void reqchat(void)
  49. {
  50.   int ok, xcash2;
  51.   char s[81], xcash, xcash1, chat_password[40];
  52.  
  53.   nln(2);
  54.   ok=sysop2();
  55.   if (restrict_chat & thisuser.restrict)
  56.     ok=0;
  57.   if (ok) {
  58.     if (chatcall) {
  59.       chatcall=0;
  60.       pl(get_string(597));
  61.       topscreen();
  62.     } else {
  63.       printfile("CHATMAIN.MSG");
  64.       xcash=onek("ABCDE");
  65.       if (xcash=='E')
  66.         return;
  67.       if (xcash=='A') {                /* Transfer Help */
  68.         printfile("CHAT_A.MSG");
  69.         xcash1=onek("ABC");
  70.         if (xcash1=='A') {             /* UL / DL problems */
  71.           printfile("CHAT_A_A.MSG");
  72.           return;
  73.         } if (xcash1=='B') {           /* Access Problems */
  74.           printfile("CHAT_A_B.MSG");
  75.           return;
  76.         } else {
  77.           return;
  78.           }
  79.       } if (xcash=='B') {              /* Posting and E-Mail Help */
  80.         printfile("CHAT_B.MSG");
  81.         xcash1=onek("ABCDE");
  82.         if (xcash1=='A') {             /* Can't read mail */
  83.           printfile("CHAT_B_A.MSG");
  84.           return;
  85.         } if (xcash1=='B') {           /* Can't write mail */
  86.           printfile("CHAT_B_B.MSG");
  87.           return;
  88.         } if (xcash1=='C') {           /* Can't read posts */
  89.           printfile("CHAT_B_C.MSG");
  90.           return;
  91.         } if (xcash1=='D') {           /* Can't write posts */
  92.           printfile("CHAT_B_D.MSG");
  93.           return;
  94.         } else {
  95.           return;
  96.         }
  97.       } if (xcash=='C') {              /* Apply for more access */
  98.         printfile("CHAT_C.MSG");
  99.         xcash1=onek("ABCDE");
  100.         if xcash1=='A'                 /* SL / DSL */
  101.           xcash2=1;
  102.         if xcash1=='B'                 /* Sysop, Co-Sysop, Remote Sysop */
  103.           xcash2=2;
  104.         if xcash1=='C'                 /* Host a Sub */
  105.           xcash2=3;
  106.         if xcash1=='D'                 /* Special parts of transfer section */
  107.           xcash2=4;
  108.         if xcash1=='E'
  109.           xcash2=5;
  110.         application_fill(xcash2);
  111.         return;
  112.       } if (xcash=='D') {              /* Must Chat, system can't help */
  113.         inputl(chat_password,40);
  114.         if (chat_password != "squareware")  /* I suggest you change this... */
  115.           return;
  116.         else {
  117.           prt(2,get_string(598));
  118.           inputl(s,70);
  119.           if (s[0]) {
  120.             if (sysinfo.flags & OP_FLAGS_NEW_CHATSOUND) {
  121.               if (!play_sdf("CHAT",0))
  122.                 chatsound(1000, 2000, 50, 20, 20, 5);
  123.             }
  124.             chatcall=1;
  125.             sprintf(chatreason,"%s: %s",get_stringx(1,33), s);
  126.             nl();
  127.             sysoplog(chatreason);
  128.             for (ok=strlen(chatreason); ok<80; ok++)
  129.               chatreason[ok]=32;
  130.             chatreason[80]=0;
  131.             topscreen();
  132.             pl(get_string(599));
  133.             nl();
  134.           }
  135.           break;
  136.         }
  137.       } else {
  138.       break;
  139.       }
  140.     }
  141.   } else {
  142.     pl(get_string(600));
  143.     nl();
  144.     pl(get_string(601));
  145.     strcpy(irt,get_stringx(1,34));
  146.     irt_name[0]=0;
  147.     imail(1,0);
  148.   }
  149. }
  150.