home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Devil's Doorknob BBS Capture (1996-2003)
/
devilsdoorknobbbscapture1996-2003.iso
/
Dloads
/
WWIVMODS
/
MODSUNKN.ZIP
/
CHATWISH.MOD
< prev
next >
Wrap
Text File
|
1992-01-29
|
5KB
|
148 lines
/* ChatWish.mod -- written by: *
* Admiral Connors, Sysop of the Starport Equeluus, *
* Highland, Ca. *
* 714-864-1898 2400,8,N,1 *
* *
* *
* This modification was created for SysOps who wince at the idea of *
* crashing in on a user with the dramatic (but awsome) Two Way Chat. *
* Shift F9 prints a message to the user telling him/her that the *
* sysop wishes to chat with him/her, as soon as they are done with *
* what they are doing. The user then has the option of either ignoring *
* the message or hitting "C" to chat. Choosing the latter will put you *
* right into the appropriate chat mode. If he goes about on his merry *
* way and ignores you, you can hit the scroll lock and give him the *
* standard "Sysop not available" message when he finally decides >HE< *
* wants to chat.... *
*/
/*============================== In VARS.H add ============================*/
int wishes;
/*============================= In FCNS.H add =============================*/
void chatwish();
/*===================== In CONIO.C make these additions ===================*/
/* Add this after the other extern declarations */
extern int wishes;
/*========================== Also in CONIO.C ==============================*/
case 88: /* Shift-F5 */ /* Search on */
il=(rand() % 20) + 10;
for (i=0; i<i1; i++)
outchr(rand() % 256);
hangup=1;
dtr(0);
break;
case 92: /* Shift-F9 */ /* add */
wishes=1; /* add */
chatwish(); /* add */
break; /* add */
case 98: /* Ctrl-F5 */ /* Existing line */
/*=================== End of CONIO.C additions =============================*/
/*========== In BBSUTL.C add this after the other extern declarations ======*/
extern int wishes;
/*=========== Also, in BBSUTL.C add this function above void reqchat() =====*/
void chatwish()
{
char xl[81],cl[81],atr[81],cc,s[81];
savel(cl,atr,xl,&cc);
ansic(0);
nl();
nl();
pl("The SysOp wishes to chat with you...");
pl("If you would like to chat hit \"C\" when done,");
pl("or you can ignore this message.....");
nl();
nl();
restorel(cl,atr,xl,&cc);
}
/*========= Also in BBSUTL.C, make these mods to void reqchat() ============*/
void reqchat()
{
int ok,ok1; /* change */
char s[81];
nl();
nl();
ok=sysop2();
ok1=sysop1(); /* add */
if ((ok1) && (wishes==1)) { /* add */
wishes=0; /* add */
chat1("",1); /* add */
return; /* add */
} /* add */
if (restrict_chat & thisuser.restrict)
ok=0;
if (ok) {
if (chatcall) {
chatcall=0;
pl("Chat call turned off.");
topscreen();
} else {
helpl=3;
prt(2,"Reason: ");
inputl(s,70);
if (s[0]) {
chatcall=1;
strcpy(chatreason,"Chat: ");
strcat(chatreason,s);
nl();
sysoplog(chatreason);
for (ok=strlen(chatreason); ok<80; ok++)
chatreason[ok]=32;
chatreason[80]=0;
topscreen();
pl("Chat call turned ON.");
nl();
}
}
} else {
pl("Sysop not available.");
nl();
pl("Use feedback instead.");
if (wishes==1) { /* add */
wishes=0; /* add */
strcpy(irt,"Ignored Wish."); /* add */
imail(1,0); /* add */
} else { /* add */
strcpy(irt,"Tried Chatting.");
imail(1,0);
}
}
}
/*========================== End BBSUTL.C Changes ==========================*/
/* For now the sysop will have to be responsible for hitting scroll lock *
* if he changes his mind and walks away...That way the user doesn't get *
* stuck in chat... */
/* Beacuse items were added to VARS.H and FCNS.H, you must re-compile the *
* entire bbs. But I'm sure you knew that already! *
*/
/*=========================== End Chatwish.mod =============================*/