Let me start out by showing you the stuff
menu channel,status {
¤ BotServ
.Botlist:bs botlist
.-
.Assign:bs ASSIGN $chsrv(Channel name. Leave blank for [ # ] ) $$?="Name of bot:" | erase
.UnAssign:bs UNASSIGN $chsrv(Channel name. Leave blank for [ # ] ) | erase
.-
That is just part of the BotServ portion of my popup script.
And for the aliases:
alias question {
set %temp.question $?=" $+ $1- $+ "
if (%temp.question != $null) { return %temp.question }
else { return $false }
unset %temp.*
}
alias chsrv {
%temp.chsrv = $?" $+ $1- $+ "
if (%temp.chsrv == $null) { set %temp.chsrv $active }
if ($chr(35) !isin %temp.chsrv) { %temp.chsrv = $chr(35) $+ %temp.chsrv | return %temp.chsrv }
else { return %temp.chsrv }
unset %temp.*
}
alias check if ($left($1,1) != $chr(35)) { return $chr(35) $+ $1- } | else { return $1- }
alias erase {
if (%temp.chsrv != $null) { .timer 1 1 unset %temp.chsrv }
if (%temp.question != $null) { .timer 1 1 unset %temp.question }
}
The problem is, whenever I unassign a bot, or do something similar with this script, even if I press cancel on the dialog box, it runs the command anyway as if I didn't type anything in the window, and pressed ok.
I want it to
not run the command if I press cancel.
The tricky part is that I also want to be able to not type a channel in the dialog box, and have it fill in the current active channel for me, like it's doing now.
Any help is greatly appreciated