mIRC Home    About    Download    Register    News    Help

Print Thread
#50052 18/09/03 01:17 PM
Joined: Dec 2002
Posts: 15
A
awn Offline OP
Pikka bird
OP Offline
Pikka bird
A
Joined: Dec 2002
Posts: 15
I want to have an audible alert if a certain person says a certain word. What is wrong with the following syntax?

Thanks in advance.

Code:
ON *:TEXT:*:#: {
  if (($nick == putnickhere) && (puttexthere isin $1-)){
  splay F:\WINDOWS\Media\pop.wav
}
}   

#50053 18/09/03 01:32 PM
Joined: Jun 2003
Posts: 242
R
Fjord artisan
Offline
Fjord artisan
R
Joined: Jun 2003
Posts: 242
You need a space between if statement and bracket
This ..
if (($nick == putnickhere) && (puttexthere isin $1-)){

Should be this ..
if (($nick == putnickhere) && (puttexthere isin $1-)) {

other than that it looks fine

Edit:
Also, if you want to match the exact word, you could use this ..
if (($nick == putnickhere) && ($istok($1-,putwordhere,32))) {

Or, you could use mIRC built in highlighting which will play a sound if you set it to do so, mIRC Options > IRC > Highlight

Last edited by r0ck0; 18/09/03 01:41 PM.

Link Copied to Clipboard