home *** CD-ROM | disk | FTP | other *** search
- 1Frank #1 @8339 7(1- the abstract -7)
- Fri Jun 30 12:09:22 1995
- 9Re2: 1I made a mod for the BBS Listing program0
- Beamer #1 @3453
- Tue Jun 27 12:09:48 1995
- RE: 9Re2: 1I made a mod for the BBS Listing program0
-
- 7[2Reply7]1: 9Please Reply d00d!0
-
- ╔═══════════════════════════════════════════════════════════════════════════╗
- ║ MOD Desc : Adds the Digital BBS listing Program to run inside WWIV ║
- ║ REQUIRES that you have DBLST1+.ZIP BBS Listing Program in ║
- ║ you WWIV directory!!!!!! ║
- ║ Filename : BEAM202.mod Mod Version : 1 ║
- ║ Author : Beamer WWIV Version : 4.24 ║
- ║ ║
- ║ Network : 7@2148 WWIVnet ║
- ║ Addresses 1@3450 DesertNet ║
- ║ 1@3453 DigiNet ║
- ║ 1@3452 Infiniti ║
- ║ 1@3459 TerraNet ║
- ║ ║
- ║ Last updated : 6/27/95 ║
- ║ Difficulty : █░░░░░░░░ ║
- ║ ║
- ╚═══════════════════════════════════════════════════════════════════════════╝
- ┌───────────────────────────────────────────────────────────────────────────┐
- │ Legend: │
- │ │
- │ - Commeny out or delete │
- │ + Add this │
- │ = Leave alone │
- │ @ Change this │
- └───────────────────────────────────────────────────────────────────────────┘
-
-
- ──────────────────────────────────────────────────────────────────────────────
- Step 0: Dahhhhh!!!
- ──────────────────────────────────────────────────────────────────────────────
-
- ──────────────────────────────────────────────────────────────────────────────
- Step 1: If you want a //slash command, then add this to MMENU.C just above
- 'if (strcmp(s,"CLS")==0) {'
- ──────────────────────────────────────────────────────────────────────────────
-
- + if (strcmp(s,"BBS")==0) {
- + if ((okansi()) && (!rip_on())) {
- + CLS();
- + prt(7,"Please hold while program is loading2...");0
- + extern_prog("BBSLIST.EXE",EFLAG_SHRINK|EFLAG_NOPAUSE|EFLAG_TOPSCREEN);
- + } else {
- + nl();
- + pl("7This is a NON-RIP 'ANSI' option3, 7Sorry2.");0
- + nl();
- + }
- + }
- = if (strcmp(s,"CLS")==0) {
- = outstr("\f");
- = if (rip_on()) {
-
-
- ──────────────────────────────────────────────────────────────────────────────
- Step 2: If you want this to replace your stock WWIV BBS Listing program,
- then open MISCCMD.C and replace 'void bbslist(void)' with mine...
- ──────────────────────────────────────────────────────────────────────────────
-
-
- void bbslist(void)
- {
- int i,f,done,ok;
- char s[150],s1[150],ch,ch1,*ss;
- char phone[13], name[51], speed[5], type[5];
- long l,l1;
-
- if ((okansi()) && (!rip_on())) {
- CLS();
- prt(7,"Please hold while program is loading2...");0
- extern_prog("BBSLIST.EXE",EFLAG_SHRINK|EFLAG_NOPAUSE|EFLAG_TOPSCREEN);
- } else {
- done=0;
- do {
- helpl=0;
- nl();
- prt(2,get_string(489));
- ch=onek("QRNA");
- switch(ch) {
- case 'Q':
- done=1;
- break;
- case 'R':
- printfile("BBSLIST.MSG");
- break;
- case 'N':
- print_net_listing(0);
- break;
- case 'A':
- helpl=25;
- if ((actsl<=10)) {
- nln(2);
- pl(get_string(490));
- nl();
- break;
- }
- if (thisuser.restrict & restrict_automessage) {
- nln(2);
- pl(get_string(491));
- nl();
- break;
- }
- nl();
- pl(get_string(492));
- pl(get_string(493));
- outstr(":");
- mpl(12);
- input(phone,12);
- if ((phone[3]!='-') || (phone[7]!='-'))
- phone[0]=0;
- for (i=0; i<12; i++) {
- if (strchr("0123456789-",phone[i])==0)
- phone[0]=0;
- }
- if (strlen(phone)==12) {
- ok=1;
- sprintf(s1,"%sBBSLIST.MSG",syscfg.gfilesdir);
- f=sh_open1(s1,O_RDONLY | O_BINARY);
- if (f>0) {
- sh_lseek(f,0L,SEEK_SET);
- l=filelength(f);
- if ((ss=malloca(l+500L))==NULL) {
- sh_close(f);
- return;
- }
- sh_read(f,ss,(int)l);
- l1=0L;
- while ((l1<l) && (ok)) {
- i=0;
- do {
- ch=ss[l1++];
- s1[i]=ch;
- if (ch==13)
- s1[i]=0;
- ++i;
- } while ((ch!=10) && (i<120) && (l1<l));
- if (strstr(s1,phone)!=NULL)
- ok=0;
- if (strncmp(s1,phone,12)==0)
- ok=0;
- }
- bbsfree(ss);
- sh_close(f);
- }
- if (ok) {
- pl(get_string(494));
- nln(2);
- pl(get_string(495));
- outstr(":");
- mpl(50);
- inputl(name,50);
- nl();
- pl(get_string(496));
- pl(get_string(497));
- outstr(":");
- mpl(4);
- input(speed,4);
- nl();
- pl(get_string(498));
- outstr(":");
- mpl(4);
- input(type,4);
- sprintf(s,"%12s %-50s [%4s] (%4s)\r\n",
- phone, name, speed, type);
- nln(2);
- pl(s);
- nl();
- prt(5,get_string(499));
- if (yn()) {
- sprintf(s1,"%sBBSLIST.MSG",syscfg.gfilesdir);
- f=sh_open(s1,O_RDWR | O_CREAT | O_BINARY, S_IREAD | S_IWRITE);
- if (filelength(f)) {
- sh_lseek(f,-1L,SEEK_END);
- sh_read(f,((void *)&ch1),1);
- if (ch1==26)
- sh_lseek(f,-1L,SEEK_END);
- }
- sh_write(f,(void *)s,strlen(s));
- sh_close(f);
- nl();
- pl(get_string(500));
- }
- } else {
- pl(get_string(501));
- nln(2);
- }
- } else {
- nl();
- pl(get_string(502));
- nl();
- }
- break;
- }
- } while ((!done) && (!hangup));
- }
- }
-
- ──────────────────────────────────────────────────────────────────────────────
- Step 3: Save, Compile, and Enjoy!
- ──────────────────────────────────────────────────────────────────────────────
-
- After Dark BBs
- (314) 946-1730
-