home *** CD-ROM | disk | FTP | other *** search
-
- ┌┬─── ── ─ ─ ── ───────────────────────────────────────────────────┬─ ∙∙
- ││ Alternative Worlds Presents │
- └┼─────────────────────────────────────────────────────────────────────┐
- ││ Mod Name » FMD-20a.MOD │∙
- ││ Difficulty » █▒▒▒▒▒▒▒▒▒▒ (1/10) │:
- ││ WWIV Version » 4.24 ││
- ││ Date Affected » 06/01/95 ││
- :│ Files Affected » MISCCMD.C / MMENU.C ││
- ∙│ Description » True Pulldown Matrix Log-Off ││
- └─────────────────────────────────────────────────────────────────────┼┐
- │ A French Mod Division Release - (C) 1995 FMD Software ││
- ∙∙ ─┴─────────────────────────────────────────────────── ── ─ ─ ── ───└┘
-
- ┌┬══════════════════┐
- ││ Long Description ││
- └══════════════════┴┘
-
- This modification will replace your normal logoff with a log off menu that
- uses the arrow keys. You will have many options in that menu and it will have
- a nice design.
-
-
- Here's what it looks like:
-
- D
- CL o g O f f M a t r i x
- C┌·┐ ┌·┐ · ┌──────·┐C┌·─────┐ ┌·┐ ┌·┐ ·
- ───:─:─:─:─: ─:───────: ────────────F─M─D────────────── :──────:─ :─:─:─:─:──
- C· └·┘ └·┘ ·C└·───────────────────────────────·┘C· · └·┘ └·┘
- C┌·───────────────────────────────────·┐
- C| Log Off C|
- C|CTime BankC|
- C:CFeedback To SysopC:
- C·CMessage To Next UserC·
- C:CBBS ListC:
- C|CPage SysOpC|
- C|CQuit Back To SystemC|
- C└·───────────────────────────────────·┘
- C┌·┐ ┌·┐ · ┌──────·┐C┌·─────┐ ┌·┐ ┌·┐ ·
- ───:─:─:─:─: ─:───────: ──────Alternative─Worlds─────── :──────:─ :─:─:─:─:──
- C· └·┘ └·┘ ·C└·───────────────────────────────·┘C· · └·┘ └·┘
- D0
-
-
- It is only available to ANSI users of course, Ascii users will have a kind-of
- same thing, they'll be asked if they wish to leave a feedback and a message to
- next user.
-
- A feature is added, you can select if you want or not your users to be asked
- on their 3 first logons if they wish to keep their account of not, VERY useful
- I think, so I included it.
-
- ┌┬══════════════════┐
- ││ Requirements ││
- └══════════════════┴┘
-
- This modification >NEEDS< COMMON from the Asylum Mod Group installed in your
- source. It should be included in this archive. You need to have v2.2 or higher
- installed else it won't work.
-
- Not required, but highly suggested:
-
- FMD-09.MOD (To help the chat request at matrix)
- FMD-14.MOD (Pulldown Matrix Logon)
-
- ┌┬══════════════════┐
- ││ Thanks ││
- └══════════════════┴┘
-
- ■ Zu Digital & Sam for their COMMON modification that was used for the
- arrow keys in this modification.
- ■ Unca Scrooge & Zu Digital for modeling this mod from the logon matrix.
- ■ All users from Alternative Worlds for their testing.
-
- Revision A:
-
- - Updated for WWIV v4.24
- - Using Internal WWIV.INI functions
- - Now can use random matrix screens.
-
- ┌┬═══════┐
- ││ Tests ││
- └═══════┴┘
-
- This modification has been tested on a virgin WWIV v4.24 source using
- Borland C++ v4.5
-
- ──────────────────────────────────────────────────────────────────────────────
- Legend
- ╔═══╤══════════════════┐
- │ + │ Add This Line │
- │ - │ Delete This Line │
- │ * │ Modify This Line │
- │ = │ Existing Line │
- └═══╧══════════════════╝
- ───[Step 1]────────────────────────────────────────────────────────────────────
-
- Load MISCCMD.C and dump the following functions at the end of the file:
-
- #include <conio.h>
-
- void call_again(void)
- {
- char tb[81],s[81];
-
- if (thisuser.logons<3) {
- nln(2);
- existprint("CALLAGAN");
- nl();
- npr("9Do you wish to keep your account on 1%s9? ",syscfg.systemname);
- if (ny()) {
- pl("Good! See you at next session!");
- } else {
- prt(9,"Reason: ");
- mpl(60);
- inputl(s,60);
- sysoplog(s);
- prt(9,"Well, maybe we will see you another day, you no longer exist on this system.");
- deluser(usernum);
- sprintf(tb,"%s chose to delete his account.",nam(&thisuser,usernum));
- sysoplog(tb);
- ssm(1,0,tb);
- }
- }
- }
-
-
- char *matrix2_str [] = {
- "Log Off",
- "Time Bank",
- "Feedback To Sysop",
- "Message To Next User",
- "BBS List",
- "Page SysOp",
- "Quit Back To System"
- };
-
- #define MATRIX2_OPTIONS 7
-
- void logoff_matrix(void)
- {
- int i, done, ch, cl;
- char *ss;
- showtextrec opt[MATRIX2_OPTIONS];
- varimenurec *menu=NULL, newmenu;
- varimenuinfo info={0, 0, 0, 0,
- DARKGRAY+(BLUE<<4),
- COMMON_FULL, 0, 0, 0, 0, 0};
-
- if (ini_init("WWIV.INI", "LOGOFF_MATRIX", NULL)==0)
- {
- if ((ss=ini_get("COLOR_HIGH", -1, NULL))!=NULL)
- ch=atoi(ss);
- if ((ss=ini_get("COLOR_LOW", -1, NULL))!=NULL)
- cl=atoi(ss);
- ini_done();
- }
-
- info.mi_normal=cl;
- info.mi_hi=ch;
- info.ci_normal=ch;
- info.ci_hi=cl;
-
- for (i=0; i<MATRIX2_OPTIONS; i++)
- {
- build_showtextrec(&opt[i], 25, 7+i, 35, matrix2_str[i], JUSTIFY_CENTER, ' ');
- fillvarimenurec(&newmenu, &opt[i], SHOW_TEXT_TYPE, matrix2_str[i][0],
- matrix2_str[i][0], COMMON_ACTIVE);
- menu=addvarimenu(menu, &newmenu);
- }
-
- done=0;
- topdata=0;
-
- while((!done) && (!hangup))
- {
- outchr(12);
- _setcursortype(_NOCURSOR);
- if (ini_init("WWIV.INI", "LOGOFF_MATRIX", NULL)==0)
- {
- if ((ss=ini_get("RANDOM_MATRIX", -1, NULL))!=NULL)
- {
- if (ss[0]==*str_yes)
- random_screen("MATRIX2");
- else
- existprint("MATRIX2");
- }
- ini_done();
- }
- info.redraw=COMMON_FULL;
- varimenu(menu, &info);
- _setcursortype(_NORMALCURSOR);
- do_sysop_command(info.event);
- _setcursortype(_NOCURSOR);
-
- switch(info.event)
- {
- case EXECUTE:
- _setcursortype(_NORMALCURSOR);
- switch(info.returnvalue)
- {
- case 'T':
- time_bank();
- break;
- case 'P':
- nln(8);
- reqchat();
- pausescr();
- break;
- case 'F':
- nln(9);
- feedback(0);
- break;
- case 'Q':
- done=1;
- outchr(12);
- break;
- case 'L':
- done=1;
- outchr(12);
- if (ini_init("WWIV.INI", "LOGOFF_MATRIX", NULL)==0)
- {
- if ((ss=ini_get("CALL_AGAIN", -1, NULL))!=NULL)
- {
- if (ss[0]=='Y')
- call_again();
- }
- ini_done();
- }
- outchr(12);
- outstr(get_string(29));
- pl(ctim(timer()-timeon));
- existprint(get_string(1036));
- hangup=1;
- break;
- case 'M':
- nln(9);
- write_automessage();
- break;
- case 'B':
- nln(9);
- bbslist();
- break;
- }
- break;
- case GET_OUT:
- _setcursortype(_NORMALCURSOR);
- outchr(12);
- done=1;
- break;
- }
- }
- killvarimenu(menu);
- }
-
-
- ───[Step 2]────────────────────────────────────────────────────────────────────
-
- Load MMENU.C and replace the 2 "case 'O':" by this:
-
- case 'O':
- if (okansi()) {
- write_inst(INST_LOC_LOGOFF,0,INST_FLAGS_ONLINE);
- logoff_matrix();
- } else {
- nl();
- nl();
- prt(9,get_string(28));
- helpl=12;
- if (yn()) {
- if (ini_init("WWIV.INI", "LOGOFF_MATRIX", NULL)==0)
- {
- if ((s=ini_get("CALL_AGAIN", -1, NULL))!=NULL)
- {
- if (s[0]=='Y')
- call_again();
- }
- ini_done();
- }
- prt(9,"Leave a message to the sysop?");
- strcpy(irt,"Logoff Feedback");
- if (yn())
- feedback(2);
- prt(9,"Leave a message to next user?");
- if (yn())
- write_automessage();
- write_inst(INST_LOC_LOGOFF,0,INST_FLAGS_ONLINE);
- outchr(12);
- if (rip_on())
- random_screen("goodbye");
- outstr(get_string(29));
- pl(ctim(timer()-timeon));
- #ifdef RIPDRIVE
- rd_coff();
- #endif
- existprint(get_string(1036));
- hangup=1;
- }
- }
- break;
-
-
- ───[Step 3]────────────────────────────────────────────────────────────────────
-
- Load WWIV.INI, create a [LOGOFF_MATRIX] sub section and add the following
- lines:
-
- [LOGOFF_MATRIX]
- ; Color of Highlighted item in scroll menu.
- COLOR_HIGH = 31
- ; Color of other items in scroll menu.
- COLOR_LOW = 1
- ; Ask users with less than 3 logs if they want to keep their account
- CALL_AGAIN = YES
- ; Allow to use various ANSI matrix screen, like WELCOME.*
- RANDOM_MATRIX = NO
-
- ───[Step 4]────────────────────────────────────────────────────────────────────
-
- HOW TO ADD OPTIONS: (From the logon matrix, this is similar)
-
- You will have to know how to mod of course, but with this new version of
- the logon matrix, it is VERY easy to add new options.
-
- In LILO.C, you have:
-
- #define MATRIX_OPTIONS 7 // Amount of options in the matrix.
-
- You have to change the number, increasing or discreasing when you add or
- remove an option. This is absolutely needed. Then
-
- char *matrix_str [] = {
- "Log On The BBS",
- "Apply For Access",
- "Check For Validation",
- "Feedback To The Sysop",
- "Page Sysop",
- "Read Your Mail",
- "Quit Now", <--- Add a COMMA here
- "This is your new option" <--- Your new option
- };
-
- You can put your new option whereever you want it, but be sure the last label
- doesn't have a comma, all others should have one. BE SURE that the first line
- of the option is UNIQUE, because the matrix will use that letter as the hot
- key needed to run the matrix.
-
- That's it! Then you simply have to add a case there:
-
- case EXECUTE:
- _setcursortype(_NORMALCURSOR);
- switch(info.returnvalue)
- {
- case 'x': <-- x is the 1st letter of your option (Hotkey)
- /*
- * Add your function here.
- */
- break;
- case 'L':
- do
- {
-
- And you're done! Nothing is more easy.
-
- ───[Step 5]────────────────────────────────────────────────────────────────────
-
- Now you need to do a MAKE FCNS to have this function working okay, and then
- you just run this new BBS and enjoy your pulldown matrix logoff menu.
-
- Copy the file FMD.INI in your main WWIV directory, and copy MATRIX2.ANS in
- your GFILE directory. Feel free to modify it like you want it. Place also the
- file CALLAGAN.MSG in your GFILES directory and edit it for your needs.
-
- If you want to enable the RANDOM_MATRIX option, you need to do your own
- ANSI screen because we don't have any extra for the moment. Simply label them
- as MATRIX2.ANS, MATRIX2.0, MATRIX2.1, ... and place them in your language #1's
- directory (this is generally your gfiles directory)
-
-
- French Proverb: A l'impossible, nul n'est tenu.
-
- For comments, bug report and suggestion, e-mail at the following address:
-
- Nicolas LeBlanc 2@20302.WWIVnet (aka Spotnick)
- -> spotnick@gamemaster.qc.ca
- Martin Bourdages 242@20306 / 3@20302.WWIVnet (aka Dark Shadow)
- -> martin.bourdages@radio.magicnet.com
-
- => French Mod Division Support Sub <=
- SubType: FMD
- Host: @20302 (WWIVnet)
- Scan sublist for other networks
-
- Read PRODUCTS.FMD for the full list of our support systems.
-
- ───[EOF]──────────────────────────────────────────────────────────────────────
-