mIRC Homepage
Posted By: static6x9 ON:TEXT case sensetive - 14/07/03 01:15 AM
I've searched countless sites and this message board, I just can't get it right. I'm trying to right a script that will recognize a word and then play the sound, but I'd like the word case sensative I know it has to do with If-Then-Else commands but I'm clueless.
Posted By: Watchdog Re: ON:TEXT case sensetive - 14/07/03 01:21 AM
Use 'isincs' instead of 'isin'
Code:
ON *:TEXT:*:#: {
  if (WaTcHdoG isincs $1) {
    splay bark.wav
  }
}
If someone calls me by matching the case used in the script then the sound will play. If they use all lower or all upper case then it won't.
Posted By: static6x9 Re: ON:TEXT case sensetive - 14/07/03 01:26 AM
Sorry that didnt work, it just sent my mirc into a endless loop that killed it, thx tho
Posted By: Watchdog Re: ON:TEXT case sensetive - 14/07/03 01:33 AM
It's tested code so you must have left out a closing brace. Try it in it's own remote file.
Posted By: static6x9 Re: ON:TEXT case sensetive - 14/07/03 01:43 AM
ON *:TEXT:*:#: { if (WakeUP isincs $1) { splay C:\WINDOWS\MEDIA\Robotz Default.wav }}
I can't see it
Posted By: Watchdog Re: ON:TEXT case sensetive - 14/07/03 01:47 AM
Hmmm, you shouldn't have to for splay but try putting the filepath in inverted commas.
Code:
ON *:TEXT:*:#: {
 if (WakeUP isincs $1) {
   splay [color:red]"[/color]C:\WINDOWS\MEDIA\Robotz Default.wav[color:red]"[/color]
 }
}
Posted By: static6x9 Re: ON:TEXT case sensetive - 14/07/03 01:49 AM
IM getting /if: close bracket not found in my status, to me it looks like they are all closed
Posted By: Watchdog Re: ON:TEXT case sensetive - 14/07/03 01:54 AM
How are you formatting the script? If you are doing it on a single line I would remove the outer set of braces but leave everything else. If it is over four lines then it should work as-is.
Posted By: static6x9 Re: ON:TEXT case sensetive - 14/07/03 02:01 AM
Its all a straight line, I dropped the outta brackets no errors now, but no sound either I know the path is correct I tried with the "..." and adding the splay command of -w for wav I'm sorry to be a bother But hankyou for the help
Posted By: Watchdog Re: ON:TEXT case sensetive - 14/07/03 02:17 AM
It should work without the -w. There must be something else in your script that may be interfering. Make sure that there is only one ON TEXT event in each script file otherwise they will clash, usually resulting in only the first one working.
Posted By: static6x9 Re: ON:TEXT case sensetive - 14/07/03 02:23 AM
All my scripts are in working order frown Thanks for your help, Ill search the net some more
Posted By: Hammer Re: ON:TEXT case sensetive - 14/07/03 09:49 AM
on *:TEXT:*:#: if ($1 === WakeUP) splay "C:\WINDOWS\MEDIA\Robotz Default.wav"
Posted By: saragani Re: ON:TEXT case sensetive - 14/07/03 04:50 PM
He wrote:

ON *:TEXT:*:#: { if (WakeUP isincs $1) { splay C:\WINDOWS\MEDIA\Robotz Default.wav }}
I can't see it


He has }}

to closing backets which doesn't have space betweek them. I think that will make his script not to work.
Posted By: KingTomato Re: ON:TEXT case sensetive - 14/07/03 06:00 PM
WakeUp? that remins me of the old Multiplayer server MPlayer for games. You'd type it in a channel, and a wierd voice would yell "Wake up!".. Ahh, those were the days >:S
© mIRC Discussion Forums