[color:green]; alias to save the trigger, requires manual input:[/color]
[color:green]; /trig <nick> <complete trigger>[/color]
alias trig { write [color:blue]filename.txt[/color] $network $channel $1 $2- }
[color:green] [/color]
[color:green]; this deletes a trigger in the file if the file has been completely received[/color]
on *:FILERCVD:*: { if ($read([color:blue]filename.txt[/color],s,$nick)) write $+(-dl,$readn) [color:blue]filename.txt[/color] }
[color:green] [/color]
[color:green]; this will check for the right network and channel when you join,[/color]
[color:green]; then if the nick exists in your list, send the trigger[/color]
on me:*:JOIN:#: {
[color:green] ; opens a temporary window with all triggers with the right channel and network[/color]
window -h @tmp
filter -fw [color:blue]filename.txt[/color] @tmp $+(*,$network,*,$chan,*)
var %x = $line(@tmp,0)
[color:green] ; loop that reads lines from the window, checks for the user and sends the trigger[/color]
while (%x) {
var %y = $line(@tmp,%x))
tokenize 32 %y
if ($3 ison $chan) $4-
dec %x
}
[color:green] ; clean up after yourself![/color]
close -@ @tmp
}