home *** CD-ROM | disk | FTP | other *** search
/ The Devil's Doorknob BBS Capture (1996-2003) / devilsdoorknobbbscapture1996-2003.iso / Dloads / WWIVMODS / MODSUNKN.ZIP / LOWMEM.MOD < prev    next >
Text File  |  1992-01-29  |  3KB  |  60 lines

  1. /****************************************************************************/
  2.  
  3.                             LOW MEMORY WARNING MOD
  4.                              Another Mod for 4.xx
  5.                                  by TwO PunKs
  6.                               1@8410      1@8406
  7.  
  8. /****************************************************************************/
  9.         This mod was written because some of us can't afford 80MB Hard Drives
  10. and go to bed each night praying that some idiot doesn't upload the entire
  11. Encylopedia Britainica and drop the free space on our drives below 100K (at
  12. which point users can't post or even leave you mail to tell you about it!).
  13.         Well for those sysops who don't go on their boards that much and just
  14. check the logs this mod will cause a BEEPING to occur when a user logs off &
  15. the free space drops below 100K and also writes you a note in the sysop log.
  16. It's very easy to configure for any memory size you'd like to be warned at.
  17.         Have fun and enjoy....
  18. ------------------------------------------------------------------------------
  19. STEP 1:  BBSUTIL.C  in void logoff();      ____________________
  20.                                           | $ Search for Line  |
  21. Search for:                               | ! Change Line      |
  22.                                           | + Add Line         |
  23. void logoff()                             | - Delete Line      |
  24. {                                         | = Leave Line Alone |
  25. = long l;                                 |____________________|
  26. ! int f,r,w,t,beepyet;
  27. ! char s[81],s1[81];
  28. $ mailrec m;
  29. = shortmsfrec sm;
  30. ! double ton,ti;
  31.  
  32. = dtr(0);
  33. = thisuser.lastrate=atoi(curspeed);
  34. = strcpy(thisuser.laston,xdate);
  35. + beepyet=0;
  36. + ti=freek1((d.path));
  37. = thisuser.sl=realsl;
  38.   .
  39.   .
  40.   .
  41. =     close(f);
  42. =   }
  43. = }
  44.  
  45. + ltoa((long) (ti),s1,10);
  46. + if (ti<100) {                          /* vary if needed */
  47. +   beepyet=1;
  48. +   outstr(7);
  49. +   sysoplog("*!*!*!*!*!*  WARNING!  DISK SPACE IS BELOW 100K!! *!*!*!*!*");
  50.   }
  51. -----------------------------------------------------------------------------
  52.  
  53.         That should be it. It will give one error (yet another to ignore)
  54. upon compiling but don't worry about it. You can change the 100 to anything
  55. that you'd like for a warning. And you can also change the number of times
  56. the thing will beep at you if you'd like.
  57.         Well that's about it. Let us know if you have any problems or
  58. questions.  All suggestions are also welcome and always responded to. Enjoy.
  59.  
  60.                                   TwO PunKs