|
Joined: Oct 2005
Posts: 75
Babel fish
|
OP
Babel fish
Joined: Oct 2005
Posts: 75 |
i got this from hawkee's but did a lil editing, #flyby on
on !*:JOIN:#:{
if (% [ $+ [ $wildsite ] $+ ] .rd == $null) { set -u10 % [ $+ [ $wildsite ] $+ ] .rd on }
}
on !*@:PART:#:{
if (% [ $+ [ $wildsite ] $+ ] .rd != $null) { ban -u60 # $address($nick,1) | /splay unstable.wav | /msg $chan 15,15 14,14 2,2 5,15 Door Revolving 2,2 12,15 triggered by 2,2 4,15 $nick 2,2 12,15 in 2,2 4,15 # 2,2 4,15 Banned 12for4 60 Seconds 2,2 14,14 15,15 | notice $nick you've been placed on a 60 Seconds BAN for Door Revolving }
}
#flyby end it works fine, but was hoping if there is any way i could msg the nick of the person that got banned when the nick has been UNBANNED after that 60 seconds. that could scan if banned nick is still online or irc then it'll msg or notice the nick and tell the nick that he or she has been unbanned for that 60 ban if banned nick is no longer online or irc it won't do nothing. can that be done?...if yes how? or what do i do?
Last edited by Confuzzled; 05/12/05 10:01 AM.
|
|
|
|
Joined: Aug 2005
Posts: 525
Fjord artisan
|
Fjord artisan
Joined: Aug 2005
Posts: 525 |
You could store the nick in a temp var then set a timer to do a whois after the ban expires. At that point use the raw event to determine if the nick is still online and if so send a msg. I'm not sure though, maybe someone else knows a simpler way. Something like this on !*@:PART:#:{
if (% [ $+ [ $wildsite ] $+ ] .rd != $null) {
[color:green]; You should put these commands on separate lines
; It's much easier to read this way rather than all on one line[/color]
ban -u60 # $address($nick,1)
splay unstable.wav
msg $chan 15,15 14,14 2,2 5,15 Door Revolving 2,2 12,15 triggered by 2,2 4,15 $nick 2,2 12,15 in 2,2 4,15 # 2,2 4,15 Banned 12for4 60 Seconds 2,2 14,14 15,15
notice $nick you've been placed on a 60 Seconds BAN for Door Revolving
set %tmp1 $nick
set %tmp2 $chan
set %tmp3 $true
timer 1 60 whois $nick
}
}
raw 311:*:{
if (%tmp3) {
msg %tmp1 You were unbanned from %tmp2
unset %tmp*
}
} Since raw 311 isn't returned if the nick is offline, it should be ok to use that. I used a flag variable so that it doesn't send the unbanned message when you just do a normal whois.
Last edited by schaefer31; 05/12/05 05:58 PM.
|
|
|
|
Joined: Oct 2005
Posts: 75
Babel fish
|
OP
Babel fish
Joined: Oct 2005
Posts: 75 |
GREAT!,
works excellent, thank you very much for your huge help
|
|
|
|
Joined: Apr 2003
Posts: 701
Hoopy frood
|
Hoopy frood
Joined: Apr 2003
Posts: 701 |
You do know that it's allowed to put each command on a separate line? Scripts can have more than 3 lines...
|
|
|
|
Joined: Oct 2005
Posts: 75
Babel fish
|
OP
Babel fish
Joined: Oct 2005
Posts: 75 |
yes now i know, it's cause i'm not use to do each command on seperate line i'm being use to the | cause before when i try to do that it always misplace the full script maybe bracket mismatch but yes thank you guys for the huge help
|
|
|
|
Joined: Aug 2004
Posts: 7,252
Hoopy frood
|
Hoopy frood
Joined: Aug 2004
Posts: 7,252 |
Generally speaking scripts are easier to read & debug/repair if they don't use | since each command is then on a different line, it's easier to figure out just where a problem is. Additonally, using | limits you as to the number of characters & commands you can put on a single line.
I'm currently working on a revision of my Truth-or-Dare/Spin the bottle script, & I'd be going crazy if I had to use pipes, rather than separate lines.
|
|
|
|
|