Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ; Modified BNC Script
- ;================================================================================== LOADING HASH TABLES
- ; Works for all anope/bahamut/hybrid
- #bnc off
- raw 307:*: set -u5 %checknick $2 | checkID %bncnick
- alias -l checkID {
- if ((%checknick == $1) && (!$hget($+($network,.aps),$+(%checknick,.tos)))) {
- .msg %checknick Okay. Your nickname appears to be %checknick $+ . If you would like to continue with using your nickname as your login username type "4use default" or type "4username YourSpecifiedUsername". NOTE: You need to remember this username to log into the BNC service. Please choose something that you will remember.
- var %n = $network | leafghoul %checknick on %n has accepted to comply with the BNC Terms of Service in their application. $asctime(dddd/mmm/yyyy - hh:nn:ss TT) $+ . Info: $address(%checknick,5)
- unset %checknick
- }
- else {
- .msg $1 Your nickname is not registered with NickServ. Please try again after you register. For help with registration, please type "4/nickserv help register"
- }
- }
- ;on *:notice:*:?:{
- ;tokenize 32 $strip($1-)
- ;if ($nick != NickServ) { return }
- ;elseif (*isn't registered* iswm $1- || *is not registered* iswm $1-) { .msg $2 Your nickname is not registered with NickServ. Please try again after you register. For help with registration, please type "4/nickserv help register" }
- ;elseif (* is * iswm $1-3) { set -u5 %checknick $1 }
- ;elseif (Info for *:* iswm $1-) { set -u5 %checknick $remove($3,:) }
- ;elseif (%checknick && !$hget($+($network,.aps),$+(%checknick,.tos))) {
- ;if (%checknick && !$hget($+($network,.aps),$+(%checknick,.tos))) {
- ;.msg %checknick Okay. Your nickname appears to be %checknick $+ . If you would like to continue with using your nickname as your login username type "4use default" or type "4username YourSpecifiedUsername". NOTE: You need to remember this username to log into the BNC service. Please choose something that you will remember.
- ;var %n = $network | ganjairc %checknick on %n has accepted to comply with the BNC Terms of Service in their application. $asctime(dddd/mmm/yyyy - hh:nn:ss TT) $+ . Info: $address(%checknick,5)
- ;unset %checknick
- ;}
- ;}
- on *:connect:{
- var %a = $qt($+($scriptdir,$network,.accounts.dat)), %b = $qt($+($scriptdir,$network,.aps.dat))
- hmake $+($network,.accounts) 100 | if ($exists(%a)) { hload $+($network,.accounts) %a }
- hmake $+($network,.aps) 100 | if ($exists(%b)) { hload $+($network,.aps) %b }
- }
- alias -l reloadthis {
- var %a = 1, %b
- while ($scon(%a)) {
- scid $v1
- var %x = $qt($+($scriptdir,$network,.accounts.dat)), %b = $qt($+($scriptdir,$network,.aps.dat))
- if (!$hget($+($network,.accounts))) { %b = $scriptdir, hmake $+($network,.accounts) 100 | if ($exists(%x)) { hload $+($network,.accounts) %x } }
- if (!$hget($+($network,.aps))) { hmake $+($network,.aps) 100 | if ($exists(%b)) { hload $+($network,.aps) %b } }
- inc %a
- }
- scid -r
- }
- on *:disconnect:{
- if ($hget($+($network,.accounts))) { hsave $+($network,.accounts) $qt($+($scriptdir,$network,.accounts.dat)) | hfree $+($network,.accounts) }
- if ($hget($+($network,.aps))) { hsave $+($network,.aps) $qt($+($scriptdir,$network,.aps.dat)) | hfree $+($network,.aps) }
- unset %flood.*
- }
- on *:start:{
- if (!$hget(suspended)) { hmake suspended 100 }
- if ($exists($qt($+($scriptdir,suspended.dat)))) { hload suspended $qt($+($scriptdir,suspended.dat)) }
- unset %flood.*
- .timersaveitall -o 0 300 saveitall
- ;Protected Admins (un deletable)
- if (!%protect) { %protect = zzbooze Exile }
- }
- on *:exit:{ saveitall }
- on *:load:{ %admins = zzbooze | %BNCBH = goblin.bnc.leafghoul.net | reloadthis }
- on *:unload:{ unset %admins | unset %flood.* | unset %protect | unset %BNCBH }
- ;=============================================================================== LOADING EXISTING ACCOUNTS TO
- ;alias loadall {
- ;hadd -m GanjaIRC.accounts Bot ACCEPTED $ctime $me $adate
- ;hadd -m xeromem.accounts Dragon ACCEPTED $ctime $me $adate
- ;hadd -m GanjaIRC.accounts Gdi ACCEPTED $ctime $me $adate
- ;hadd -m GanjaIRC.accounts Gul-Dukat ACCEPTED $ctime $me $adate
- ;hadd -m sytes.accounts Killer ACCEPTED $ctime $me $adate
- ;hadd -m GanjaIRC.accounts King ACCEPTED $ctime $me $adate
- ;hadd -m UnderNet.accounts PassWord ACCEPTED $ctime $me $adate
- ;hadd -m SwiftIRC.accounts T1 ACCEPTED $ctime $me $adate
- ;hadd -m purplesurge.accounts T2 ACCEPTED $ctime $me $adate
- ;hadd -m GanjaIRC.accounts T3 ACCEPTED $ctime $me $adate
- ;hadd -m dejatoons.accounts T4 ACCEPTED $ctime $me $adate
- ;hadd -m UnderNet.accounts ahbaht ACCEPTED $ctime $me $adate
- ;hadd -m UnderNet.accounts auto ACCEPTED $ctime $me $adate
- ;hadd -m GanjaIRC.accounts auto- ACCEPTED $ctime $me $adate
- ;hadd -m UnderNet.accounts bawawa ACCEPTED $ctime $me $adate
- ;hadd -m abjects.accounts bot-abject ACCEPTED $ctime $me $adate
- ;hadd -m GanjaIRC.accounts bot-ganja ACCEPTED $ctime $me $adate
- ;hadd -m SwiftIRC.accounts bot-swift ACCEPTED $ctime $me $adate
- ;hadd -m GanjaIRC.accounts dopeman ACCEPTED $ctime $me $adate
- ;hadd -m UnderNet.accounts gangstaa ACCEPTED $ctime $me $adate
- ;hadd -m GanjaIRC.accounts nick1 ACCEPTED $ctime $me $adate
- ;hadd -m UnderNet.accounts pilya ACCEPTED $ctime $me $adate
- ;hadd -m mindforge.accounts slayer ACCEPTED $ctime $me $adate
- ;hadd -m GanjaIRC.accounts stuck ACCEPTED $ctime $me $adate
- ;hadd -m trolol.accounts stuck1 ACCEPTED $ctime $me $adate
- ;hadd -m abjects.accounts stuck2 ACCEPTED $ctime $me $adate
- ;hadd -m GanjaIRC.accounts umadbor ACCEPTED $ctime $me $adate
- ;hadd -m rizon.accounts xzavier ACCEPTED $ctime $me $adate
- ;hadd -m GanjaIRC.accounts BluntMasta ACCEPTED $ctime $me $adate
- ;}
- ;======================= ALIASES
- alias -l saveitall {
- var %a = 1
- if (!%admins) { %admins = zzbooze }
- while ($scon(%a)) {
- scid $v1
- if ($hget($+($network,.accounts))) { hsave $+($network,.accounts) $qt($+($scriptdir,$network,.accounts.dat)) }
- if ($hget($+($network,.aps))) { hsave $+($network,.aps) $qt($+($scriptdir,$network,.aps.dat)) }
- inc %a
- }
- scid -r
- if ($hget(suspended)) { hsave suspended $qt($+($scriptdir,suspendid.dat)) }
- }
- alias -l getuser {
- if (!$1 || !$isid) { return }
- var %a = 1
- while ($scon(%a)) {
- scid $v1
- if ($hget($+($network,.accounts),$1)) { return $v1 }
- inc %a
- }
- scid -r
- }
- alias -l adduser {
- if ($1 == ACCEPT) {
- var %tmppass = $rand(a,z) $+ $rand(A,Z) $+ $rand(a,z) $+ $rand(A,Z) $+ $rand(1000,9999)
- .msg MemoServ send $2 [DO NOT DELETE THIS MEMO] Congratulations, your BNC has been accepted by the administrator: $nick $+ . To log onto it type /server %BNCBindHost $+ :53697 $2 $+ : $+ %tmppass - To change your password: /msg *admin set password <pass>- WebAdmin Page: http://BNC.Web.usr.sh
- .msg *admin adduser $2 %tmppass $hget($+($network,.aps),$+($2,.server))
- .msg *admin set Bindhost $2 %BNCBindHost
- .msg *admin set DenySetBindHost $2 true
- .msg *admin set PrependTimestamp $2 true
- .msg *admin set DCCBindHost $2 false
- .msg *partyline AddFixChan $2 ~#BNC
- .msg *admin loadmodule $2 stickychan #GhoulBNC
- .msg *admin set RealName $2 #GhoulBNC user. Home: (irc.leafghoul.net)
- .msg *admin set QuitMsg $2 #GhoulBNC - Free BNCs hosted by GhoulBNC on irc.leafghoul.net @ #GhoulBNC
- .msg *admin addctcp $2 PING PINGs are not accepted Hosted By: #GhoulBNC Home: (irc.leafghoul.net)
- .msg *admin addctcp $2 TIME Time: $time(h:nn:ssTT) Uptime: %uptime Hosted By: #GhoulBNC Home: (irc.leafghoul.net)
- .msg *admin addctcp $2 VERSION Version: GhoulBNC %version Hosted By: #GhoulBNC Home: (irc.leafghoul.net)
- .msg *admin Reconnect $2
- hadd -m $+($network,.accounts) $2 ACCEPTED $ctime $me $adate
- hadd -m $+($network,.aps) $+($2,.tos) accepted
- hadd -m $+($network,.aps) $+($2,.added) $ctime
- hadd -m $+($network,.aps) $+($2,.password) %tmppass
- hadd -m $+($network,.aps) $+($2,.bindhost) %BNCBindHost
- }
- }
- alias -l remuser {
- if (!$1) { return }
- var %a = 1
- while ($scon(%a)) {
- scid $v1
- hdel -m $+($network,.accounts) $1
- remhash $1
- inc %a
- }
- scid -r
- }
- alias -l remhash {
- if (!$1 || $isid) { return }
- while ($hfind($+($network,.aps),$+($1,.*),1,w).item) { hdel -m $+($network,.aps) $v1 }
- }
- alias -l checkuser {
- if (!$1 || !$isid) { return }
- var %a = 1
- while ($scon(%a)) {
- scid $v1
- if ($hget($+($network,.accounts),$1)) { return $true }
- inc %a
- }
- scid -r
- return $false
- }
- alias -l isuserblack {
- if (!$1) { return }
- var %b = $hget($+($network,.accounts),$1)
- if ($gettok(%b,1,32) == BLACKLISTED) { return $true }
- else { return $false }
- }
- alias -l fpro {
- if (!$1 || $isid) { return }
- set -u3 $eval($+(%,flood.,$1),1) $ctime
- }
- alias -l writefile { if (!$1) { return } | write $qt($+($scriptdir,todolist.txt)) $1- }
- alias -l playfile { if (!$1) { return } | .play $1 $qt($+($scriptdir,todolisttemp.txt)) 800 }
- alias -l cleanup { filter -cnff $qt($+($scriptdir,todolist.txt)) $qt($+($scriptdir,todolisttemp.txt)) }
- alias -l cleanupreport {
- if (!$1) { return }
- while ($hfind($+($network,.aps),$+(issue.,$1,*),1,w).item) { hdel $+($network,.aps) $v1 }
- }
- alias -l leafghoul {
- if (!$1) { return }
- var %a = 1, %b
- while ($scon(%a)) {
- %b = $v1
- scid %b
- if ($network == leafghoul) { .msg #GhoulBNCStaff $1- | break }
- inc %a
- }
- scid -r
- }
- ;alias updatebnc {
- ;var %a = hadd -m GanjaIRC.aps
- ;%a BluntMasta.bindhost Hermes.BNC.GanjaIRC.net
- ;%a Bug.bindhost Hermes.BNC.GanjaIRC.net
- ;%a Db0y.bindhost Hermes.BNC.GanjaIRC.net
- ;%a DeuS.bindhost Hermes.BNC.GanjaIRC.net
- ;%a Diamond.bindhost Hermes.BNC.GanjaIRC.net
- ;%a Dragon.bindhost Hermes.BNC.GanjaIRC.net
- ;%a Garand15.bindhost Hermes.BNC.GanjaIRC.net
- ;%a Gdi.bindhost Hermes.BNC.GanjaIRC.net
- ;%a Gul-Dukat.bindhost Hermes.BNC.GanjaIRC.net
- ;%a ImpendingDave.bindhost Hermes.BNC.GanjaIRC.net
- ;%a Inquisitor.bindhost Hermes.BNC.GanjaIRC.net
- ;%a King.bindhost Hermes.BNC.GanjaIRC.net
- ;%a Loing.bindhost Hermes.BNC.GanjaIRC.net
- ;%a MAFIA.bindhost Hermes.BNC.GanjaIRC.net
- ;%a Samar-Dukat.bindhost Hermes.BNC.GanjaIRC.net
- ;%a Shadow.bindhost Hermes.BNC.GanjaIRC.net
- ;%a THEONE.bindhost Hermes.BNC.GanjaIRC.net
- ;%a ahbaht.bindhost Hermes.BNC.GanjaIRC.net
- ;%a auto.bindhost Hermes.BNC.GanjaIRC.net
- ;%a auto-.bindhost Hermes.BNC.GanjaIRC.net
- ;%a bot-ganja.bindhost Hermes.BNC.GanjaIRC.net
- ;%a bot-riz.bindhost Hermes.BNC.GanjaIRC.net
- ;%a bungaw.bindhost Hermes.BNC.GanjaIRC.net
- ;%a da3v.bindhost Hermes.BNC.GanjaIRC.net
- ;%a dopeboy.bindhost Hermes.BNC.GanjaIRC.net
- ;%a ing.bindhost Hermes.BNC.GanjaIRC.net
- ;%a miniman.bindhost Hermes.BNC.GanjaIRC.net
- ;%a nick1.bindhost Hermes.BNC.GanjaIRC.net
- ;%a nickhere.bindhost Hermes.BNC.GanjaIRC.net
- ;%a oczx.bindhost Hermes.BNC.GanjaIRC.net
- ;%a passWORD.bindhost Hermes.BNC.GanjaIRC.net
- ;%a raj.bindhost Hermes.BNC.GanjaIRC.net
- ;%a rastagirl.bindhost Hermes.BNC.GanjaIRC.net
- ;%a slayer.bindhost Hermes.BNC.GanjaIRC.net
- ;%a stuck.bindhost Hermes.BNC.GanjaIRC.net
- ;%a stuck1.bindhost Hermes.BNC.GanjaIRC.net
- ;%a stuck2.bindhost Hermes.BNC.GanjaIRC.net
- ;%a stuck3.bindhost Hermes.BNC.GanjaIRC.net
- ;%a umadbor.bindhost Hermes.BNC.GanjaIRC.net
- ;%a xzavier.bindhost Hermes.BNC.GanjaIRC.net
- ;%a Bot.bindhost Poseidon.BNC.GanjaIRC.net
- ;%a T3.bindhost Poseidon.BNC.GanjaIRC.net
- ;%a bot-abject.bindhost Hyperion.BNC.GanjaIRC.net
- ;%a jorbz.bindhost Apollo.BNC.GanjaIRC.net
- ;%a pilya.bindhost Hyperion.BNC.GanjaIRC.net
- ;%a sHuT^d0wN.bindhost Hyperion.BNC.GanjaIRC.net
- ;%a Skype.bindhost Apollo.BNC.GanjaIRC.net
- ;echo $color(info) -ta * Imported BNC aps list complete.
- ;}
- ;alias fill {
- ;var %a = hadd -m GanjaIRC.aps
- ;%a BluntMasta.server irc.ganjairc.net
- ;%a BluntMasta.vhost Staff.GanjaIRC.net
- ;%a Bug.server irc.dal.net
- ;%a Db0y.server irc.criten.net
- ;%a Db0y.vhost old.sk00l.Dboy
- ;%a DeuS.server irc.esper.net
- ;%a Diamond.server irc.mindforge.org
- ;%a Dragon.server irc.chatnplay.net
- ;%a Garand15.server irc.rizon.net
- ;%a Garand15.vhost Full.Metal.vHost
- ;%a Gdi.server irc.ganjairc.net
- ;%a Gul-Dukat.server irc.ganjairc.net
- ;%a Gul-Dukat.vhost Staff.GanjaIRC.net
- ;%a ImpendingDave.server irc.freenode.net
- ;%a Inquisitor.server irc.ganjairc.com
- ;%a King.server irc.ganjairc.net
- ;%a King.vhost Staff.BNC.GanjaIRC.net
- ;%a Loing.server irc.undernet.org
- ;%a MAFIA.server irc.ganjairc.net
- ;%a Samar-Dukat.server irc.coldfront.net
- ;%a Shadow.server irc.lempo.uk.liberty-unleashed.co.uk
- ;%a THEONE.server irc.ganjairc.net
- ;%a THEONE.vhost ganjairc.ADMINS.sg
- ;%a ahbaht.server montreal.qc.ca.undernet.org
- ;%a auto.server irc.undernet.org
- ;%a auto-.server blunt.ganjairc.net
- ;%a bot-ganja.server blunt.ganjairc.net
- ;%a bot-ganja Staff.GanjaIRC.net
- ;%a bot-riz.server irc.rizon.net
- ;%a bot-riz.vhost GanjaBNC.Operational.net
- ;%a bungaw.server irc.undernet.org
- ;%a da3v.server irc.rizon.net
- ;%a dopeboy.server blunt.ganjairc.net
- ;%a dopeboy.vhost Staff.GanjaIRC.net
- ;%a ing.server irc.ganjairc.net
- ;%a ing.vhost Best.Loing.In.The.World
- ;%a miniman.server irc.quakenet.org
- ;%a nick1.server irc.ganjairc.net
- ;%a nick1.vhost Staff.GanjaIRC.net
- ;%a oczx.server irc.universochat.net
- ;%a passWORD.server irc.undernet.org
- ;%a raj.server irc.ganjairc.net
- ;%a rastagirl.server irc.ganjairc.net
- ;%a slayer.server irc.mindforge.org
- ;%a stuck.server irc.ganjairc.net
- ;%a stuck.vhost Staff.GanjaIRC.net
- ;%a stuck1.server irc.trolol.net
- ;%a stuck2.server irc.abjects.net
- ;%a stuck3.server irc.iptorrents.com
- ;%a umadbor.server Hermes.BNC.GanjaIRC.net
- ;%a umadbor.vhost sexy.penguin
- ;%a xzavier.server irc.rizon.net
- ;%a xzavier.vhost ganjairc.ADMINS.sg
- ;%a Bot.server irc.ganjairc.net
- ;%a Bot.vhost Hub.BNC.GanjaIRC.net
- ;%a T3.server irc.ganjairc.net
- ;%a T3.vhost The.Silent.Warrior
- ;%a bot-abject.server irc.abjects.net
- ;%a bot-abject.vhost GanjaBNC.Operational.net
- ;%a jorbz.server Irc.undernet.org
- ;%a jorbz.vhost AwT.username
- ;%a pilya.server eu.undernet.org
- ;%a sHuT^d0wN.server 5.175.160.217
- ;%a Skype.server oslo.no.eu.undernet.org
- ;echo $color(info) -ta * Adding server/vhost to accounts complete.
- ;}
- ;================================================================================================== OPTIONS
- on me:*:join:#:{ who # }
- alias -l lar { if ($1) { return $remove($replace($1,wks,w,wk,w,days,d,day,d,hrs,h,hr,h,mins,m,min,m,secs,s,sec,s),$chr(32)) } }
- alias -l countit {
- if (!$istok(%admins,$nick,32)) { return }
- elseif (!%BNCBH) { .msg # Bind Host list empty! | return }
- var %a = 1, %total = 0
- if ($hget($+($network,.accounts))) {
- inc %total $hget($+($network,.accounts),0).item
- }
- var %x = 1, %y, %z, %m
- while ($gettok(%BNCBH,%x,32)) {
- %z = $v1
- set -u5 $+(%,%z) 0
- %y = $gettok($v1,1,46)
- var %c = 1, %d
- while ($hfind($+($network,.aps),*.bindhost,%c,w).item) {
- %d = $hget($+($network,.aps),$v1)
- if (%z == %d || %y == $gettok(%d,1,46)) { inc $+(%,%z) }
- inc %c
- }
- inc %x
- }
- var %a = 1, %m
- while ($gettok(%BNCBH,%a,32)) {
- %m = %m $gettok($v1,1,46) $+ : $eval($+(%,$v1),2)
- inc %a
- }
- .msg # Total accounts: %total %m
- }
- ;================================================================================================== GhoulBNCSTAFF
- on *:text:*:#GhoulBNCstaff:{
- if ($eval($+(%,flood.,$nick),2)) { return }
- elseif (?help iswm $1-) {
- o var %s = $left($1,1)
- if (!$istok(%admins,$nick,32)) { return }
- else {
- .msg # Bot commands:
- var %a = 1, %t, %coms = bncentrymsg broadcast global bhview jump partyline unpartyline massbncheck status motd stickychan bl blview rembl remuser unblock block set adduser addadmin remadmin todo todolist todorem todoclear mode uptime dr ar ra report checkreport pending suspend suspended unsuspend bncbh rembncbh
- while ($gettok(%coms,%a,32)) { %t = %t $+(%s,$v1) | inc %a }
- .msg # %t
- }
- }
- elseif (?count iswm $1) {
- countit
- }
- elseif (?relay iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif (!$2 || !$istok(on off,$2,32)) { .msg # Invalid $1 option. Available: $1 on -or- $1 off }
- else {
- %relay = $2
- .msg # Relay is now: $2
- }
- }
- elseif (?info iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif (!$2) { .msg # Invalid $1 syntax! Syntax: $1 <account> }
- elseif (!$checkuser($2)) { .msg # No such records of $2 exist. }
- else { .msg # Info for $2 $+ ... | .msg # [TOS] $hget($+($network,.aps),$+($2,.tos)) [BindHost] $hget($+($network,.aps),$+($2,.bindhost)) [Server] $hget($+($network,.aps),$+($2,.server)) [Vhost] $hget($+($network,.aps),$+($2,.vhost)) [Added] $time($hget($+($network,.aps),$+($2,.added)),hh:nn:sstt mm/dd/yyyy) }
- }
- elseif (?suspended iswm $1-) {
- if (!$istok(%admins,$nick,32)) { return }
- else {
- var %a = 1, %b, %total = 0, %f, %c
- while ($hget(suspended,%a).item) {
- if (*.reason !iswm $v1) {
- %b = $hget(suspended,$hget(suspended,%a).item)
- %c = $hget(suspended,$+($hget(suspended,%a).item,.reason))
- inc %total
- %f = %f $hget(suspended,%a).item %c ( $+ $lar($duration($calc($ctime - %b))) ago)
- }
- inc %a
- }
- if (%total >= 1) { .msg # Current Suspended Networks: %f }
- else { .msg # No networks are suspended. }
- }
- }
- elseif (?unsuspend * iswm $1-) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif (!$hget(suspended,$2)) { .msg # $2 is not suspended! }
- else {
- hdel -m suspended $2
- hdel -m suspended $+($2,.reason)
- .msg # Removed $2 from suspended networks list.
- }
- }
- elseif (?suspend * iswm $1-) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif (!$3) { .msg # No reason supplied! }
- elseif ($hget(suspended,$2)) { .msg # $2 is already suspended! }
- else {
- hadd -m suspended $2 $ctime
- hadd -m suspended $+($2,.reason) $3-
- .msg # Added $2 to suspended networks list with reason: $3-
- }
- }
- elseif (?bhview iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- else {
- var %a = 1, %b, %total
- while ($gettok(%BNCBH,%a,32)) { %b = $gettok($v1,1,46) | %total = %total %b | inc %a }
- .msg # Current Bind Host list: $iif(!%total,No bind hosts,%total) $+ .
- }
- }
- elseif (?rembh iswm $1 && $2) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif ($istok(%BNCBH,$2,32)) {
- scon -at1 .msg #GhoulBNCStaff [BIND HOST] $nick has removed the Bind Host: $2 from the GhoulBNC Service.
- %BNCBH = $remtok(%BNCBH,$2,1,32)
- .msg *status RemBindHost $2
- }
- else {
- scon -at1 .msg # $2 wasn't located in the Bind Host list.
- }
- }
- elseif (?addbh iswm $1 && $2) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif (!$istok(%BNCBH,$2,32)) {
- scon -at1 .msg #GhoulBNCStaff [BIND HOST] $nick has added the Bind Host: $2 to the GhoulBNC Service.
- %BNCBH = %BNCBH $2
- ;%BNCBindHost = $2
- }
- else {
- scon -at1 .msg # $2 already exists in the Bind Host list.
- }
- }
- elseif (?bncbh iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif (!$2) { .msg # Invalid $1 syntax. Syntax: $1 <bindhost> }
- elseif (!$istok(%BNCBH,$2,32)) { .msg # Invalid bindhost! $+($left($1,1),bhview) to list. }
- else {
- %BNCBindHost = $2
- .msg # BNC Active bind host is now: $2
- }
- }
- elseif (?rembncbh iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif (!$2) { .msg # Invalid $1 syntax. Syntax: $1 <bindhost> }
- elseif (!$istok(%BNCBindHost,$2,32)) { .msg # Invalid bindhost! $+($left($1,1),bhview) to list. }
- else {
- ;unset %BNCBindHost $remtok(%BNCBindHost,$2,0,32)
- set %BNCBindHost $remtok(%BNCBindHost,$2,1,32)
- .msg # Removed BNC bind host: $2
- }
- }
- elseif (?bnctopic iswm $1 && $2) {
- if (!$istok(%admins,$nick,32)) { return }
- .scon -at1 topic #GhoulBNC $2- ( $+ $nick $+ )
- }
- elseif (?bncentrymsg iswm $1 && $2) {
- if (!$istok(%admins,$nick,32)) { return }
- .scon -at1 cs set #GhoulBNC entrymsg $2-
- }
- elseif (?broadcast iswm $1 && $2) {
- if (!$istok(%admins,$nick,32)) { return }
- msg *status Broadcast [ $+ $time(ddd mmm dd yyyy @ hh:nn:ss TT) $+ ]: Broadcast Message: $nick $2-
- scon -at1 msg #GhoulBNCStaff $time(ddd mmm dd yyyy @ hh:nn:ss TT) $+ : Broadcast Message: $nick $2-
- }
- elseif (?global iswm $1 && $2) {
- if (!$istok(%admins,$nick,32)) { return }
- scon -at1 .msg #GhoulBNCStaff $time(ddd mmm dd yyyy @ hh:nn:ss TT) $+ : Global Admin Message: $nick $2-
- }
- elseif (?jump iswm $1 && $2) {
- if (!$istok(%admins,$nick,32)) { return }
- .msg *admin Reconnect $2
- }
- elseif (?partyline iswm $1 && $3) {
- if (!$istok(%admins,$nick,32)) { return }
- msg *partyline addfixchan $2 $3-
- }
- elseif (?unpartyline iswm $1 && $2) {
- if (!$istok(%admins,$nick,32)) { return }
- msg *partyline delfixchan $2 $3-
- }
- elseif (?massbncheck iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- var %a = 0, %b = 0, %c = 0, %d = 0, %e = 0, %f, %x = 1
- while ($hget($+($network,.accounts),%x).item) {
- %f = $v1
- if ($gettok($hget($+($network,.accounts),%f),1,32) == accepted) { inc %a }
- elseif ($gettok($hget($+($network,.accounts),%f),1,32) == denied) { inc %b }
- elseif ($gettok($hget($+($network,.accounts),%f),1,32) == pending) { inc %c }
- elseif ($gettok($hget($+($network,.accounts),%f),1,32) == blocked) { inc %d }
- elseif ($gettok($hget($+($network,.accounts),%f),1,32) == blacklisted) { inc %e }
- inc %x
- }
- .msg # ------ START STATUS CHECK ---------
- .msg # We have %a accepted bnc users.
- .msg # We have %b denied bnc users.
- .msg # We have %c pending bnc users.
- .msg # We have %d blocked bnc users.
- .msg # We have %e blacklisted bnc users.
- }
- elseif (?status iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- .msg # ------ START STATUS CHECK ---------
- .msg # Nickname: [ $+ $me $+ ].
- .msg # Identd: [ $+ $gettok($address($me,5),1,33) $+ ].
- .msg # Hostname: [ $+ $address($me,2) $+ ].
- .msg # I am currently on $scid(0) network $+ $chr(40) $+ s $+ $chr(41) $+ .
- .msg # ------- END STATUS CHECK ----------
- }
- elseif (?motd iswm $1 && $2) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif (set == $2) {
- if (!$3) { .msg # No set parameter! | return }
- .msg *status setmotd Message of the day: $3-
- .msg # MOTD has been updated.
- }
- elseif (clear == $2) {
- .msg *status clearmotd
- .msg $chan MOTD has been cleared.
- }
- else {
- .msg $nick Syntax is: $1 set [message] OR to clear use: $1 clear
- }
- }
- elseif (?stickychan iswm $1 && $3) {
- ;======================================= OTHER ADMIN COMMANDS
- if (!$istok(%admins,$nick,32)) { return }
- .msg *admin loadmodule $2 stickychan $3
- }
- elseif (?bl iswm $1 && $1 != bbl && $2) {
- ;===================================== BLACKLIST
- if (!$istok(%admins,$nick,32)) { return }
- elseif ($gettok($getuser($2),1,32) == blacklisted) { .msg # $2 is already blacklisted! }
- else {
- scon -at1 .msg #GhoulBNCStaff [BLACKLIST] $2 has been blacklisted from GhoulBNC Services for: $3-
- hadd -m $+($network,.accounts) $2 BLACKLISTED $ctime $nick $adate
- }
- }
- elseif (?blview iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- var %a = 1, %b, %total
- while ($hfind($+($network,.accounts),%a).item) { %b = $v1 | if ($gettok($hget($+($network,.accounts),%b),1,32) == blacklisted) { %total = %total %b } | inc %a }
- .msg # Current Blacklist: $iif(!%total,None have been blacklisted,%total)
- }
- elseif (?rembl iswm $1 && $2) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif ($gettok($getuser($2),1,32) != blacklisted) { .msg # Username is not blacklisted! }
- else {
- scon -at1 .msg #GhoulBNCStaff [BLACKLIST] $2 has been unblacklisted from GhoulBNC Services.
- hdel -m $+($network,.accounts) $2
- }
- }
- elseif (?remuser iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif (!$2) { .msg # Invalid $1 syntax. Syntax: $1 <nick> | fpro $nick | return }
- elseif (!$checkuser($2)) { .msg # No such account! | fpro $nick | return }
- remuser $2
- .msg # $nick Deleted $2 from database...
- .msg *admin set QuitMsg $2 #GhoulBNC -- Free BNCs hosted by GhoulBNC on irc.leafghoul.net @ #GhoulBNC - BNC deleted by: $nick
- .timer 1 1 .msg *admin deluser $2
- }
- elseif (?unblock iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif ($gettok($getuser($2),1,32) == BLOCKED) {
- hdel -m $+($network,.account) $2
- .msg # $nick Added $2 to UNBLOCK
- }
- else { .msg # $2 is not blocked! }
- }
- elseif (?block iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif ($gettok($getuser($2),1,32) != BLOCKED) {
- hadd -m $+($network,.account) $2 BLOCKED $ctime $nick $adate
- .msg # $nick Added $2 to BLOCKED
- }
- else { .msg # $2 is already blocked! }
- }
- elseif (?set iswm $1) {
- if (!$istok(%admins,$nick,32) || !$istok(BNCServerVar BNCBindHost,$2,32)) { return }
- if ($2 == BNCServerVar) { set %BNCServerVar $3 }
- elseif ($2 == BNCBindHost) { set %BNCBindHost $3 }
- .msg # [VARS] $2 has been set to: $3 $+ .
- }
- elseif (?accept iswm $1) {
- ;Check NickServ first before adding...
- if (!$2 || !$istok(%admins,$nick,32)) { return | echo -a 1 }
- elseif ($gettok($getuser($2),1,32) == ACCEPTED) { echo -a 2 | .msg # Nick $2 has already been ACCEPTED | fpro $nick | return }
- elseif (!$hget($+($network,.aps),$+($2,.tos))) { echo -a 3 | .msg # Nick $2 has not completed their application! }
- else {
- echo -a 4
- adduser ACCEPT $2
- leafghoul Nick $2 has now been ACCEPTED...
- }
- }
- elseif (?decline iswm $1) {
- if (!$2 || !$istok(%admins,$nick,32)) { return }
- elseif ($gettok($hget($+($network,.accounts),$2),1,32) == DECLINED) { .msg # Nick $2 has already been DECLINED }
- else { hadd -m $+($network,.accounts) $2 DECLINED $ctime $nick $adate | hadd -m $+($network,.aps) $+($2,.tos) declined | .msg # Nick $2 has now been DECLINED }
- }
- elseif (?adduser iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif (!$istok(pending accepted declined blocked blacklisted,$3,32) || !$2) { .msg # Invalid syntax. Syntax: $1 <username> [pending/accepted/declined/blocked/blacklisted] | fpro $nick | return }
- elseif ($gettok($hget($+($network,.accounts),$2),1,32) == $3) { .msg # $2 exists in the database as $3 already! | fpro $nick | return }
- else {
- hadd -m $+($network,.accounts) $2 $upper($3) $ctime $nick $adate
- .msg # $nick Added $2 to database...
- leafghoul $nick Added $2 to database as $upper($3) $+ ...
- if ($3 == accepted) {
- hadd -m $+($network,.aps) $+($2,.server) %BNCBindHost
- adduser ACCEPT $2
- }
- }
- }
- elseif (?addadmin iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif ($istok(%admins,$2,32)) { .msg # $2 exists in the database as Admin already! | fpro $nick | return }
- elseif ($gettok($hget($+($network,.accounts),$2),1,32)) { .msg # Account exists under $2 $+ ! | fpro $nick | return }
- else {
- %admins = %admins $2
- hadd -m $+($network,.aps) $+($2,.server) %BNCBindHost
- .msg # $nick Added $2 to admin database...
- leafghoul [New ADMIN] User ( $+ $2 $+ ) has been added to BNC by $nick $+ .
- scon -at1 .msg #GhoulBNC [New ADMIN] User ( $+ $2 $+ ) has been added to BNC by $nick $+ .
- adduser ACCEPT $2
- }
- }
- elseif (?remadmin iswm $1) {
- ; Set this var to the nicks to protect against !remadmin (protected admin)
- if (!$istok(%admins,$nick,32)) { return }
- elseif (!$2) { .msg # Invalid syntax. Syntax: $1 <nick> }
- elseif (!$istok(%admins,$2,32)) { .msg # $2 does not exists in the database as Admin! }
- elseif ($istok(%protect,$2,32)) { .msg # You cannot delete this protected admin! }
- else {
- leafghoul [New ADMIN] User ( $+ $2 $+ ) has been removed from the BNC by $nick $+ .
- scon -at1 .msg #GhoulBNC [New ADMIN] User ( $+ $2 $+ ) has been removed from the BNC by $nick $+ .
- %admins = $remtok(%admins,$2,1,32)
- }
- }
- elseif (?todo* iswm $1) {
- ;======================================== TODO List
- if (!$istok(%admins,$nick,32)) { return }
- if (!$2) { .msg # Error: invalid $1 syntax. Syntax: $1 <text> }
- elseif (?todolist iswm $1) { .msg # TODO List: | cleanup | playfile # }
- elseif (?todorem iswm $1) {
- if ($2 !isnum) { .msg # Error: Specify the line number to delete. }
- elseif (!$read($qt($+($scriptdir,todolist.txt)),$2)) { .msg # Error: No such line number $qt($2) }
- else { .msg # Deleted todo line $qt($2) | write $+(-dl,$2) $qt($+($scriptdir,todolist.txt)) }
- }
- elseif (?todoclear iswm $1) {
- .msg # $nick $+ , $chr(47) $+ CLEARED $+ $chr(47) (Todo Events)
- write -c $qt($+($scriptdir,todolist.txt))
- write -c $qt($+($scriptdir,todolisttemp.txt))
- }
- elseif (?todo == $1) {
- write $qt($+($scriptdir,todolist.txt)) $timestamp $nick $+ : $2-
- .msg # $nick $+ , (Todo Events Updated)
- }
- else {
- .msg # Sorry, $1 is not a valid command. Use ?todolist, ?todorem, ?todoclear, and ?todo - Thanks!
- }
- }
- elseif (?ar iswm $1) {
- ;==================================== REPORT SECTION
- if (!$istok(%admins,$nick,32)) { return }
- elseif (!$3) { .msg # Invalid $1 syntax. Syntax: $1 <ID> <answer> }
- elseif ($hget($+($network,.aps),$+(issue,$2,.status)) == accepted) { .msg # Report has already been ACCEPTED }
- else {
- hadd -m $+($network,.aps) $+(issue,$2,.status) accepted
- hadd -m $+($network,.aps) $+(issue,$2,.reply) $3-
- .msg # Report has now been ACCEPTED
- }
- }
- elseif (?dr iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif (!$3) { .msg # Invalid $1 syntax. Syntax: $1 <ID> <reason> }
- elseif ($hget($+($network,.aps),$+(issue,$2,.status)) == declined) { .msg # Report has already been DECLINED }
- else {
- hadd -m $+($network,.aps) $+(issue,$2,.status) declined
- hadd -m $+($network,.aps) $+(issue,$2,.reply) $3-
- .msg # Report has now been DECLINED
- }
- }
- elseif (?ra iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- elseif (!$3) { .msg # Invalid $1 syntax. Syntax: $1 <ID> <reason> }
- elseif ($hget($+($network,.aps),$+(issue,$2))) {
- hadd -m $+($network,.aps) $+(issue,$2,.status) solved
- hadd -m $+($network,.aps) $+(issue,$2,.reply) $3-
- .msg # Report has now been SOLVED and replied with text: $3-
- }
- else { .msg # No such report! }
- }
- elseif (?pending iswm $1) {
- if (!$istok(%admins,$nick,32)) { return }
- write -c $qt($+($scriptdir,pending.txt)) Pending BNC users:
- var %a = 1, %b, %c, %total, %inc = 0, %x
- while ($hget($+($network,.accounts),%a).item) {
- %c = $v1
- %b = $hget($+($network,.accounts),%c)
- %x = $hget($+($network,.aps),$+(%c,.username))
- if ($gettok(%b,1,32) == pending) { inc %inc | write $qt($+($scriptdir,pending.txt)) $+($chr(40),%inc,$chr(41)) Username: %c server: $hget($+($network,.aps),$+(%c,.server)) vhost: $iif($hget($+($network,.aps),$+(%c,.vhost)),$v1,None Specified) reason: $hget($+($network,.aps),$+(%c,.reason)) }
- inc %a
- }
- if (%inc == 0) { .msg # No pending BNC accounts. }
- else { .play # $qt($+($scriptdir,pending.txt)) 800 }
- }
- elseif (?mode iswm $1 && $2) {
- ;============================================ OTHER COMMANDS
- if (!$istok(%admins,$nick,32)) { return }
- elseif ($left($2,1) == +) || ($left($2,1) == -) {
- scon -at1 mode #GhoulBNC $2-
- .msg # [MODE] Set mode of #GhoulBNC to $2- across all networks.
- }
- }
- elseif (?uptime iswm $1) {
- set -u5 %chan #
- .msg *status uptime
- }
- fpro $nick
- }
- alias relay {
- ;Syntax: relay nick network text
- var %a = 1
- while ($scon(%a)) {
- scid $v1
- if ($network == leafghoul) { .msg #GhoulBNCstaff $+(<,$1,>) $+([,$2,]) $3- }
- }
- }
- ;=================================================================================== GhoulBNC
- on *:text:*:#GhoulBNC:{
- if ($eval($+(%,flood.,$nick),2)) { return }
- elseif ($hget(suspended,$network)) { return }
- elseif (?uptime iswm $1) {
- set -u5 %chan #
- .msg *status uptime
- }
- elseif (?count iswm $1) {
- countit
- }
- elseif (?suspended iswm $1-) {
- var %a = 1, %b, %total = 0, %f, %c
- while ($hget(suspended,%a).item) {
- if (*.reason !iswm $v1) {
- %b = $hget(suspended,$hget(suspended,%a).item)
- %c = $hget(suspended,$+($hget(suspended,%a).item,.reason))
- inc %total
- %f = %f $hget(suspended,%a).item %c ( $+ $lar($duration($calc($ctime - %b))) ago)
- }
- inc %a
- }
- if (%total >= 1) { .msg # Current Suspended Networks: %f }
- else { .msg # No networks are suspended. }
- }
- elseif (?help iswm $1-) {
- var %s = $left($1,1)
- .msg # Bot commands:
- var %a = 1, %t, %coms = check bnchelp request report checkreport
- while ($gettok(%coms,%a,32)) { %t = %t $+(%s,$v1) | inc %a }
- .msg # %t
- }
- elseif (?check iswm $1) {
- if (!$2) { .msg # Invalid $1 syntax. Syntax: $1 <nick> }
- elseif ($checkuser($2)) {
- var %a = $gettok($getuser($2),1,32), %b = $gettok($getuser($2),2,32)
- if (%a == pending) { .msg # This account is waiting to be processed, please check back later. Request info, server: $hget($+($network,.aps),$+($2,.server)) port: $hget($+($network,.aps),$+($2,.port)) - if any item is incorrect, please use !report }
- elseif (%a == accepted) { .msg # This request was accepted, please look for the information memo. The account was added to the $gettok(%BNCBindHost,1,46) server. If you did not receive the information memo or there is a problem with the account, please use !report if staff are not available. }
- elseif (%a == blacklisted) { .msg # This account has been BLACKLISTED $asctime(%b,h:nn:ssTT m/d/yy) }
- elseif (%a == blocked) { .msg # This account has been BLOCKED $asctime(%b,h:nn:ssTT m/d/yy) }
- elseif (%a == declined) { .msg # This account has been DECLINED $asctime(%b,h:nn:ssTT m/d/yy) }
- elseif (%a == deleted) { .msg # This account has been DELETED $asctime(%b,h:nn:ssTT m/d/yy) }
- }
- else { .msg # $2 account was not found in the request records during the last 60 days. Make sure you have the exact username, including any CaPs if used. }
- fpro $nick
- }
- elseif (?bnchelp iswm $1) { .msg # $nick $+ , To apply for a BNC, please type: !request (in #GhoulBNC) }
- elseif (?request iswm $1-) {
- if (!%checkuser) {
- .msg # Thank you for your interest in our BNC software. An automated message will message you in 3 seconds...
- .timer 1 3 .msg $nick Hello, I am $me $+ , an automated BNC bot designed to guide you through the BNC application process.
- .timer 1 3 .msg $nick You need to refrain from breaking any of $network $+ 's rules while using this BNC service.
- .timer 1 3 .msg $nick If you accept our Terms of Service, please type "4accept" if not please type "4decline".
- .timer 1 3 .msg $nick NOTE: At any time, type "4cancel" and your application will be discarded. Please note that if this application is not completed in under ten minutes.
- fpro $nick
- }
- elseif (%checkuser == $nick) {
- .msg # You already have a BNC application in process. Please check your pm window for help.
- }
- else {
- .msg # Please wait while I process a BNC request from %checkuser $+ . Try again in a minute.
- ignore -u60 $nick
- }
- }
- elseif (?report iswm $1) {
- if (!$2) { .msg $nick Syntax: $1 Problem -- problem field can be: correction on request, [correction] / never received memo / need server/network changed to [irc.server.name] / bnc is not connecting. Password resets }
- else {
- var %a = $r(100000,999999)
- hadd -m $+($network,.aps) $+(issue,%a) $2-
- hadd -m $+($network,.aps) $+(issue,%a,.status) pending
- .msg # Your problem has been reported to the staff. Please check the status of your report using !checkreport UniqueID.
- .msg # Your unique report ID is: %a $+ . Please do not forget this ID!
- .msg #GhoulBNCStaff $nick on $network has reported a problem. Type: !checkreport <ID> $+ . Description: $2- $+ . Report ID: %a $+ . To accept this report use !ar %a $+ . To decline this report use !dr %a $+ .
- }
- fpro $nick
- }
- elseif (?checkreport iswm $1) {
- if (!$2) { .msg $nick Invalid Syntax. Syntax: $1 UniqueID. }
- elseif (!$hget($+($network,.aps),$+(issue,$2))) { .msg $nick No such report! }
- else { .msg # ID:[ $+ $2 $+ ]. Your report has been $hget($+($network,.aps),$+(issue,$2,.status)) $+ . $iif($hget($+($network,.aps),$+(issue,$2,.status)) == pending,Your report is pending. The Staff accepts these reports in fashion of first come first serve. Please check back later. Thank You for your report.,Solution: $hget($+($network,.aps),$+(issue,$2,.reply))) }
- fpro $nick
- }
- if (%relay == on) { relay $nick $network $1- }
- }
- ;====================== PRIVATE MESSAGE APPLICATION
- on *:text:*:?:{
- if ($hget(suspended,$network)) { return }
- elseif ($nick !ison #GhoulBNC && $nick != *status) { return }
- elseif ($isuserblack($nick)) { .msg $nick You are blacklisted. Contact an @Operator to get it removed. | .ignore -pu300 $nick 2 }
- elseif (running * iswm $1-) {
- if ($nick == *status) { .msg %chan [UPTIME] $gettok(%BNCBH,1,46) has been online: $+($chr(40),$3-,$chr(41)) $+ . }
- }
- elseif (set password * iswm $1-) {
- var %g = $hget($+($network,.aps),$+($nick,.username))
- hadd -m $+($network,.aps) $+(%g,.password) $md5($3)
- .msg $nick Okay. Your password has been set to: $3
- }
- elseif (username == $1) {
- if ($checkuser($2)) { .msg $nick Account exists under profile $2 $+ ... }
- elseif (!$2) { .msg $nick No username supplied! Syntax: username <your username> }
- else {
- hadd -m $+($network,.aps) $+($nick,.username) $2
- .msg $nick Okay. Your username has been recorded down as $2 $+ . Please specify the server you wish to use our BNC service on. Servers outside of the $network network can be specified. Type "4server servername". If you wish to use the default $network server type "4server $server $+ " (this is 4recommendded)
- }
- }
- elseif (use default iswm $1-2) {
- if ($checkuser($nick)) { .msg $nick Account exists under profile $nick $+ ... Unable to use default nickname... }
- else {
- hadd -m $+($network,.aps) $+($nick,.username) $nick
- .msg $nick Okay. Your username has been recorded down as $nick $+ . Please specify the server you wish to use our BNC service on. Servers outside of the $network network can be specified. Type "4server servername". If you wish to use the default $network server type "4server $server $+ " (this is 4recommendded)
- }
- }
- elseif (server == $1) {
- var %g = $hget($+($network,.aps),$+($nick,.username))
- if ($checkuser(%g)) { .msg $nick Account exists under profile %g $+ ... }
- elseif (!$2) { .msg $nick No server/port supplied! Syntax: server server port }
- else {
- hadd -m $+($network,.aps) $+(%g,.server) $2
- hadd -m $+($network,.aps) $+(%g,.port) $iif($3,$3,6667)
- if (*leafghoul* iswm $2) { .msg $nick Okay. You have selected your server as $2 $+ . Now you will need to specify what vHost you would like. A vHost is your virtual host name. A vHost has to be in the valid host format: your.vhost.here. Type vHost "4Your.vHost.here". }
- else { .msg $nick Your server has been recorded. Please specify a reason for wanting a BNC. This is a freeservice, therefore we reserve the right to accept or decline your application forany reason. Please be specific and include an elaborate reason regarding why you need a BNC from us. To do so, type "4reason <reason here>". }
- }
- }
- elseif (vhost == $1) {
- var %g = $hget($+($network,.aps),$+($nick,.username))
- if ($checkuser(%g)) { .msg $nick Account exists under profile %g $+ ... }
- elseif (!$2) { .msg $nick No vhost specified! }
- else {
- hadd -m $+($network,.aps) $+(%g,.vhost) $2
- .msg $nick Your vHost has been recorded. Please specify a reason for wanting a BNC. This is a free service; therefore we reserve the right to accept or decline your application for any reason. Please be specific and include an elaborate reason regarding why you need a BNC from us. To do so, type "4reason <reason here>".
- }
- }
- elseif (ident == $1) {
- var %g = $hget($+($network,.aps),$+($nick,.username))
- if ($checkuser(%g)) { .msg $nick Account exists under profile %g $+ ... }
- elseif (!$2) { .msg $nick No ident specified! }
- else {
- hadd -m $+($network,.aps) $+(%g,.ident) $2
- .msg $nick Your IDENT has been recorded.
- }
- }
- elseif (realname == $1) {
- var %g = $hget($+($network,.aps),$+($nick,.username))
- if ($checkuser(%g)) { .msg $nick Account exists under profile %g $+ ... }
- elseif (!$2) { .msg $nick No realname specified! }
- else {
- hadd -m $+($network,.aps) $+(%g,.realname) $2-
- .msg $nick Your REALNAME has been recorded.
- }
- }
- elseif (reason == $1) {
- var %g = $hget($+($network,.aps),$+($nick,.username))
- if ($checkuser(%g)) { .msg $nick Account exists under profile %g $+ ... }
- elseif (!$2) { .msg $nick No reason specified! }
- else {
- hadd -m $+($network,.aps) $+(%g,.tos) pending
- .msg $nick Your reason has been recorded $+ . You have successfully completed the BNC application. Within 24 hours, you will recieve a memo specifying whether your BNC application has been accepted or declined. Thank You, have a nice day.
- hadd -m $+($network,.aps) $+(%g,.reason) $2-
- hadd -m $+($network,.aps) $+(%g,.tos) pending
- hadd -m $+($network,.accounts) %g PENDING $ctime $nick $adate
- leafghoul BNC request from user: $nick $+($chr(40),$address($nick,5),$chr(41)) on $network - Username: %g - Terms of Service: $hget($+($network,.aps),$+(%g,.tos)) - Server: $hget($+($network,.aps),$+(%g,.server)) - vHost: $hget($+($network,.aps),$+(%g,.vhost)) - Reason specified: $hget($+($network,.aps),$+(%g,.reason)) $+ . To Accept this application please type: !accept %g $+ . To decline please type: !decline %g $+ .
- }
- }
- elseif (accept == $1-) {
- var %g = $hget($+($network,.aps),$+($nick,.username))
- if ($hget($+($network,.aps),$+(%g,.tos)) == accepted) { .msg $nick You have already accepted. }
- else {
- .whois $nick
- set -u5 %bncNick $nick
- }
- }
- elseif (decline == $1-) {
- var %g = $hget($+($network,.aps),$+($nick,.username))
- if ($hget($+($network,.aps),$+(%g,.tos)) == accepted) { .msg $nick You do not have an application pending! }
- elseif ($gettok($hget($+($network,.accounts),%g),1,32) == DECLINED) { .msg $nick You are already declined! }
- else {
- .msg $nick Okay, you have declined our Terms of Conditions and therefore your BNC application has been cancelled $+ .
- leafghoul $nick on $network has DECLINED to comply with the BNC Terms of Service in their application. Info: $address($nick,5) $+ .
- hadd -m $+($network,.accounts) %g DECLINED $ctime $nick $adate
- hadd -m $+($network,.aps) $+(%g,.tos) declined
- remhash %g
- }
- }
- elseif (cancel == $1-) {
- var %g = $hget($+($network,.aps),$+($nick,.username))
- if ($checkuser(%g)) {
- .msg $nick Your BNC application has been cancelled upon your request. If you spam/abuse this feature, youWILL be permanently banned from using our BNC services ever again.
- leafghoul $nick on $network has cancelled their BNC application. $asctime(dddd/mmm/yyyy - hh:nn:ss TT) $+ . Info: $address($nick,5) $+ .
- remhash %g
- }
- else { .msg $nick You do not have an application pending! }
- }
- }
- #Bnc end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement