mIRC Home    About    Download    Register    News    Help

Print Thread
#34882 08/07/03 01:50 AM
Joined: Apr 2003
Posts: 24
S
Ameglian cow
OP Offline
Ameglian cow
S
Joined: Apr 2003
Posts: 24
I can' seem to get ignore to work correctly
No doubt im doing it completly wrong but Ive searched the forums here and so far allthough helpfull i still havent found the answer frown

What I want is a simple trigger driven ignore script
!stop on nick = ignore on
!stop off nick = off

I tried the following but seem to turn ignore on for all not just the person in question

on *:text:!stop *:#: {
if ($nick !isop $chan) { halt }
if ($2 == on) && ($3 != $null) {
set %nick $3
.ignore -pcnd $address(%nick, 9)
.msg $chan ignoring $3 $address($3,9) Reason: $4!
/echo -a %nick has been ignored for $4
}
if ($2 == off) && ($3 != $null) {
/ignore -r $address($3, 9)
.msg $chan ignoring on $3 is now off!
}
if ($3 == $null) {
msg $chan  Have we forgotten something $nick $+ ?
}
}

#34883 08/07/03 02:21 AM
Joined: Dec 2002
Posts: 3,547
S
Hoopy frood
Offline
Hoopy frood
S
Joined: Dec 2002
Posts: 3,547
This code works for me:
Code:
on *:text:!stop *:#: {
  if ($nick !isop $chan) { halt }
  if ($2 == on) && ($3 != $null) {
    set %nick $3
    ignore -pcnd $address(%nick,9) 
    msg $chan ignoring $3 $address(%nick,9) Reason: $4! 
    echo -a %nick has been ignored for $4 
  }
  if ($2 == off) && ($3 != $null) {
    ignore -r $address($3,9) 
    msg $chan ignoring on $3 is now off!
  }
  if ($3 == $null) {
    msg $chan  Have we forgotten something $nick $+ ?
  } 
} 

#34884 08/07/03 11:42 PM
Joined: Mar 2003
Posts: 54
J
Babel fish
Offline
Babel fish
J
Joined: Mar 2003
Posts: 54
/ignore also supports a type parameter, so you don't really have to use $address there.

#34885 09/07/03 12:04 PM
Joined: Apr 2003
Posts: 24
S
Ameglian cow
OP Offline
Ameglian cow
S
Joined: Apr 2003
Posts: 24
Thanks for your help guys seems I had a problem in my control.ini no doubt from ealier script tests my problem was that I had *!*@* in the control ini I have no idea how it got there but like i say it was no doubt from an earlier script.
Should of realised something was wrong I guess when I had to start using /ignore off
Wierd thing is I tried to remove and it would say they where not in there confused

Anyway script now works with a few minor details worked out smile


Link Copied to Clipboard