home *** CD-ROM | disk | FTP | other *** search
- Apollo #1 @11138
- Sun Jun 25 22:38:28 1995
- ┌──────────────────────────────────────────────────────Filo─Header─(c)────┐
- │ Mod Name: Edit02.424 Mod Authors: Editor 149 │
- │ Difficulty: ███▒▒▒▒▒▒▒(3.0/10) @11138.WWIVNet │
- │ WWIV Version: v4.24 @2939 TERRANet, IceNet, SierraLink │
- │ Date: 06/21/95 @2938 CyberNet │
- │ Files Affected: MMENU.C, BBS.C │
- │ Description: Send SSM's to All or to one user from WFC or from the Main │
- │ Menu. │
- └─────────────────────────────────────────────────────────────────────────┘
-
- Extended Description:
- Adds //SSM and //SSM <UserName/UserNumber> commands to Main Menu For SysOps
- Ads ! command to WFC to send SSM's to all users
-
- You can add Color to the SSM's using WWIV's standard ^P Codes.
- SysOp can send SSM's to networked addresses IE: 1@2800
-
- Copyright Disclaimer:
- (c) 1995 Editor a.k.a #149@Retreat of the Gods (209) 537-2808
- This mod is written for use by REGISTERED WWIV SysOps, as they are the only
- ones who should have the source code. SysOps may freely upload this mod to
- any BBS or online service provided it is not edited in any way except to
- remove messge headers and/or taglines. Shareware CDROM vendors are prohibited
- from distributing this mod without EXPRESS WRITTEN CONSENT from the author &
- Wayne Bell, Author of WWIV BBS Software.
- Parts of the code shown in this mod are:
- Copyright (C) 1988-1993 by Wayne Bell.
-
- BACKUP your source
-
- LEGEND:
- = Old code, Search for this
- + New code, Add this
- - Remove or comment out this
- ... Go down several lines in the same function
-
- Open: MMENU.C
- Find: void mainmenu(void)
- = static int mflag = 0, no_clear = 0;
- = long oldstat;
- = FILE *namefile;
- =
- + unsigned short un, sy; /* Edit02.424 */
- + userrec u; /* Edit02.424 */
- + /* Edit02.424 */
- = s2[0]=0;
- = if (usub[cursub].subnum==-1) {
- = cursub=0;
- .
- .
- .
- = if (strcmp(s,"PACK")==0) {
- = nl();
- = prt(5, get_string(1505));
- = if (yn())
- = pack_all_subs();
- = else
- = pack_sub(usub[cursub].subnum);
- = }
- + if (strcmp(s, "SSM")==0) { /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + prt(2, "Send a short message to everyone?");
- + /* Edit02.424 */
- + if (yn()) { /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + prt(1, "Enter short message now.");
- + /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + prt(2, ": "); /* Edit02.424 */
- + mpl(70); /* Edit02.424 */
- + ansic(4); /* Edit02.424 */
- + inli(s1, "", 70, 1); /* Edit02.424 */
- + if (s1[0]==NULL) { /* Edit02.424 */
- + pl(get_string(14)); /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + } else { /* Edit02.424 */
- + i=0; /* Edit02.424 */
- + outstr(get_string(356)); /* Edit02.424 */
- + do { /* Edit02.424 */
- + if(i%5==0) /* Edit02.424 */
- + npr("\b\b\b\b%4d", i); /* Edit02.424 */
- + read_user(i, &u); /* Edit02.424 */
- + if ((u.inact & inact_deleted)==0) {
- + /* Edit02.424 */
- + ssm(i, 0, s1); /* Edit02.424 */
- + i++; /* Edit02.424 */
- + } /* Edit02.424 */
- + } while ((i<=((status.users)+1)) && (!hangup));
- + /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + npr("%d SSM's sent.", i); /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + } /* Edit02.424 */
- + } else { /* Edit02.424 */
- + prt(1, get_string(15)); /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + prt(2, ": "); /* Edit02.424 */
- + mpl(70); /* Edit02.424 */
- + ansic(4); /* Edit02.424 */
- + inli(s1, "", 70, 1); /* Edit02.424 */
- + parse_email_info(s1, &un, &sy);
- + /* Edit02.424 */
- + if(un || sy) { /* Edit02.424 */
- + prt(1, "Enter short message now.");
- + /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + prt(2, ": "); /* Edit02.424 */
- + mpl(70); /* Edit02.424 */
- + ansic(4); /* Edit02.424 */
- + inli(s1, "", 70, 1); /* Edit02.424 */
- + if (s1[0]==NULL) { /* Edit02.424 */
- + pl(get_string(14)); /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + } else { /* Edit02.424 */
- + ssm(un, sy, s1); /* Edit02.424 */
- + npr("%d SSM's sent.", 1); /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + } /* Edit02.424 */
- + } else { /* Edit02.424 */
- + pl(get_string(8)); /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + } /* Edit02.424 */
- + } /* Edit02.424 */
- + } /* Edit02.424 */
- + /* Edit02.424 */
- + if (strncmp(s, "SSM ", 4)==0) { /* Edit02.424 */
- + strrev(s); /* Edit02.424 */
- + i=strlen(s); /* Edit02.424 */
- + s[i-4]=NULL; /* Edit02.424 */
- + strrev(s); /* Edit02.424 */
- + strcpy(s1, s); /* Edit02.424 */
- + parse_email_info(s1, &un, &sy); /* Edit02.424 */
- + if(un || sy) { /* Edit02.424 */
- + prt(1, "Enter short message now.");
- + /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + prt(2, ": "); /* Edit02.424 */
- + mpl(70); /* Edit02.424 */
- + ansic(4); /* Edit02.424 */
- + inli(s1, "", 70, 1); /* Edit02.424 */
- + if (s1[0]==NULL) { /* Edit02.424 */
- + pl(get_string(14)); /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + } else { /* Edit02.424 */
- + ssm(un, sy, s1); /* Edit02.424 */
- + npr("%d SSM's sent.", 1); /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + } /* Edit02.424 */
- + } else { /* Edit02.424 */
- + pl(get_string(8)); /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + } /* Edit02.424 */
- + } /* Edit02.424 */
- = }
- =/**************************************************/
- =
- = if (cs()) {
- = if (strcmp(s,"IVOTES")==0) {
-
- Load up: BBS.C
- Find: void getcaller(void)
- = double d;
- = userrec tu;
- + unsigned short un, sy; /* Edit02.424 */
- + /* Edit02.424 */
- = c_sub=c_dir=0;
- =
- = cid_num[0]=0;
- = cid_name[0]=0;
- = frequent_init();
- .
- .
- .
- = case 9:
- = if (ok_local()) {
- = holdphone(1);
- = instance_edit();
- = holdphone(0);
- = }
- = break;
- + case '!': /* Edit02.424 */
- + prt(2, "Send a short message to everyone?");
- + /* Edit02.424 */
- + if (yn()) { /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + prt(1, "Enter short message now.");
- + /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + prt(2, ": "); /* Edit02.424 */
- + mpl(70); /* Edit02.424 */
- + ansic(4); /* Edit02.424 */
- + inli(s, "", 70, 1); /* Edit02.424 */
- + if (s[0]==NULL) { /* Edit02.424 */
- + pl(get_string(14)); /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + } else { /* Edit02.424 */
- + i=0; /* Edit02.424 */
- + outstr(get_string(356));/* Edit02.424 */
- + do { /* Edit02.424 */
- + if(i%5==0) /* Edit02.424 */
- + npr("\b\b\b\b%4d", i);
- + /* Edit02.424 */
- + read_user(i, &tu); /* Edit02.424 */
- + if ((tu.inact & inact_deleted)==0) {
- + /* Edit02.424 */
- + ssm(i, 0, s); /* Edit02.424 */
- + i++; /* Edit02.424 */
- + } /* Edit02.424 */
- + } while ((i<=((status.users)+1)) && (!hangup));
- + /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + npr("%d SSM's sent.", i);
- + /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + } /* Edit02.424 */
- + } else { /* Edit02.424 */
- + prt(1, get_string(15)); /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + prt(2, ": "); /* Edit02.424 */
- + mpl(70); /* Edit02.424 */
- + ansic(4); /* Edit02.424 */
- + inli(ss, "", 70, 1); /* Edit02.424 */
- + parse_email_info(ss, &un, &sy);
- + /* Edit02.424 */
- + if(un || sy) { /* Edit02.424 */
- + prt(1, "Enter short message now.");
- + /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + prt(2, ": "); /* Edit02.424 */
- + mpl(70); /* Edit02.424 */
- + ansic(4); /* Edit02.424 */
- + inli(s, "", 70, 1); /* Edit02.424 */
- + if (s[0]==NULL) { /* Edit02.424 */
- + pl(get_string(14)); /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + } else { /* Edit02.424 */
- + ssm(un, sy, s); /* Edit02.424 */
- + npr("%d SSM's sent.", 1);
- + /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + } /* Edit02.424 */
- + } else { /* Edit02.424 */
- + pl(get_string(8)); /* Edit02.424 */
- + nl(); /* Edit02.424 */
- + } /* Edit02.424 */
- + } /* Edit02.424 */
- + break; /* Edit02.424 */
- = }
- = if (!incom && !lokb) {
- = frequent_init();
-
-
- Done.
-
- Save, Recompile and run.
- As you can see, it's very easy and you only have to change two files!
-
- Editor
-