Peace & Protection 4.00 — File Browser
PeaceProtection4.00v4.0 / PeaceProtection4.00v4.0 / ADDONS / XW.MRC
XW.MRC — 24.98 KB — Download this file
; #= xwzbot -rs
; ########################################
; Peace & Protection
; X/W (standard addon) part 1
; ########################################
alias -l _xwcmd if ($_isbot(x)) return /xw | return /z
alias -l _xwall if ($_isserv(xw)) { if ($_isbot(x)) return X / W | return Z }
; /xw [bot|?|!] command [#chan|?] [params]
alias z xw $1-
alias xw {
if (($_isserv(xw) == $false) && (($1 != auto) || ($istok(view clear,$2,32) == $false))) _error You cannot use /xw on this network./xw (or /z) only work on Undernet and OzOrg.
if (($_isbot($1) == $false) && ($1 !isin !?)) tokenize 32 ? $1-
var %chan,%param,%xw,%pw,%send,%who,%new,%old
if ($2 == $null) { var %cmd = $_xwcmd +command -#channel -parameters * ! $+ $_xwall command to perform | _qhelp $_s2f(%cmd) }
elseif ($_ischan($3)) { %chan = $3 | %param = $4- }
elseif (($istok(search map motd help showignore verify,$2,32)) || (($2 == auto) && ($istok(add del,$3,32) == $false))) %param = $3-
elseif ($active ischan) { %chan = $active | %param = $3- }
elseif ($3 == ?) { %chan = $_patch($_entry(-1,$null,Channel for,$2,command?)) | %param = $4- }
else _error No channel specified!You must use $_xwcmd in a channel or specify a channel.
if ($1 isin !?) {
if ($_isbot(z)) %xw = z
elseif (($2 == search) || (($2 == auto) && ($gettok(%param,1,32) != add))) %xw = x,w
elseif ((%chan ischan) && ($_chanbot(%chan))) %xw = $ifmatch
else {
%pw = $readini -n $_cfg(pw.ini) xw %chan
if (%pw != $null) %xw = $gettok(%pw,1,32)
elseif ($istok(map help verify,$2,32)) %xw = x
elseif ($1 == !) { set %.fullmsg Select which bot to use: | set %.found X,W | %xw = $$dialog(nickcomp,nickcomp,-4) }
else _error Cannot determine bot to use.Please specify which bot ( $+ $_xwall $+ ) to use.
}
}
else %xw = $1
if (($2 == set) && ($numtok(%param,32) == 1)) {
%send = msgxw %xw SET %chan $upper(%param) | goto %param
:MassDeopPro | %send $_entry(-2,3,Mass Deop Protection level?(number of deops in 15 seconds before a user is kicked.)) | return
:NickFloodPro | %send $_entry(-2,5,Nick Flood Protection level?(number of nick changes in 15 seconds causing a kick.)) | return
:FloodPro | %send $_entry(-2,7,Flood Protection level?(number of modes/topics in 15 seconds causing a kick.)) | return
:UserFlags | %send $_yesno(1,Should new,%xw,users be added with auto-op on?) | return
:NoOp | %send $_tf2o($_yesno(0,Disallow ops? (require all actions to use [ [ %xw ] $+ ] ?))) | return
:AlwaysOp | %send $_tf2o($_yesno(1,Should,%xw,always op itself if needed?)) | return
:OpOnly | %send $_tf2o($_yesno(0,Disable all basic,%xw,commands except OP?)) | return
:StrictOp | %send $_tf2o($_yesno(1,Disallow unknown users from being opped?)) | return
:Description | %send $_entry(1,$null,%xw,description for,%chan,?(80 characters max., blank to clear)) | return
:URL | %send $_entry(1,$null,%xw,URL for,%chan,?(80 characters max., blank to clear)) | return
:AutoTopic | %send $_tf2o($_yesno(1,Have,%xw,keep the description/URL as the channel topic?)) | return
:%param
}
elseif (($2 == modinfo) && ($numtok(%param,32) isnum 1-2)) {
if ($istok(Match Access AutoOp Password,$gettok(%param,1,32),32)) {
if ($gettok(%param,2,32)) %who = $_ncc($ifmatch,%chan)
else %who = $_entry(-1,$null,User to modify?Enter a nickname or address.)
%send = msgxw %xw MODINFO %chan $upper($gettok(%param,1,32)) %who
goto $gettok(%param,1,32)
:Match
if ($address(%who,5)) %new = $_entry(-1,$_usermask($ifmatch),New,%xw,mask to match for,%who,?User's address is,$address(%who,5))
else %new = $_entry(-1,$null,New,%xw,mask to match for,%who,?(User's actual address is unknown.))
%send $_fixmask(%new)
return
:Access
%send $_entry(-2,$null,New,%xw,access level for,%who,?(Level must be from 1 to 499.))
return
:Password
%new = $$?*="New %xw password for %who $+ ?"
if ($$?*="Please retype new password to confirm:" != %new) _error Passwords do not match.
%send %new
return
:AutoOp
%send $_tf2o($_yesno(1,Enable,%xw,auto-op for,%who,?))
}
}
elseif ($2 == auto) {
if ($gettok(%param,1,32) == add) {
if (%chan == $null) _error No channel specified.You must specify a channel to add an auto-login.
if ($gettok(%param,2,32)) %pw = $ifmatch
else {
%pw = $$?*="Password for auto-login to %xw on %chan $+ ?"
if ($$?*="Please retype password to confirm:" != %pw) _error Passwords do not match.
}
writeini $_cfg(pw.ini) xw %chan %xw $_pw.enc(%pw)
disp Auto-login to $:t(%xw) for $:s(%chan) added.
%old = $readini -n $_cfg(pw.ini) xw all
writeini $_cfg(pw.ini) xw all $addtok(%old,%chan,32)
}
elseif ($gettok(%param,1,32) == del) {
if (%chan == $null) _error No channel specified.You must specify a channel to delete an auto-login.
%pw = $readini -n $_cfg(pw.ini) xw %chan
if (%pw) {
%old = $readini -n $_cfg(pw.ini) xw all
%new = $remtok(%old,%chan,1,32)
if (%new == $null) remini $_cfg(pw.ini) xw all
else writeini $_cfg(pw.ini) xw all %new
remini $_cfg(pw.ini) xw %chan
disp Auto-login for $:s(%chan) deleted.
}
else disp No auto-login has been defined for $:s(%chan) $+ .
}
elseif ($gettok(%param,1,32) == view) {
%chan = $readini -n $_cfg(pw.ini) xw all
if (%chan == $null) disp No $_xwall auto-logins have been defined.
else {
_info /xw auto
dispr @Info $_xwall logins- ( $+ $numtok(%chan,32) total)
:vloop
%old = $gettok(%chan,1,32)
%pw = $readini -n $_cfg(pw.ini) xw %old
dispr @Info $:+ Login to $:t($gettok(%pw,1,32)) on $:s(%old)
%chan = $gettok(%chan,2-,32)
if (%chan) goto vloop
}
}
elseif ($gettok(%param,1,32) == clear) { remini $_cfg(pw.ini) xw | disp All $_xwall auto-logins have been deleted. }
else {
if (%chan) {
%pw = $readini -n $_cfg(pw.ini) xw %chan
if (%pw) { %xw = $gettok(%pw,1,32) | %pw = $_pw.enc($gettok(%pw,2,32)) | .msgxw %xw LOGIN %chan %pw | disprs %chan $:c(%chan) Logging into $:t(%xw) }
else _error No $_xwall login defined for %chan $+ .You can add an auto-login through popups.
}
else {
%chan = $readini -n $_cfg(pw.ini) xw all
if (%chan == $null) _error No $_xwall logins have been defined!You can add auto-logins through popups.
var %delay = 0
:aloop
%old = $gettok(%chan,1,32)
%pw = $readini -n $_cfg(pw.ini) xw %old
%xw = $gettok(%pw,1,32)
%pw = $_pw.enc($gettok(%pw,2,32))
.timer 1 %delay .msgxw %xw LOGIN %old %pw
inc %delay $iif(%delay < 2,1,4)
disprs %old $:c(%old) Logging into $:t(%xw)
%chan = $gettok(%chan,2-,32)
if (%chan) goto aloop
}
}
}
elseif (($numtok(%param,32) <= 1) && ($istok(kick adduser remuser ban access unsuspend suspend op deop,$2,32))) {
goto $2
:kick
if (%param) %who = $_ncc(%param,%chan)
else %who = $_entry(-1,$null,Who do you want to kick?You may also specify a mask to filterkick. (level 200 access))
%param = $_rentry(kick,1,$_s2p($_msg(kick)),Kick reason? (optional))
_recent2 kick 9 %param
msgxw %xw KICK %chan %who %param
return
:adduser
if (%param) _xwuser %xw %chan $_ncc(%param,%chan)
else _xwuser %xw %chan $_entry(-1,$null,Nickname to add to,%xw,?You will enter an address mask later.)
return
:suspend
if (%param) %who = $_ncc(%param,%chan)
else %who = $_entry(-1,$null,User to suspend?Enter a nickname or address.)
%param = $_entry(0,24hours,Suspend for how long?Enter X days, X hours, X min, or X sec.)
msgxw %xw SUSPEND %chan %who $gettok(%param,1,32) $iif($left($gettok(%param,2,32),1) isin hmds,$left($gettok(%param,2,32),1),h)
return
:ban
if (%param) %param = $_ncc(%param,%chan)
set %.xw %xw
set %.xw.chan %chan
set %.xw.param %param
msgxw $$dialog(xwban,xwban,-4)
return
:remuser
if (%param) %who = $_ncc(%param,%chan)
else %who = $_entry(-1,$null,User to remove from,%xw,?Enter a nickname or address.)
msgxw %xw REMUSER %chan %who
return
:unsuspend
if (%param) %who = $_ncc(%param,%chan)
else %who = $_entry(-1,$null,User to unsuspend?Enter a nickname or address.)
msgxw %xw UNSUSPEND %chan %who
return
:access
if (%param) %who = $_ncc(%param,%chan)
else {
%who = $_entry(1,$null,Who do you want access info on?(Press Enter for advanced options.))
if (%who == $null) {
set %.xw %xw
set %.xw.chan %chan
msgxw $$dialog(xwacc,xwacc,-4)
return
}
}
msgxw %xw ACCESS %chan %who -modif
return
:op | :deop
if (%param) %who = $_nccs(32,%chan,$_c2s(%param))
else %who = $_c2s($_entry(0,$null,User(s) to,$2?(You may specify multiple users)))
msgxw %xw $upper($2) %chan %who
}
elseif ($istok(search map motd help showignore verify,$2,32)) msgxw %xw $upper($2) %param
elseif (%param) msgxw %xw $upper($2) %chan %param
elseif ($istok(invite unban topic lbanlist bans login verify search set config modinfo newpass,$2,32)) {
%send = msgxw %xw $upper($2) %chan | goto $2
:invite | %send $_entry(-1,$iif(%chan !ischan,$me),User to invite to channel?) | return
:unban | %send $_entry(-1,$null,User to unban?Enter a nickname or address mask.) | return
:topic | %send $_rentry(topic,%chan,$_s2p($chan(%chan).topic),New channel topic?) | return
:lbanlist | %send $_entry(-1,*,Show,%xw,banlist entries matching what mask?Use * to list all entries) | return
:login | %send $$?*="Enter your %xw password:" | return
:verify | msgxw %xw VERIFY $_entry(-1,$null,Nickname of user to verify?Enter a user to find out if they are a legit cservice representative.) | return
:search | msgxw %xw SEARCH $_entry(0,$null,Enter a word or topic to search for:This will search, [ [ %xw ] $+ ] 's,database for matching channels.) | return
:set
editbox -ap /xw %xw $2 %chan
dispa Specify one of the following settings:
dispa - $:l(MassDeopPro NickFloodPro FloodPro UserFlags)
dispa - $:l(NoOp AlwaysOp OpOnly StrictOp)
dispa - $:l(Description URL AutoTopic)
dispa Or, use /xw config to edit settings interactively.
return
:config
if ($dialog(xwcfg)) { disprs %chan $:c(%chan) Cannot configure channel, configure dialog is already open | return }
disprs %chan $:c(%chan) Retrieving $:t(%xw) info for channel...
unset %-xwc.*
%-xwc.chan = %chan | %-xwc.bot = %xw
.msgxw %xw STATUS %chan
.msgxw %xw CHANINFO %chan
return
:modinfo
editbox -ap /xw %xw $2 %chan
dispa Specify one of the following settings:
dispa - $:l(Match Access AutoOp Password)
dispa Or, use /xw user to edit a user interactively.
return
:newpass
%pw = $$?*="New %xw password?"
if (%pw != $$?*="Please retype new password to confirm:") _error Passwords do not match.
msgxw %xw NEWPASS %chan %pw
}
else msgxw %xw $upper($2) %chan
}
; /msgxw bot full command
alias msgxw {
if (($2 == adduser) || (($2 == modinfo) && ($4 == password)) || ($2 == login) || ($2 == newpass)) {
dispr $iif($3,$3,-ai2) Using $:t($upper($1)) for command: $:h($gettok($1-,2- [ $+ [ $numtok($2-,32) ] ] ,32),?????)
_linedance .raw privmsg $iif($1 == x,X@channels.undernet.org,$iif($1 == z,Z@channels.oz.org,W@channels2.undernet.org)) : $+ $2-
if ($2 == newpass) {
var %pw = $readini -n $_cfg(pw.ini) xw $3
if (%pw) writeini $_cfg(pw.ini) xw $3 $gettok(%pw,1,32) $_pw.enc($4)
}
if ($2 == login) %-xwacc. [ $+ [ $3 ] ] = 500
}
else {
dispr $iif($3,$3,-ai2) Using $:t($upper($1)) for command: $:h($2-)
_linedance .raw privmsg $1 : $+ $2-
if ($2 == deauth) unset %-xwacc. $+ $3
}
}
on *:NOTICE:AUTHENTICATION SUCCESSFUL ON &:?:if ($_isbot($nick)) %-xwacc. [ $+ [ $left($4,-1) ] ] = 500
dialog xwacc {
title "Access search"
size -1 -1 340 270
box "", 1, 5 8 330 220
text "&Mask to search for:", 2, 10 35 112 16, right
edit "*", 3, 125 31 200 22, autohs
text "M&inimum access level:", 4, 10 59 112 16, right
edit "", 5, 125 55 200 22
text "M&aximum access level:", 6, 10 83 112 16, right
edit "", 7, 125 79 200 22
radio "&Show all users", 8, 20 111 200 16
radio "S&how users with auto-op", 9, 20 129 200 16
radio "Sh&ow users without auto-op", 10, 20 147 200 16
check "Sho&w when user was last modified...", 11, 20 177 200 16
text "...&and only if modified by this user:", 12, 10 198 198 16, right
edit "", 13, 210 194 115 22, autohs
button "OK", 101, 30 240 120 25, OK default
button "Cancel", 102, 185 240 120 25, cancel
edit "", 200, 1 1 1 1, hide result autohs
}
on *:DIALOG:xwacc:init:*:{
did -c $dname 8
did -a $dname 1 Searching for %.xw access on %.xw.chan $+ :
did -a $dname 200 %.xw ACCESS %.xw.chan
unset %.xw %.xw.chan
}
on *:DIALOG:xwacc:sclick:101:if (($did(13)) && (* !isin $did(13))) did -a $dname 13 !* | did -o $dname 200 1 $did(200) $iif($did(3),$gettok($did(3),1,32),*) $iif($did(5) isnum,-min [ $did(5) ] ) $iif($did(7) isnum,-max [ $did(7) ] ) $iif($did(9).state,-autoop) $iif($did(10).state,-noautoop) $iif(($did(11).state) || ($did(13)),-modif) $gettok($did(13),1,32)
dialog xwban {
title "Ban"
size -1 -1 340 230
box "", 1, 5 8 330 182
text "&Nick or mask to ban:", 2, 10 34 118 16, right
combo 3, 131 31 198 120, edit drop
text "&Reason for ban:", 4, 10 57 118 16, right
combo 5, 131 53 198 120, edit drop
text "Number of &hours for ban:", 6, 10 79 118 16, right
edit "336", 7, 130 75 30 22
text "(max. is 336, for 2 weeks)", 8, 164 79 150 16
radio "&Level 20 ban (cannot be op)", 9, 50 107 200 16
radio "L&evel 75 ban (normal ban)", 10, 50 125 200 16
radio "Le&vel 100 ban", 11, 50 143 200 16
radio "&Custom level:", 12, 50 161 80 16
edit "200", 13, 133 158 30 22, disable
button "OK", 101, 30 200 120 25, OK default
button "Cancel", 102, 185 200 120 25, cancel
edit "", 200, 1 1 1 1, hide autohs result
}
on *:DIALOG:xwban:init:*:{
_fillrec $dname 5 0 $_cfg(xwban.lis) %.xw.chan
if ($_dlgi(xwban1)) did -o $dname 7 1 $ifmatch
if ($_dlgi(xwban2)) {
var %ban = $_dlgi(xwban2)
if (%ban == 20) did -c $dname 9
elseif (%ban == 75) did -c $dname 10
elseif (%ban == 100) did -c $dname 11
else { did -c $dname 12 | did -oe $dname 13 1 %ban }
}
else did -c $dname 11
if ($numtok(%.xw.param,32) > 1) did -abc $dname 3 %.xw.param
elseif (%.xw.param) {
did -ac $dname 3 $ifmatch
if (*!*@* iswm %.xw.param) _ddaddm $dname 3 %.xw.param 022 030 100 002 111
elseif ($address(%.xw.param,5)) _ddaddm $dname 3 $ifmatch 022 030 100 002 111
}
did -a $dname 1 Setting %.xw ban on %.xw.chan $+ :
did -a $dname 200 %.xw BAN %.xw.chan
unset %.xw %.xw.chan %.xw.param
}
on *:DIALOG:xwban:sclick:101:{
if ($did(3) == $null) _error You must specify a user or mask to ban.
if ($did(5)) _recent2 xwban 9 $replace($did(5),$gettok($did(200),3,32),&channel&)
if ($did(7) isnum) _dlgw xwban1 $ifmatch
var %lvl = $iif($did(9).state,20,$iif($did(10).state,75,$iif($did(11).state,100,$iif($did(13) isnum,$did(13),75))))
_dlgw xwban2 %lvl
did -o $dname 200 1 $did(200) $gettok($did(3),1,32) $iif($did(7) isnum,$did(7),24) %lvl $did(5)
}
on *:DIALOG:xwban:sclick:*:if ($did < 12) did -b $dname 13 | elseif ($did == 12) did -e $dname 13
dialog xwuser {
title "Add user"
size -1 -1 340 315
box "", 1, 5 8 330 100
text "&Nickname:", 2, 10 34 78 16, right
edit "", 3, 90 31 240 22, autohs
text "&Address mask:", 4, 10 57 78 16, right
combo 5, 91 54 238 150, drop edit
text "&Level:", 6, 10 81 78 16, right
combo 7, 91 77 120 150, drop edit
box "Password:", 21, 5 115 330 105
text "You must enter a password for the new user. (enter it twice to confirm the password.)", 20, 20 135 300 30
text "&Password:", 8, 10 170 78 16, right
edit "", 9, 90 167 122 22, pass autohs
text "&Confirm:", 10, 10 193 78 16, right
edit "", 11, 90 190 122 22, pass autohs
box "Auto-op:", 12, 5 227 330 45
radio "&Default", 13, 30 246 60 16
radio "&Set to ON", 14, 105 246 80 16
radio "S&et to OFF", 15, 190 246 80 16
button "OK", 101, 30 282 120 25, OK default
button "Cancel", 102, 185 282 120 25, cancel
edit %.xw, 200, 1 1 1 1, hide autohs
edit %.xw.chan, 201, 1 1 1 1, hide autohs
}
on *:DIALOG:xwuser:init:*:{
if (%.xw.addr) { _ddaddm $dname 5 %.xw.addr 3 4 010 2 011 | did -c $dname 5 1 }
did -a $dname 3 %.xw.who
did -c $dname 13
loadbuf -otxwuser $dname 7 " $+ $scriptdirxw.ppa"
did -c $dname 7 3
did -a $dname 1 Adding user to %.xw on %.xw.chan $+ :
unset %.xw %.xw.addr %.xw.chan %.xw.who
}
on *:DIALOG:xwuser:sclick:101:{
if ($did(3) == $null) _error You must specify a nicknameUsers cannot be added without a nickname.
if ($did(9) == $null) _error You must specify a passwordUsers must be added with a password.
if ($did(9) != $did(11)) _error Passwords do now match.Please re-enter the password, exactly the same both times.
msgxw $did(200) ADDUSER $did(201) $did(3) $iif($did(5),$_fixmask($did(5))) $iif($gettok($did(7),1,32) isnum,$gettok($did(7),1,32),100) $did(9)
if ($did(13).state == 0) msgxw $did(200) MODINFO $did(201) AutoOp $did(3) $_tf2o($did(14).state)
}
alias _xwuser {
if (($address($3,5)) || ($4)) {
set %.xw $1
set %.xw.chan $2
set %.xw.who $3
if ($address($3,5)) set %.xw.addr $ifmatch
elseif ($4 != .) set %.xw.addr $4
else unset %.xw.addr
return $dialog(xwuser,xwuser,-4)
}
else {
disp Please wait, looking up address of $:t($3) $+ ...
_Q.userhost _xwuser $+ $1 $+ $+ $2 $+ $+ $3 $+ $+ &n!&a _xwuser $+ $1 $+ $+ $2 $+ $+ $3 $+ . $3
}
}
on me:*:JOIN:#:if ((%-skipautoxw) || (%-skipautoxw. [ $+ [ $chan ] ] )) return | if ($_isserv(xw)) { set -u120 %-skipautoxw. $+ $chan 1 | .xw auto $chan }
on *:JOIN:#:if (($_isserv(xw)) && ($_isbot($nick))) .xw auto $chan
alias _xw.connect if ($_isserv(xw)) { set -u120 %-skipautoxw 1 | .xw auto }
alias _xw.splice {
if ($1 == ?) {
if ($_isserv(xw) == $false) return 0
if ($istok(voice devoice mode,$3,32)) return 0
if ((%-xwacc. [ $+ [ $2 ] ] ) && ($_chanbot($2) isop $2)) return 1
return 0
}
goto $3
:kick | xw kick $2 $4- | return
:topic | xw topic $2 $4- | return
:op | :opme | xw op $2 $4- | return
:deop | xw deop $2 $4- | return
:unban | xw unban $2 $4 | return
:ban | xw ban $2 $4 336 75 $5-
}
alias -l xwpop {
unset %.xw*
if ($_isserv(xw)) {
if ($_chanbot($active)) set -u %.xw $ifmatch
else {
set -u %.xw2 $_xwall
if ($_isbot(z)) set -u %.xw1b Have Z join [450]
else {
set -u %.xw1b Have X join [450]
set -u %.xw2b Have W join [450]
}
}
set -u %.xwlogin $iif($readini -n $_cfg(pw.ini) xw $active,1,0)
}
}
menu status {
-
$_xwall
.Login
..Auto-logins (all):xw auto
..Manual...:xw ! login ?
..Deauth...:xw ! deauth ?
.-
.Recovery
..Unban yourself... [75]:xw ! unban ? $me
..Invite yourself... [100]:xw ! invite ? $me
..Clear mode... [400]:xw ! clearmode ?
.Commands
..Topic... [50]:xw ! topic ?
..Kick... [50]:xw ! kick ?
..-
..Ban... [75]:xw ! ban ?
..Unban... [75]:xw ! unban ?
..-
..Op... [100]:xw ! op ?
..Deop... [100]:xw ! deop ?
..-
..Suspend... [100]:xw ! suspend ?
.-
.Info
..Your access... [0]:xw ! access ? $me
..-
..Channel info... [0]:xw ! chaninfo ?
..Channel status... [1]:xw ! status ?
..$_xwall banlist... [0]:xw ! lbanlist ?
.$_xwall info
..Search channels...:xw search $_entry(0,$null,String to search for?)
..-
..Server map:xw map
..MOTD...:xw ! motd
..Ignorelist...:xw ! showignore
..Verify cservice rep...:xw verify $_entry(-1,$null,User to verify?(this will tell you if they are a cservice rep. or IRCop))
..-
..Help...:xw help $_entry(0,$null,Command to get,$_xwall,help on?)
.-
.$iif($_isbot(x),Webpages)
..CService home:http http://cservice.undernet.org
..-
..X / W commands list:http http://cservice.undernet.org/docs/xwcoms.html
..Register a channel:http http://cservice.undernet.org/regist/
..-
..Channel userlists:http http://cservice.undernet.org/main/userlist.html
..Channel banlists:http http://cservice.undernet.org/main/banlist.html
..Channel info:http http://cservice.undernet.org/main/chaninfo.html
..Channel search:http http://cservice.undernet.org/main/search.html
.$iif($_isbot(z),Webpages)
..oz.org home:http http://www.oz.org/
..Register a channel:http http://www.oz.org/aucs/
..Channel info:http http://www.oz.org/z/
}
menu @Banlist {
$_banpopxw
.Copy to bot banlist...:_transxw $active 0
.Move to bot banlist...:_transxw $active 1
}
alias -l _banpopxw if (($sline($active,1).ln > 5) && ($_isserv(xw)) && ($_chanbot($mid($active,11,$len($active))))) return $ifmatch
alias -l _transxw {
set %.xw.param (banlist transfer)
set %.xw.chan $mid($1,11,$len($1))
set %.xw $_chanbot(%.xw.chan)
var %num = 1,%todo = $$dialog(xwban,xwban,-4)
if ($2) var %blip = $mid(beI,$pos(bei,$mid($1,2,1),1),1)
:loop
if ($sline($1,%num)) {
msgxw $puttok(%todo,$gettok($ifmatch,2,9),4,32)
if ($2) _banrem $1 $sline($1,%num).ln %blip
else inc %num
goto loop
}
}
menu nicklist {
-
$xwpop:{ }
%.xw
.Op [100]:xw op $_c2s($$snicks)
.Deop [100]:xw deop $_c2s($$snicks)
.-
.Kick... [50]:xw kick $$1
.Ban... [75]:xw ban $$1
.-
.Access [0]:xw access $$1 -modif
.User
..Add user... [400]:xw adduser $$1
..Remove user [400]:xw remuser $$1
..-
..Auto-op... [400]:xw modinfo autoop $$1
..Match mask... [400]:xw modinfo match $$1
..Access... [400]:xw modinfo access $$1
..Password... [400]:xw modinfo password $$1
..-
..Verify cservice rep [0]:xw verify $$1
.-
.Suspend... [100]:xw suspend $$1
.Unsuspend [100]:xw unsuspend $$1
}
menu channel {
-
$xwpop:{ }
%.xw2
.Channel info [0]:xw ! chaninfo
.-
.Login to %.xw2 $+ ... [0]:if ($readini -n $_cfg(pw.ini) xw #) xw auto # | else xw ! login
.Deauthenticate [0]:xw ! deauth
.Change password... [0]:xw ! newpass
.-
.%.xw1b:xw $iif($_isbot(z),Z,X) join
.%.xw2b:xw W join
%.xw
.$iif(%.xwlogin,Login)
..Manual login...:xw login
..Deauthenticate:xw deauth
..Change password...:xw newpass
..-
..Perform auto-login:xw auto #
..Remove $replace($active,&,&&) auto-login...:_okcancel 1 Delete auto-login? | xw auto del
..-
..View all auto-logins:xw auto view
..Clear all auto-logins...:_okcancel 1 Delete ALL $_xwall auto-logins? | xw auto clear
.$iif(%.xwlogin == 0,Login)
..Login to %.xw $+ ...:xw login
..Deauthenticate:xw deauth
..Change password...:xw newpass
..-
..Add $replace($active,&,&&) auto-login...:xw auto add
..-
..View all auto-logins...:xw auto view
..Clear all auto-logins...:_okcancel 1 Delete ALL $_xwall auto-logins? | xw auto clear
.Info
..Channel info [0]:xw chaninfo
..Status [1]:xw status
..-
..Your access [0]:xw access $me
..Your commands [0]:xw showcommands
.-
.Topic... [50]:xw topic
.Invite... [100]:xw invite
.-
.Bans
..Ban... [75]:xw ban
..Unban... [75]:xw unban
..-
..List %.xw bans... [0]:xw lbanlist
..List channel bans [0]:xw banlist
..-
..Filterkick... [200]:xw kick
.Users
..View access... [0]:xw access
..-
..Suspend... [100]:xw suspend
..Unsuspend... [100]:xw unsuspend
..-
..Add user... [400]:xw adduser
..Remove user... [400]:xw remuser
..-
..Modify
...Auto-op... [400]:xw modinfo autoop
...Match mask... [400]:xw modinfo match
...Access... [400]:xw modinfo access
...Password... [400]:xw modinfo password
.-
.Join / part
..Have %.xw part [450]:xw part
..-
..Add to %.xw $+ 's auto-join [450]:xw addchan
..Remove from %.xw $+ 's auto-join [450]:xw remchan
..-
..Help!:{
dispa Asking $_xwall to join and part has the obvious effect, assuming the channel is in their database.
dispa The channel must also be added to the bot's auto-join, causing them to always join the channel if and when they restart.
dispa Any channel modes set (such as +tn) when adding to the auto-join list will be the 'default' channel modes, set if $_xwall joins and no one else is in the channel.
}
.Set
..Description... [450]:xw set description
..URL... [450]:xw set url
..Auto topic... [450]:xw set autotopic
..-
..Mass deop prot... [450]:xw set massdeoppro
..Nick flood prot... [450]:xw set nickfloodpro
..Flood protection... [500]:xw set floodpro
..-
..Always op... [450]:xw set alwaysop
..No op... [500]:xw set noop
..Strict op... [500]:xw set strictop
..Op only... [500]:xw set oponly
..-
..Auto op... [450]:xw set userflags
.Config... [450]:xw config
}