mIRC Home    About    Download    Register    News    Help

Topic Options
#187885 - 14/10/07 06:23 PM the winner is
spermis Offline
Babel fish

Registered: 26/02/07
Posts: 91
I need a pretty small script.

so if user who is OP writes !win Batman it will msg user with nick Spiderman this - The winner is Batman.

and if OP writes !win anyotherwthing it will msg user with nick Spiderman - The winner is anyotherwthing.

i think it is very easy

Top
#187887 - 14/10/07 06:33 PM Re: the winner is [Re: spermis]
schaefer31 Offline
Fjord artisan

Registered: 27/08/05
Posts: 525
Code:
on *:TEXT:!win &:#YourChannelGoesHere:{
  if ($nick isop #) && (Spiderman ison #) {
    msg $v1 The winner is $2
  }
}

Top
#187889 - 14/10/07 08:03 PM Re: the winner is [Re: schaefer31]
Lpfix5 Offline
Hoopy frood

Registered: 10/08/05
Posts: 1052
Loc: Canada
Originally Posted By: schaefer31
Code:
on *:TEXT:!win &:#YourChannelGoesHere:{
  if ($nick isop #) && (Spiderman ison #) {
    msg $v1 The winner is $2
  }
}


if ($nick isop #) is not needed

on @:TEXT:!win*:#yourchannel:{ if spiderman ison # msg $v1 The winner is $2 }
_________________________
Code:
if $reality > $fiction { set %sanity Sane }
Else { echo -a *voices* }

Top
#187891 - 14/10/07 08:29 PM Re: the winner is [Re: Lpfix5]
schaefer31 Offline
Fjord artisan

Registered: 27/08/05
Posts: 525
It is needed and the @ prefix is not a substitute for it. Read the first post a little closer. Also "!win &" instead of "!win*" is more appropriate in this case.

Top
#187898 - 14/10/07 09:29 PM Re: the winner is [Re: Lpfix5]
Riamus2 Offline
Planetary brain

Registered: 13/10/04
Posts: 8327
Loc: MA, USA
As schaefer mentioned, @ isn't a substitute for "if ($nick isop $chan)". @ is a substitute for "if ($me isop $chan)".
_________________________
Invision Support
#Invision on irc.irchighway.net

Top
#187913 - 15/10/07 01:51 AM Re: the winner is [Re: Riamus2]
Lpfix5 Offline
Hoopy frood

Registered: 10/08/05
Posts: 1052
Loc: Canada
Hmph I should get on the ball of on text events back again huh
_________________________
Code:
if $reality > $fiction { set %sanity Sane }
Else { echo -a *voices* }

Top
#187959 - 15/10/07 08:20 PM Re: the winner is [Re: Lpfix5]
spermis Offline
Babel fish

Registered: 26/02/07
Posts: 91
thanks everyone.

Top