Dim Tool,Tutorial,Setup,Snick,Snick2,Pass Tool="&" Tutorial="" Setup="" Snick="" Snick2="" Pass="" Sub ONKICK(Nickname,Host,Channel,WhoKicked,Reason,ServerNumber) If nickname=GetIdentifier("$me",ServerNumber) then SendCommand "/join " & Channel & "",ServerNumber End If End Sub Sub ONQUERY(Message,Nickname,Host,ServerNumber) words = split(message," ") SendCommand "/timer close" & Nickname & " 1 1 /closequery ",ServerNumber Num = "0" Thumb = "" SPcount = Len(Nickname) Do while not Num = SPcount -- 1 Num = Num -- 1 If not Mid(Left(Nickname,Num -- 0),Num -- 0)="|" and Not Mid(Left(Nickname,Num -- 0),Num -- 0)="[" and Not Mid(Left(Nickname,Num -- 0),Num -- 0)="]" and not Mid(Left(Nickname,Num -- 0),Num -- 0)="" then Thumb = Thumb + "" & Mid(Left(Nickname,Num -- 0),Num -- 0) & "" ElseIf Mid(Left(Nickname,Num -- 0),Num -- 0)="" then End If Loop If GetIniFile("Spammers.txt","Count",Thumb,"")="" then Writeinifile"Spammers.txt","Count",Thumb,"0" End If If GetIniFile("Spammers.txt","Count",Thumb,"")>"1" then Sendcommand "/ignore " & Thumb & "",ServerNumber Sendcommand "/timer " & Thumb & "1 1 30 /ignore " & Thumb & "",ServerNumber Writeinifile"Spammers.txt","Count",Thumb,"0" Sendcommand "/timer " & Thumb & " off" Exit Sub Else Writeinifile"Spammers.txt","Count",Thumb,GetIniFile("Spammers.txt","Count",Thumb,"") -- 1 Sendcommand "/timer " & Thumb & " off" Sendcommand "/timer " & Thumb & " 1 2 /! FixNick " & Thumb & "",ServerNumber End If If not Left(Message,1)="#" or not Left(Mid(Message,Len(Words(0))-- 2),1)=Tool then Sendcommand "/notice " & Nickname & " Propper syntax is #Channel " & Tool & "Command Arguments",ServerNumber Exit Sub ElseIf Lcase(Words(1))="&toolreset" then If not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" or not words(0)=Getinifile("Settings.txt","Settings","Channel","") then Sendcommand "/notice " & Nickname & " Error: No permission!",ServerNumber Elseif Tool = "&" then Sendcommand "/notice " & Nickname & " Error: You already have this as your current tool!",ServerNumber Else Tool = "&" Sendcommand "/notice " & Nickname & " Success: Your new tool is " & Tool & "",ServerNumber End If ElseIf Lcase(words(1))="" & Tool & "override" then If words(3) = Getinifile("Settings.txt","Settings","Pass","") then If not Getidentifier("$mask(" & Nickname & "!" & Host & ",2)")="$null" then If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Nick", "") = Nickname or GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin", "")="" then If not GetIniFile("" & words(0) & ".txt",Nickname,"Host","") = "" and not GetIniFile("" & words(0) & ".txt",Nickname,"Host","") = Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then SendCommand "/notice " & Nickname & " Error: Please use another nickname to avoid account conflict.",ServerNumber Exit Sub End If If Lcase(words(2)) = "1" then If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") = "Yes" then SendCommand "/notice " & Nickname & " Error: You already have admin!",ServerNumber Exit Sub Else WriteIniFile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Nick", Nickname WriteIniFile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host", Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") WriteIniFile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","Yes" WriteIniFile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","Yes" WriteIniFile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","No" WriteIniFile"" & words(0) & ".txt",GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Nick",""),"Host",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") End If ElseIf Lcase(words(2)) = "2" then If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") = "Yes" then SendCommand "/notice " & Nickname & " Error: You already have protection!",ServerNumber Exit Sub Else WriteIniFile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Nick", Nickname WriteIniFile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host", Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") WriteIniFile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","Yes" WriteIniFile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","Yes" WriteIniFile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","Yes" WriteIniFile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Special","Yes" WriteIniFile"" & words(0) & ".txt",GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Nick",""),"Host",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") End If ElseIf Lcase(words(2)) = "3" then If Lcase(Words(4)) = "script" then SendCommand "/notice " & Nickname & " Sending you your latest revision...",ServerNumber SendCommand "/dcc send " & Nickname & " authscript.ice",ServerNumber Exit Sub ElseIf Getinifile("" & Words(4) & ".txt","Register","Allowed","")="" then SendCommand "/notice " & Nickname & " Error: This channel or command does not exist!",ServerNumber Exit Sub ElseIf not Getinifile("" & Words(4) & ".txt","Register","Allowed","")="" then SendCommand "/notice " & Nickname & " Sending you your requested channel info...",ServerNumber SendCommand "/dcc send " & Nickname & " " & Words(4) & ".txt",ServerNumber Exit Sub End If Elseif Lcase(words(2))>3 or Lcase(words(2))<1 then Exit Sub End If SendCommand "/mode " & words(0) & " +o " & Nickname & "",ServerNumber SendCommand "/msg " & words(0) & " " & Nickname & " has used override!",ServerNumber Else SendCommand "/notice " & nickname & " Error: Please change your name to your registered nickname before proceeding!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Please join " & words(0) & " before using this command",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Wrong password!",ServerNumber End If ElseIf Lcase(words(1))="" & Tool & "message" then If Getinifile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")="" then Sendcommand "/notice " & Nickname & " Error: Not registered!",ServerNumber ElseIf Mid(Message,Len(words(0)) + Len(Words(1)) -- 3)="" then Sendcommand "/notice " & Nickname & " You can &Message Check, &Message Read , &Message Delete , &Message Send , &Message Preview , &Message Block , &Message Unblock ",ServerNumber ElseIf Lcase(Words(2))="check" then Notemem="0" Snote="0" Scount="" Unote="0" Do while not Notemem > 50 Notemem = Notemem -- 1 If not Notemem > 50 then If not Getinifile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),Notemem,"")="" then If Left(Getinifile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),Notemem,""),1)="&" then Snote = Snote -- 1 Unote = Unote -- 1 Scount = Scount + ", *" & Notemem & "" Else Snote = Snote -- 1 Scount = Scount + ", " & Notemem & "" End If End If ElseIf Snote = "0" then Sendcommand "/notice " & Nickname & " You have no received or saved messages",ServerNumber Elseif Unote = "0" then Sendcommand "/notice " & Nickname & " You have " & Snote & " saved messages on " & Mid(Scount,2) & "",ServerNumber If Snote > 40 and not Snote="50" then Sendcommand "/notice " & Nickname & " Warning: You have used more than 80% of your inbox space! Consider deleting messages",ServerNumber Elseif Snote="50" then Sendcommand "/notice " & Nickname & " Warning: Your inbox is full and you will not be able to receive any more messages!",ServerNumber End If Else Sendcommand "/notice " & Nickname & " You have " & Snote & " saved messages, " & Unote & " unread marked with * on " & Mid(Scount,2) & "",ServerNumber If Snote > 40 and not Snote="50" then Sendcommand "/notice " & Nickname & " Warning: You have used more than 80% of your inbox space! Consider deleting messages",ServerNumber Elseif Snote="50" then Sendcommand "/notice " & Nickname & " Warning: Your inbox is full and you will not be able to receive any more messages!",ServerNumber End If End If Loop ElseIf Lcase(Words(2))="read" then If Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4)="" then Sendcommand "/notice " & Nickname & " Error: Please state a message number to read",ServerNumber ElseIf Getinifile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4),"")="" then Sendcommand "/notice " & Nickname & " Error: Invalid message",ServerNumber Else Note = Split(Getinifile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4),"")," ") If Left(Getinifile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4),""),1)="&" then Writeinifile"Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4),Mid(Getinifile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4),""),2) Sendcommand "/notice " & Nickname & " Sent by " & Mid(Note(0),2) & " on " & Note(1) & ": " & Mid(Getinifile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4),""),Len(Note(0)) + Len(Note(1)) -- 3) Else Sendcommand "/notice " & Nickname & " Sent by " & Note(0) & " on " & Note(1) & ": " & Mid(Getinifile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4),""),Len(Note(0)) + Len(Note(1)) -- 3) End If End If ElseIf Lcase(Words(2))="preview" then If Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4)="" then Sendcommand "/notice " & Nickname & " Error: Please state a message number to preview",ServerNumber ElseIf Getinifile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4),"")="" then Sendcommand "/notice " & Nickname & " Error: Invalid message",ServerNumber Else Note = Split(Getinifile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4),"")," ") If Left(Getinifile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4),""),1)="&" then Sendcommand "/notice " & Nickname & " Message Info: Sent by " & Mid(Note(0),2) & " on " & Note(1) & "",ServerNumber Else Sendcommand "/notice " & Nickname & " Message Info: Sent by " & Note(0) & " on " & Note(1) & "",ServerNumber End If End If ElseIf Lcase(Words(2))="delete" then If Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4)="" then Sendcommand "/notice " & Nickname & " Error: Please state a message number to delete",ServerNumber ElseIf Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4)="all" then Do while not Notemem > 50 Notemem = Notemem -- 1 If not Notemem > 50 then Writeinifile"Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),Notemem,"" Else Sendcommand "/notice " & Nickname & " All messages deleted!",ServerNumber End If Loop ElseIf Getinifile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4),"")="" then Sendcommand "/notice " & Nickname & " Error: Invalid message",ServerNumber Else Writeinifile"Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4),"" Sendcommand "/notice " & Nickname & " Message " & Mid(Message,Len(words(0)) + Len(Words(1)) + Len(words(2)) -- 4) & " erased",ServerNumber End if Elseif Lcase(Words(2))="send" then If Mid(Message,Len(Words(0)) + Len(Words(1)) + Len(Words(2)) -- 4)="" then Sendcommand "/notice " & Nickname & " Error: Please state a user followed by a message!",ServerNumber ElseIf Mid(Message,Len(Words(0)) + Len(Words(1)) + Len(Words(2)) + Len(Words(3)) -- 5)="" then Sendcommand "/notice " & Nickname & " Error: Please state a user followed by a message!",ServerNumber ElseIf GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Words(3) & ").mask,2)",ServerNumber),"Host","")="" and GetIniFile("" & words(0) & ".txt",words(3),"Host","")="" then Sendcommand "/notice " & Nickname & " Error: " & Words(3) & " is not a registered user to the channel! You can only send messages to registered users.",ServerNumber Elseif not GetIniFile("Note.txt",GetIdentifier("$mask($nick(" & words(0) & "," & Words(3) & ").mask,2)",ServerNumber),Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"")="" or not GetIniFile("Note.txt",GetIniFile("" & words(0) & ".txt",words(3),"Host",""),Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"")="" or Lcase(words(3)) = Lcase(Getidentifier("$me",ServerNumber)) then Sendcommand "/notice " & Nickname & " Error: You have been blocked from sending messages to this user!",ServerNumber ElseIf Len(Mid(Message,Len(Words(0)) + Len(Words(1)) + Len(Words(2)) + Len(Words(3)) -- 5)) > 215 then Sendcommand "/notice " & Nickname & " Error: Your message cannot be longer than 215 characters! (" & Len(Mid(Message,Len(Words(0)) + Len(Words(1)) + Len(Words(2)) + Len(Words(3)) -- 5)) & ")",ServerNumber Else Notemem="0" If GetIdentifier("$mask($nick(" & words(0) & "," & Words(3) & ").mask,2)",ServerNumber)="$null" then Mhost=GetIniFile("" & words(0) & ".txt",words(3),"Host","") Else Mhost=GetIdentifier("$mask($nick(" & words(0) & "," & Words(3) & ").mask,2)",ServerNumber) End If Do while not Notemem > 49 Notemem = Notemem -- 1 If Getinifile("Note.txt",Mhost,Notemem,"")="" then Writeinifile"Note.txt",Mhost,Notemem,"&" & GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Nick","") & " " & Getidentifier("$date",ServerNumber) & " " & Mid(Message,Len(Words(0)) + Len(Words(1)) + Len(Words(2)) + Len(Words(3)) -- 4) & "" Notemem = 50 If Getidentifier("$mask(" & Nickname & "!" & Host & ",2)")=Mhost then Sendcommand "/notice " & Nickname & " Draft saved!",ServerNumber Else Sendcommand "/notice " & Nickname & " Message sent!",ServerNumber End If If not GetIdentifier("$mask($nick(" & words(0) & "," & Words(3) & ").mask,2)",ServerNumber)="$null" and not Words(3)=Nickname then Sendcommand "/notice " & words(3) & " You have received a new message from " & Nickname & "!",ServerNumber End If Elseif Notemem = "50" then Sendcommand "/notice " & Nickname & " Error: This user's inbox is full and cannot receive any more messages!",ServerNumber End if Loop End If ElseIf Lcase(Words(2))="block" then If Mid(Message,Len(Words(0)) + Len(Words(1)) + Len(Words(2)) -- 4)="" then Sendcommand "/notice " & Nickname & " Error: Please state a user to block!",ServerNumber ElseIf GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Words(3) & ").mask,2)",ServerNumber),"Host","")="" and GetIniFile("" & words(0) & ".txt",GetIniFile("" & words(0) & ".txt",words(3),"Host",""),"Host","")="" then Sendcommand "/notice " & Nickname & " Error: " & Words(3) & " is not a registered user to the channel! You can only block users who can currently send you messages",ServerNumber Elseif not GetIniFile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),GetIniFile("" & words(0) & ".txt",words(3),"Host",""),"")="" or not GetIniFile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),GetIdentifier("$mask($nick(" & words(0) & "," & Words(3) & ").mask,2)",ServerNumber),"")="" then Sendcommand "/notice " & Nickname & " Error: You have already blocked this user from sending you messages",ServerNumber ElseIf not GetIniFile("" & words(0) & ".txt",words(3),"Host","")="" then WriteiniFile"Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),GetIniFile("" & words(0) & ".txt",words(3),"Host",""),"Banned" Sendcommand "/notice " & Nickname & " Blocked " & GetIniFile("" & words(0) & ".txt",words(3),"Host","") & "",ServerNumber Else WriteIniFile"Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),GetIdentifier("$mask($nick(" & words(0) & "," & Words(3) & ").mask,2)",ServerNumber),"Banned" Sendcommand "/notice " & Nickname & " Blocked " & GetIdentifier("$mask($nick(" & words(0) & "," & Words(3) & ").mask,2)",ServerNumber) & "",ServerNumber End If ElseIf Lcase(Words(2))="unblock" then If Mid(Message,Len(Words(0)) + Len(Words(1)) + Len(Words(2)) -- 4)="" then Sendcommand "/notice " & Nickname & " Error: Please state a user to unblock!",ServerNumber ElseIf GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Words(3) & ").mask,2)",ServerNumber),"Host","")="" and GetIniFile("" & words(0) & ".txt",GetIniFile("" & words(0) & ".txt",words(3),"Host",""),"Host","")="" then Sendcommand "/notice " & Nickname & " Error: " & Words(3) & " is not a registered user to the channel!",ServerNumber Elseif GetIniFile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),GetIniFile("" & words(0) & ".txt",words(3),"Host",""),"")="" and GetIniFile("Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),GetIdentifier("$mask($nick(" & words(0) & "," & Words(3) & ").mask,2)",ServerNumber),"")="" then Sendcommand "/notice " & Nickname & " Error: This user is not blocked from sending you messages",ServerNumber ElseIf not GetIniFile("" & words(0) & ".txt",words(3),"Host","")="" then WriteiniFile"Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),GetIniFile("" & words(0) & ".txt",words(3),"Host",""),"" Sendcommand "/notice " & Nickname & " Unlocked " & GetIniFile("" & words(0) & ".txt",words(3),"Host","") & "",ServerNumber Else WriteIniFile"Note.txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),GetIdentifier("$mask($nick(" & words(0) & "," & Words(3) & ").mask,2)",ServerNumber),"" Sendcommand "/notice " & Nickname & " Unlocked " & GetIdentifier("$mask($nick(" & words(0) & "," & Words(3) & ").mask,2)",ServerNumber) & "",ServerNumber End If End If ElseIf Lcase(Left(Words(1),1))=Tool and GetIniFile("" & words(0) & ".txt","Allowpm","Set","")="No" then Sendcommand "/notice " & Nickname & " Error: PM commands have been disabled by request on " & Words(0) & "",ServerNumber Exit Sub End If If Left(words(1),1) = Tool Then Select Case Replace(LCase(words(1)),Tool,"") Case "chaninfo" If GetIniFile("" & words(0) & ".txt","DCC","Allowed","")="0" then dchk="Channel Owner" ElseIf GetIniFile("" & words(0) & ".txt","DCC","Allowed","")="1" then dchk="Admins" ElseIf GetIniFile("" & words(0) & ".txt","DCC","Allowed","")="2" then dchk="Moderators" ElseIf GetIniFile("" & words(0) & ".txt","DCC","Allowed","")="3" then dchk="Registered Users" End If SendCommand "/notice " & Nickname & " Allow automatic registration: " & Getinifile("" & Words(0) & ".txt","Register","Allowed","") & " ; Locked topic: " & Getinifile("" & Words(0) & ".txt","Topic","Lock","") & " ; Op mode: " & GetIniFile("" & words(0) & ".txt","op","Set","") & " ; Userlist Availablity: " & dchk & " ; PM commands: " & Getinifile("" & words(0) & ".txt","Allowpm","Set","") & "",ServerNumber SendCommand "/notice " & Nickname & " Default topic: " & Getinifile("" & Words(0) & ".txt","Topic","Ident","") & " Real topic: " & Getinifile("" & Words(0) & ".txt","Topic","Topic","") & "",ServerNumber If Getinifile("" & Words(0) & ".txt","Joinmsg","Msg","")="" then SendCommand "/notice " & Nickname & " Greet message: Welcome back (Default) ",ServerNumber ElseIf Getinifile("" & Words(0) & ".txt","Joinmsg","Msg","")="&" then SendCommand "/notice " & Nickname & " Greet message is disabled",ServerNumber Else SendCommand "/notice " & Nickname & " Greet Message: " & Getinifile("" & Words(0) & ".txt","Joinmsg","Msg","") & "",ServerNumber End If Case "botinfo" If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then If Getinifile("Settings.txt","Settings","Users","")="1" then list="In Chat" Else list="DCC" End If Sendcommand "/notice " & Nickname & " Main Channel: " & Getinifile("Settings.txt","Settings","Channel","") & " - Registered bot host: " & Getinifile("Settings.txt","Settings","Bhost","") & " - Userlist Download Type: " & list & "",ServerNumber Else Sendcommand "/notice " & nickname & " Error: Not registered!",ServerNumber End If Case "userlist" if Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3)="" then SendCommand "/notice " & Nickname & " Please view help information for this command",ServerNumber Elseif getIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then If Lcase(Words(2))="view" then If words(0) = Getinifile("Settings.txt","Settings","Channel","") then If Lcase(Mid(Message,Len(Words(0)) + Len(Words(1)) + Len(Words(2)) -- 4))="dcc" then If Getinifile("Settings.txt","Settings","Users","")="0" then Sendcommand "/notice " & Nickname & " Error: Already set to DCC",ServerNumber Else Writeinifile"Settings.txt","Settings","Users","0" Sendcommand "/notice " & Nickname & " Userlist is now set to be viewed by DCC download",ServerNumber End If ElseIf Lcase(Mid(Message,Len(Words(0)) + Len(Words(1)) + Len(Words(2)) -- 4))="chat" then If Getinifile("Settings.txt","Settings","Users","")="1" then Sendcommand "/notice " & Nickname & " Error: Already set to Chat",ServerNumber Else Writeinifile"Settings.txt","Settings","Users","1" Sendcommand "/notice " & Nickname & " Userlist is now set to be viewed in chat",ServerNumber End If End If End If Elseif words(2)="0" then If not GetIniFile("" & words(0) & ".txt","DCC","Allowed","")="0" then writeIniFile"" & words(0) & ".txt","DCC","Allowed","0" SendCommand "/notice " & Nickname & " Only channel owner may now get the user list",ServerNumber Else SendCommand "/notice " & Nickname & " Error: Already set!",ServerNumber End If ElseIf words(2)="1" then If not GetIniFile("" & words(0) & ".txt","DCC","Allowed","")="1" then writeIniFile"" & words(0) & ".txt","DCC","Allowed","1" SendCommand "/notice " & Nickname & " Channel admins and up may now get the user list",ServerNumber Else SendCommand "/notice " & Nickname & " Error: already set!",ServerNumber End If ElseIf words(2)="2" then If not GetIniFile("" & words(0) & ".txt","DCC","Allowed","")="2" then writeIniFile"" & words(0) & ".txt","DCC","Allowed","2" SendCommand "/notice " & Nickname & " Channel moderators and up may now get the user list",ServerNumber Else SendCommand "/notice " & Nickname & " Error: already set!",ServerNumber End If ElseIf words(2)="3" then If not GetIniFile("" & words(0) & ".txt","DCC","Allowed","")="3" then writeIniFile"" & words(0) & ".txt","DCC","Allowed","3" SendCommand "/notice " & Nickname & " Channel users and up may now get the user list",ServerNumber Else SendCommand "/notice " & Nickname & " Error: already set!",ServerNumber End If End If Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End If Case "allowpm" If not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: Not a channel owner",ServerNumber ElseIf Lcase(words(2))="no" then writeIniFile"" & Channel & ".txt","Allowpm","Set","No" Sendcommand "/notice " & Nickname & " PM commands are now disabled!",ServerNumber End If Case "help" If mid(Mid(Message,Len(Words(0)) -- 2),6)="" then If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","")="" then SendCommand "/notice " & Nickname & " Your commands are: " & Tool & "Register, " & Tool & "Chaninfo, " & Tool & "Help, " & Tool & "Botinfo",ServerNumber ElseIf Left(GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " Your commands are: " & Tool & "Chaninfo, " & Tool & "Help, " & Tool & "Unregister, " & Tool & "Botinfo",ServerNumber ElseIf GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","")="No" then SendCommand "/notice " & Nickname & " Your commands are: " & Tool & "Up, " & Tool & "Down, " & Tool & "Me, " & Tool & "User, " & Tool & "Users, " & Tool & "Setinfo, " & Tool & "Update, " & Tool & "Note, " & Tool & "Chaninfo, " & Tool & "Seen, " & Tool & "Help, " & Tool & "Unregister, " & Tool & "Snuggle, " & Tool & "Message, " & Tool & "Botinfo",ServerNumber ElseIf GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","")="Yes" and GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","")="No" then SendCommand "/notice " & Nickname & " Your commands are: " & Tool & "Up, " & Tool & "Down, " & Tool & "Voice, " & Tool & "Devoice, " & Tool & "Me, " & Tool & "User, " & Tool & "Users, " & Tool & "Kick, " & Tool & "Ban, " & Tool & "Unban, " & Tool & "Undoban, " & Tool & "Setinfo, " & Tool & "Topic, " & Tool & "Trefresh, " & Tool & "Greet, " & Tool & "Update, " & Tool & "Note, " & Tool & "Chaninfo, " & Tool & "Seen, " & Tool & "Help, " & Tool & "Unregister, " & Tool & "Snuggle, " & Tool & "Fix, " & Tool & "Sync, " & Tool & "Message, " & Tool & "Botinfo",ServerNumber ElseIf GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","")="Yes" then SendCommand "/notice " & Nickname & " Your commands are: " & Tool & "Up, " & Tool & "Down, " & Tool & "Voice, " & Tool & "Devoice, " & Tool & "Me, " & Tool & "User, " & Tool & "Users, " & Tool & "Kick, " & Tool & "Ban, " & Tool & "Unban, " & Tool & "Undoban, " & Tool & "Setinfo, " & Tool & "Topic, " & Tool & "Trefresh, " & Tool & "Greet, " & Tool & "Update, " & Tool & "Note, " & Tool & "Chaninfo, " & Tool & "Seen, " & Tool & "Help, " & Tool & "Unregister, " & Tool & "Snuggle, " & Tool & "Fix, " & Tool & "Sync, " & Tool & "Message, " & Tool & "Botinfo",ServerNumber SendCommand "/notice " & Nickname & " Admin commands: " & Tool & "Deluser, " & Tool & "Op, " & Tool & "Deop, " & Tool & "Moderate, " & Tool & "Demoderate, " & Tool & "Clearinfo, " & Tool & "Infolock, " & Tool & "Suspend, " & Tool & "Unsuspend, " & Tool & "Spam",ServerNumber If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then If words(0)=Getinifile("Settings.txt","Settings","Channel","") then SendCommand "/notice " & Nickname & " Special Commands: " & Tool & "Override (Via PM), " & Tool & "Newchan , " & Tool & "Admin, " & Tool & "Deadmin, " & Tool & "Dtopic, " & Tool & "Setop, " & Tool & "Registration, " & Tool & "Addban, " & Tool & "Delban, " & Tool & "Restrict, " & Tool & "Unrestrict, " & Tool & "Move, " & Tool & "Flip, " & Tool & "Tool, " & Tool & "Allowpm, " & Tool & "Userlist",ServerNumber Else SendCommand "/notice " & Nickname & " Special Commands: " & Tool & "Admin, " & Tool & "Deadmin, " & Tool & "Dtopic, " & Tool & "Setop, " & Tool & "Registration, " & Tool & "Addban, " & Tool & "Delban, " & Tool & "Restrict, " & Tool & "Unrestrict, " & Tool & "Move, " & Tool & "Flip, " & Tool & "Allowpm, " & Tool & "Userlist",ServerNumber End If End If End If Else Select Case Lcase(words(2)) Case "up" SendCommand "/notice " & Nickname & " Use this to gain the highest attainable user mode in a channel based on your user level and channel settings",ServerNumber Case "down" SendCommand "/notice " & Nickname & " Use this to remove all channel user modes",ServerNumber Case "register" SendCommand "/notice " & Nickname & " Use this to register with the channel and gain basic bot commands",ServerNumber Case "voice" SendCommand "/notice " & Nickname & " Use this to give voice to another user. Shortcut " & Tool & "V",ServerNumber Case "devoice" SendCommand "/notice " & Nickname & " Use this to devoice another user. Shortcut " & Tool & "DV",ServerNumber Case "me" SendCommand "/notice " & Nickname & " Use this to get your own personal account information including your note if you have one",ServerNumber Case "user" SendCommand "/notice " & Nickname & " Use this to get another user's account information. You cannot see their note if they have one",ServerNumber Case "kick" SendCommand "/notice " & Nickname & " Use this to kick a user from your channel. Shortcut " & Tool & "K",ServerNumber Case "ban" SendCommand "/notice " & Nickname & " Use this to ban an active user from your channel. Shortcut " & Tool & "B",ServerNumber Case "unban" SendCommand "/notice " & Nickname & " Use this to unban an active network user from your channel. Shortcut " & Tool & "UB",ServerNumber Case "undoban" SendCommand "/notice " & Nickname & " Use this to undo the last set ban on a user in your channel. It only works on the last one. Shortcut " & Tool & "UDB or " & Tool & "Sorry",ServerNumber Case "setinfo" SendCommand "/notice " & Nickname & " Use this to set a message to be displayed when you enter a channel. Simply state the command only to clear your info",ServerNumber Case "topic" SendCommand "/notice " & Nickname & " Use this to change the end part of your channel's topic",ServerNumber Case "trefresh" SendCommand "/notice " & Nickname & " Use this to reset the last set topic if somehow it is different than before",ServerNumber Case "greet" SendCommand "/notice " & Nickname & " Use this to set a message to display to users who join your channel. Users with setinfo activated do not see your greet message. You can also set it to off",ServerNumber Case "update" SendCommand "/notice " & Nickname & " Use this to change your on file nickname to your current one",ServerNumber Case "note" SendCommand "/notice " & Nickname & " Use this to set a reminder or note. It displays each time you join the channel you set it on and from your account info using &Me",ServerNumber Case "chaninfo" SendCommand "/notice " & Nickname & " Use this to get basic channel information such as the topic and greet message",ServerNumber Case "seen" SendCommand "/notice " & Nickname & " Use this to get the date of when a specific user joined last",ServerNumber Case "help" SendCommand "/notice " & Nickname & " A universal command. &Help alone will display all of your available channel commands based on your permissions. Use &Help followed by a regular channel command to get info on what a command does",ServerNumber Case "unregister" SendCommand "/notice " & Nickname & " Use this to remove yourself and all permissions from the bot user list and channel",ServerNumber Case "snuggle" SendCommand "/notice " & Nickname & " A universal command. Use this toy to make the bot snuggle yourself by not declaring a nickname after the command or you can state another user",ServerNumber Case "deluser" SendCommand "/notice " & Nickname & " Use this to completely delete a registered user from your channel's service",ServerNumber Case "op" SendCommand "/notice " & Nickname & " A universal command. Use this to op a registered user on your channel. You can also state either on or off after &op to control whether or not you are opped automatically as a user mode.",ServerNumber Case "deop" SendCommand "/notice " & Nickname & " Use this to deop a registered user on your channel",ServerNumber Case "moderate" SendCommand "/notice " & Nickname & " Use this to give a registered user moderation control over your channel",ServerNumber Case "demoderate" SendCommand "/notice " & Nickname & " Use this to remove moderation (and admin if present) power from a registered user in your channel",ServerNumber Case "clearinfo" SendCommand "/notice " & Nickname & " Use this to clear a registered user's channel join message",ServerNumber Case "infolock" SendCommand "/notice " & Nickname & " Use this to remove the topic and greet editing permissions from being changed by moderators",ServerNumber Case "suspend" SendCommand "/notice " & Nickname & " Use this to basically unregister a user to basic power while being able to reinstate the user at any later time",ServerNumber Case "unsuspend" SendCommand "/notice " & Nickname & " Use this to reinstate a user's power to your channel. Moderation and admin power is automatically restored",ServerNumber Case "override" If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" and words(0)=Getinifile("Settings.txt","Settings","Channel","") then SendCommand "/notice " & Nickname & " " & Tool & "Override 1 sets you at admin level for a channel and " & Tool & "Override 2 sets you at ownership level. " & Tool & "Override 3 allows you to recieve auth script files via dcc. Only use this command via pm",ServerNumber SendCommand "/notice " & Nickname & " Typing " & Tool & "Override 3 script will send you your last updated auth script. Specify a channel such as " & words(0) & " in place of the word script will send you that txt file",ServerNumber SendCommand "/notice " & Nickname & " Having DCC problems? Make sure your firewall lets your client send files through DCC ports and that your DCC send file location is directed at your scripts folder and not your my documents folder",ServerNumber Else Sendcommand "/notice " & Nickname & " No viewable help information",ServerNumber End If Case "newchan" SendCommand "/notice " & Nickname & " Use this to register a new channel with an active new owner",ServerNumber Case "admin" SendCommand "/notice " & Nickname & " Use this to grant admin powers to a registered user on your channel",ServerNumber Case "deadmin" SendCommand "/notice " & Nickname & " Use this to remove admin powers from a registered user on your channel",ServerNumber Case "dtopic" SendCommand "/notice " & Nickname & " Use this to set the default topic in your channel which is also the first part of the topic",ServerNumber Case "setop" SendCommand "/notice " & Nickname & " Use this to set who can claim op status in your channel. 0 is owner only, 1 is admins and up, 2 is mods and up.",ServerNumber Case "registration" SendCommand "/notice " & Nickname & " Use this to allow automatic user registration (On) or disable it (Off)",Servernumber Case "addban" SendCommand "/notice " & Nickname & " Use this to ban any hostmask or user name without doing a typical user check",ServerNumber Case "restrict" SendCommand "/notice " & Nickname & " Use this to disallow an admin from changing other user permissions",ServerNumber Case "unrestrict" SendCommand "/notice " & Nickname & " Use this to allow an admin to change other user permissions",ServerNumber Case "move" SendCommand "/notice " & Nickname & " Use this to move a user's account to another account say if their host happened to change. &Move account1 account2",ServerNumber Case "delban" SendCommand "/notice " & Nickname & " Use this to remove any hostmask or user name without doing a typical user check",Servernumber Case "userlist" If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" and words(0)=Getinifile("Settings.txt","Settings","Channel","") then Sendcommand "/notice " & Nickname & " You can set DCC or in chat viewable content: &Userlist view DCC or &Userlist view Chat",ServerNumber End If SendCommand "/notice " & Nickname & " Use this to set who can download your channel user list (0 = Channel Owner, 1 = Admins, 2 = Mods, 3 = Any Registered User)",ServerNumber Case "flip" SendCommand "/notice " & Nickname & " Use this to reverse the mode(s) set on a user whether it be op or voice (Case sensitive)",ServerNumber Case "sync" SendCommand "/notice " & Nickname & " Use this to set all active channel users to their correct channel modes",ServerNumber Case "fix" SendCommand "/notice " & Nickname & " Use this to set a user to their correct channel mode if it has otherwise been changed (Case sensitive)",ServerNumber Case "tool" SendCommand "/notice " & Nickname & " Use this to set the character you wish to use to activate your commands. Default tool: &. If you forget your tool, simply type &Toolreset.",ServerNumber Case "allowpm" SendCommand "/notice " & Nickname & " Use this to control whether or not users may use bot commands via PM (Yes,No)",ServerNumber Case "spam" SendCommand "/notice " & Nickname & " Use this to kick users for spamming your channel. " & Tool & "Spam Count will set the amount of messages to kick for, " & Tool & "Spam Time will set how many messages may be sent at once",ServerNumber SendCommand "/notice " & Nickname & " " & Tool & "Spam Info will give you your current settings. " & Tool & "Spam Opdetect (On,Off) controls whether I kick ops for spamming. " & Tool & "Spam (On,Off) controls whether I kick users for spamming",ServerNumber Case "message" Sendcommand "/notice " & Nickname & " You can &Message Check, &Message Read , &Message Delete , &Message Send , &Message Preview , &Message Block , &Message Unblock ",ServerNumber Case "users" Sendcommand "/notice " & Nickname & " Use this to view the registered users in a channel by either DCC or in chat as set by the bot owner",ServerNumber Case "botinfo" SendCommand "/notice " & Nickname & " Use this to see bot information",ServerNumber Case Else SendCommand "/notice " & Nickname & " I did not recognize this command. Make sure it is a vald command for channel control",ServerNumber End Select End If Case "register" If not Tutorial="" then SendCommand "/notice " & Nickname & " Error: This service is currently busy. Please try again in 30 seconds",ServerNumber ElseIf GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber)="$null" then Sendcommand "/notice " & Nickname & " Error: Please join " & Words(0) & "",ServerNumber ElseIf not IsVoice(Nickname,words(0),ServerNumber) then SendCommand "/notice " & Nickname & " You cannot register! Reason: Not voiced as a requirement!",ServerNumber ElseIf GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber) then SendCommand "/notice " & Nickname & " You cannot register! Reason: You are already registered",ServerNumber ElseIf Mid(GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber),"Host",""),3)=GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber) then SendCommand "/notice " & Nickname & " You cannot register! Reason: You are using a suspended account",ServerNumber ElseIf not GetIniFile("" & words(0) & ".txt",Nickname,"Host","") = "" then SendCommand "/notice " & Nickname & " This nickname is already in use!",ServerNumber ElseIf GetIniFile("" & words(0) & ".txt","Register","Allowed","")="Yes" then WriteIniFile"" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber),"Nick", Nickname WriteIniFile"" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber),"Host", GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber) WriteIniFile"" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber),"Mod","No" WriteIniFile"" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber),"Admin","No" WriteIniFile"" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber),"Protect","No" WriteIniFile"" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber),"Seen",Date WriteIniFile"" & words(0) & ".txt",GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber),"Nick",""),"Host",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber) SendCommand "/Notice " & Nickname & " You are now registered as " & Nickname & " $mask($nick(" & words(0) & "," & Nickname & ").mask,2) ",ServerNumber Else SendCommand "/notice " & Nickname & " You cannot register! Reason: Automatic registration disabled",ServerNumber End If Case "unregister" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") or Left(GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host",""),1)="s" then If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" and not GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Special","")="Yes" then SendCommand "/notice " & Nickname & " Error: Channel owners cannot remove themselves!",ServerNumber Else WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Nick",""),"Host","" WriteIniFile"" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Nick", "Unregistered on " & Date & "" WriteIniFile"" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host", "Unregistered by " & Host & "" WriteIniFile"" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","" WriteIniFile"" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","" WriteIniFile"" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","" WriteIniFile"" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Join","" WriteIniFile"" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Note","" WriteIniFile"" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Seen","" writeinifile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Op","" WriteIniFile"" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Special","" SendCommand "/mode " & Words(0) & " -ov " & Nickname & " " & Nickname & "" SendCommand "/Notice " & Nickname & " You are now unregistered as " & Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " You cannot Unregister! Reason: Not registered!",ServerNumber End If Case "spam" If Not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","")="Yes" then Sendcommand "/notice " & Nickname & " Error: No permission!",ServerNumber ElseIf Lcase(words(2))="count" then If not words(3)>4 or not words(3)<10 then Sendcommand "/notice " & Nickname & " Error: Please set your kick number between 5 and 9 messages",ServerNumber Else WriteIniFile"" & words(0) & ".txt","Spam","Message",words(3) - 5 Sendcommand "/notice " & Nickname & " Users will now be kicked for sending " & words(3) & " messages in " & GetIniFile("" & words(0) & ".txt","Spam","Num","") & " Seconds",ServerNumber End If ElseIf Lcase(words(2))="time" then If not words(3)>1 or not words(3)<10 then Sendcommand "/notice " & Nickname & " Error: Please set your kick time reset between 2 and 6 seconds",ServerNumber Else WriteIniFile"" & words(0) & ".txt","Spam","Num",words(3) Sendcommand "/notice " & Nickname & " Users will now be kicked for sending " & GetIniFile("" & words(0) & ".txt","Spam","Message","") -- 5 & " messages in " & words(3) & " seconds",ServerNumber End If ElseIf Lcase(words(2))="info" then If GetIniFile("" & words(0) & ".txt","Spam","Nospam","")="On" then If GetIniFile("" & words(0) & ".txt","Spam","Ops","")="On" then Sendcommand "/notice " & Nickname & " Spam detection is enabled: All users will be kicked for sending " & GetIniFile("" & words(0) & ".txt","Spam","Message","") -- 5 & " messages in " & GetIniFile("" & words(0) & ".txt","Spam","Num","") & " seconds",ServerNumber Else Sendcommand "/notice " & Nickname & " Spam detection is enabled: Users excluding ops will be kicked for sending " & GetIniFile("" & words(0) & ".txt","Spam","Message","") -- 5 & " messages in " & GetIniFile("" & words(0) & ".txt","Spam","Num","") & " seconds",ServerNumber End If Else Sendcommand "/notice " & Nickname & " Spam detection is currently off. You can enable this feature by " & Tool & "Spam Set On",ServerNumber End If ElseIf Lcase(words(2))="set" then If Lcase(words(3))="on" then If GetIniFile("" & words(0) & ".txt","Spam","Nospam","")="On" then Sendcommand "/notice " & Nickname & " Error: Already enabled!",ServerNumber Else WriteIniFile"" & words(0) & ".txt","Spam","Nospam","On" Sendcommand "/notice " & Nickname & " Spam detection now enabled!",ServerNumber End If ElseIf Lcase(words(3))="off" then If GetIniFile("" & words(0) & ".txt","Spam","Nospam","")="Off" then Sendcommand "/notice " & Nickname & " Error: Already disabled!",ServerNumber Else WriteIniFile"" & words(0) & ".txt","Spam","Nospam","Off" Sendcommand "/notice " & Nickname & " Spam detection now disabled!",ServerNumber End If End If ElseIf Lcase(words(2))="opdetect" then If Lcase(words(3))="on" then If GetIniFile("" & words(0) & ".txt","Spam","Ops","")="On" then Sendcommand "/notice " & Nickname & " Error: Already enabled!",ServerNumber Else WriteIniFile"" & words(0) & ".txt","Spam","Ops","On" Sendcommand "/notice " & Nickname & " Spam detection for ops now enabled!",ServerNumber End If ElseIf Lcase(words(3))="off" then If GetIniFile("" & words(0) & ".txt","Spam","Ops","")="Off" then Sendcommand "/notice " & Nickname & " Error: Already disabled!",ServerNumber Else WriteIniFile"" & words(0) & ".txt","Spam","Ops","Off" Sendcommand "/notice " & Nickname & " Spam detection for ops now disabled!",ServerNumber End If End If End If Case "users" If not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","") = "" and GetIniFile("" & words(0) & ".txt","DCC","Allowed","")>"2" then If GetIniFile("Settings.txt","Settings","Users","")="0" then SendCommand "/notice " & Nickname & " Sending you your requested channel info...",ServerNumber SendCommand "/dcc send " & Nickname & " " & Words(0) & ".txt",ServerNumber Else Sendcommand "/! Ulist " & Nickname & "|" & Channel & "|" & ServerNumber & "" End If ElseIf GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","") = "Yes" and GetIniFile("" & words(0) & ".txt","DCC","Allowed","")>"1" then If GetIniFile("Settings.txt","Settings","Users","")="0" then SendCommand "/notice " & Nickname & " Sending you your requested channel info...",ServerNumber SendCommand "/dcc send " & Nickname & " " & Words(0) & ".txt",ServerNumber Else Sendcommand "/! Ulist " & Nickname & "|" & Channel & "|" & ServerNumber & "" End If ElseIf GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") = "Yes" and GetIniFile("" & words(0) & ".txt","DCC","Allowed","")>"0" then If GetIniFile("Settings.txt","Settings","Users","")="0" then SendCommand "/notice " & Nickname & " Sending you your requested channel info...",ServerNumber SendCommand "/dcc send " & Nickname & " " & Words(0) & ".txt",ServerNumber Else Sendcommand "/! Ulist " & Nickname & "|" & Channel & "|" & ServerNumber & "" End If Elseif GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") = "Yes" then If GetIniFile("Settings.txt","Settings","Users","")="0" then SendCommand "/notice " & Nickname & " Sending you your requested channel info...",ServerNumber SendCommand "/dcc send " & Nickname & " " & Words(0) & ".txt",ServerNumber Else Sendcommand "/! Ulist " & Nickname & "|" & Channel & "|" & ServerNumber & "" End If Else SendCommand "/notice " & Nickname & " Error: No permission! - " & GetIniFile("" & words(0) & ".txt","DCC","Allowed","") & "",ServerNumber End If Case "up" If IsOp(Nickname,words(0),ServerNumber) then SendCommand "/notice " & Nickname & " Error: You are up",ServerNumber ElseIf not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then SendCommand "/notice " & Nickname & " Cannot up! Reason: Not registered",ServerNumber ElseIf GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","")="Yes" then If not GetIniFile("" & words(0) & ".txt","op","Set","")="0" or GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then SendCommand "/mode " & words(0) & " +o " & Nickname & "",ServerNumber Elseif not IsVoice(Nickname,words(0),ServerNumber) then SendCommand "/mode " & words(0) & " +v " & Nickname & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: You are up!",ServerNumber End If ElseIf GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","")="Yes" then If GetIniFile("" & words(0) & ".txt","op","Set","")="2" then SendCommand "/mode " & words(0) & " +o " & Nickname & "",ServerNumber Elseif not IsVoice(Nickname,words(0),ServerNumber) then SendCommand "/mode " & words(0) & " +v " & Nickname & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: You are up!",ServerNumber End If ElseIf GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then If IsVoice(Nickname,words(0),ServerNumber) then SendCommand "/notice " & Nickname & " Error: You are up!",ServerNumber Else SendCommand "/mode " & words(0) & " +v " & Nickname & "",ServerNumber End If End If Case "down" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") and not IsVoice(Nickname,words(0),ServerNumber) and not IsOp(Nickname,words(0),ServerNumber) then SendCommand "/notice " & Nickname & " Cannot down! Reason: You are not voiced or opped!",ServerNumber Else SendCommand "/mode " & words(0) & " -ov " & Nickname & " " & Nickname & " ",ServerNumber End If Case "setinfo" If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then If Mid(Mid(Message,Len(Words(0)) -- 2),10)="" and not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Join","")="" then SendCommand "/notice " & Nickname & " Your info has been cleared!",ServerNumber WriteIniFile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Join","" ElseIf Lcase(Mid(Mid(Message,Len(Words(0)) -- 2),10))="" and GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Join","")="" then SendCommand "/notice " & Nickname & " Error: Nothing to clear!",ServerNumber ElseIf Lcase(Left(Mid(Message,Len(Words(0)) -- 11),1))="&" then SendCommand "/notice " & Nickname & " Error: Your info message cannot begin with the & symbol",ServerNumber Else WriteIniFile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Join",Mid(Mid(Message,Len(Words(0)) -- 2),10) If Lcase(Mid(Mid(Message,Len(Words(0)) -- 2),10))="off" then SendCommand "/notice " & Nickname & " I will no longer greet you on channel join",ServerNumber Else SendCommand "/notice " & Nickname & " " & Mid(Mid(Message,Len(Words(0)) -- 2),10) & "",ServerNumber End If End If Else Sendcommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End If Case "newchan" If words(0)=Getinifile("Settings.txt","Settings","Channel","") and Pass="" and Lcase(Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3))="" then If not Getinifile("Settings.txt","Settings","Channel","")="" then SendCommand "/notice " & nickname & " Correct syntax is " & Tool & "Newchan ",ServerNumber End If ElseIf Getinifile("Settings.txt","Settings","Channel","")="" then SendCommand "/msg " & words(0) & " Sorry, channel control script is not set up yet",ServerNumber ElseIf Not Lcase(Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3))="" and words(0)=Getinifile("Settings.txt","Settings","Channel","") and GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then If not Snick="" or not Setup="" or not Pass="" then SendCommand "/notice " & Nickname & " Error: This service is currently busy. Please try again in 30 seconds",ServerNumber ElseIf not GetIdentifier("$mask($nick(" & words(0) & "," & Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3) & ").mask,2)",ServerNumber)="$null" then SendCommand "/notice " & Nickname & " Starting up...",ServerNumber Setup= "#r" & GetIdentifier("$rnd(1000,9999)",ServerNumber) & " " & GetIdentifier("$rnd(1000,9999)",ServerNumber) & "" Pass="1" SendCommand "/join " & Left(Setup,6) & "",ServerNumber Snick= GetIdentifier("$mask($nick(" & words(0) & "," & Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3) & ").mask,2)",ServerNumber) SendCommand "/timer dsg 1 2 /mode " & Left(Setup,6) & " +k " & Mid(Setup,8) & "",ServerNumber SendCommand "/timer nchan 1 300 /! OnNewchan",ServerNumber SendCommand "/timer nchan2 1 300 /part " & Left(Setup,6) & "",ServerNumber SendCommand "/timer nchan3 1 300 /part " & Pass & "",ServerNumber SendCommand "/timer djfry 1 3 /notice " & Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3) & " Please /join " & Setup & " and know that you have 5 minutes to complete this task",ServerNumber Else SendCommand "/notice " & Nickname & " Please state an active new owner!",ServerNumber End If End If Case "topic" If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then If getIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","")="Yes" then If GetIniFile("" & words(0) & ".txt","Topic","Lock","")="On" and not getIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","")="Yes" then SendCommand "/notice " & Nickname & " Cannot change topic! Reason: Locked by an admin",ServerNumber Else SendCommand "/topic " & words(0) & " " & GetIniFile("" & words(0) & ".txt","Topic","Ident","") & " " & Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3) & "",ServerNumber Writeinifile"" & words(0) & ".txt","Topic","Topic",Mid(Message,8) Sendcommand "/msg Chanserv " & words(0) & " set defaulttopic " & GetIniFile("" & words(0) & ".txt","Topic","Ident","") & " " & Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3) & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End If Case "seen" If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","") = Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & words(2) & ").mask,2)",ServerNumber),"Nick","")="" and GetIniFile("" & words(0) & ".txt",words(2),"Host","")="" then SendCommand "/notice " & Nickname & " Error: This user does not exist!",ServerNumber ElseIf not GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber)="$null" then SendCommand "/notice " & Nickname & " " & Words(2) & " is active on the channel",ServerNumber ElseIf getIniFile("" & words(0) & ".txt",GetIniFile("" & words(0) & ".txt",words(2),"Host",""),"Seen","")="" then SendCommand "/notice " & Nickname & " Error: This user has insufficient data. Please try again later",ServerNumber Else SendCommand "/notice " & Nickname & " " & Words(2) & " last seen " & getIniFile("" & words(0) & ".txt",GetIniFile("" & words(0) & ".txt",words(2),"Host",""),"Seen","") & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End If Case "registration" If Not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber ElseIf Not getIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber ElseIf Lcase(words(2))="on" then If GetIniFile("" & words(0) & ".txt","Register","Allowed","")="Yes" then SendCommand "/notice " & Nickname & " Error: Automatic registration is already enabled",ServerNumber Else writeIniFile"" & words(0) & ".txt","Register","Allowed","Yes" SendCommand "/notice " & Nickname & " Automatic registration is now on",ServerNumber End if ElseIf Lcase(words(2))="off" then If GetIniFile("" & words(0) & ".txt","Register","Allowed","")="No" then SendCommand "/notice " & Nickname & " Error: Automatic registration is already disabled",ServerNumber Else writeIniFile"" & words(0) & ".txt","Register","Allowed","No" SendCommand "/notice " & Nickname & " Automatic registration is now off",ServerNumber End if End If Case "flip" If not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Cannot flip! Reason: Not a channel owner",ServerNumber ElseIf Words(2)=GetIdentifier("$Me",ServerNumber) then SendCommand "/notice " & Nickname & " Error: You cannot alter my channel modes!",ServerNumber ElseIf not GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber) then SendCommand "/notice " & Nickname & " Error: " & words(2) & " is not a registered user!",ServerNumber ElseIf IsOp(words(2),words(0),ServerNumber) or IsVoice(words(2),words(0),servernumber) then SendCommand "/mode " & words(0) & " -ov " & words(2) & " " & words(2) & " ",ServerNumber ElseIf GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Admin","")="Yes" then If not GetIniFile("" & words(0) & ".txt","op","Set","")="0" or GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/mode " & words(0) & " +o " & words(2) & "",ServerNumber Elseif not IsVoice(words(2),words(0),ServerNumber) then SendCommand "/mode " & words(0) & " +v " & words(2) & "",ServerNumber End If ElseIf GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Mod","")="Yes" then If GetIniFile("" & words(0) & ".txt","op","Set","")="2" then SendCommand "/mode " & words(0) & " +o " & words(2) & "",ServerNumber Elseif not IsVoice(words(2),words(0),ServerNumber) then SendCommand "/mode " & words(0) & " +v " & words(2) & "",ServerNumber End If Else SendCommand "/mode " & words(0) & " +v " & words(2) & "",ServerNumber End If Case "fix" If not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","")="Yes" then SendCommand "/notice " & Nickname & " Cannot fix! Reason: Not a channel moderator",ServerNumber ElseIf not GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber) then If IsOp(Words(2),Words(0),ServerNumber) or isvoice(Words(2),Words(0),ServerNumber) then SendCommand "/mode " & words(0) & " -ov " & words(2) & " " & words(2) & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: This user is at their appropriate user settings!",ServerNumber End if ElseIf GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Admin","")="Yes" then If not GetIniFile("" & words(0) & ".txt","op","Set","")="0" or GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Protect","")="Yes" then If Not IsOp(words(2),words(0),ServerNumber) then SendCommand "/mode " & words(0) & " +o " & words(2) & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: This user is at their appropriate user settings!",ServerNumber End If ElseIf IsOp(words(2),words(0),ServerNumber) and GetIniFile("" & words(0) & ".txt","op","Set","")="0" and not GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/mode " & words(0) & " -o+v " & words(2) & " " & words(2) & "",ServerNumber Elseif not IsVoice(words(2),words(0),ServerNumber) then SendCommand "/mode " & words(0) & " +v " & words(2) & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: This user is at their appropriate user settings!",ServerNumber End If ElseIf GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Mod","")="Yes" then If GetIniFile("" & words(0) & ".txt","op","Set","")="2" and not IsOp (words(2),words(0),ServerNumber) then SendCommand "/mode " & words(0) & " +o " & words(2) & "",ServerNumber ElseIf IsOp(words(2),words(0),ServerNumber) and not GetIniFile("" & words(0) & ".txt","op","Set","")="2" then SendCommand "/mode " & words(0) & " -o+v " & words(2) & " " & words(2) & "",ServerNumber Elseif not IsVoice(words(2),words(0),ServerNumber) then SendCommand "/mode " & words(0) & " +v " & words(2) & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: This user is at their appropriate user settings!",ServerNumber End If ElseIf IsOp(words(2),words(0),ServerNumber) then SendCommand "/mode " & words(0) & " -o+v " & words(2) & " " & words(2) & "",ServerNumber ElseIf not IsVoice(words(2),words(0),ServerNumber) then SendCommand "/mode " & words(0) & " +v " & words(2) & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: This user is at their appropriate user settings!",ServerNumber End If Case "sync" If not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","") ="Yes" then SendCommand "/notice " & Nickname & " Error: No permission!",ServerNumber Else Num = "0" Active ="0" SPcount = Getidentifier("$nick(" & words(0) & ",0),ServerNumber") Do while not Num = SPcount -- 1 Num = Num -- 1 Sname = Getidentifier("$nick(" & words(0) & "," & Num & "),ServerNumber") Shost = GetIdentifier("$mask($nick(" & words(0) & "," & Sname & ").mask,2)",ServerNumber) If Not Sname="$null" then If not Sname="ChanServ" then If IsOp(Sname,words(0),ServerNumber) then If not GetIniFile("" & words(0) & ".txt",Shost,"Host","")=Shost then WriteIniFile"" & words(0) & ".txt","Sync","Throw",GetIniFile("" & words(0) & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & words(0) & ".txt","Sync","Throwtype",GetIniFile("" & words(0) & ".txt","Sync","Throwtype","") + "-o" Active = Active -- 1 ElseIf GetIniFile("" & words(0) & ".txt",Shost,"Host","")=Shost and not GetIniFile("" & words(0) & ".txt",Shost,"Mod","")="Yes" then WriteIniFile"" & words(0) & ".txt","Sync","Throw",GetIniFile("" & words(0) & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & words(0) & ".txt","Sync","Throwtype",GetIniFile("" & words(0) & ".txt","Sync","Throwtype","") + "-o" Active = Active -- 1 ElseIf GetIniFile("" & words(0) & ".txt",Shost,"Mod","")="Yes" and not GetIniFile("" & words(0) & ".txt",Shost,"Admin","")="Yes" and not GetIniFile("" & words(0) & ".txt","op","Set","")="2" then WriteIniFile"" & words(0) & ".txt","Sync","Throw",GetIniFile("" & words(0) & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & words(0) & ".txt","Sync","Throwtype",GetIniFile("" & words(0) & ".txt","Sync","Throwtype","") + "-o" Active = Active -- 1 ElseIf GetIniFile("" & words(0) & ".txt",Shost,"Admin","")="Yes" and not GetIniFile("" & words(0) & ".txt",Shost,"Protect","")="Yes" and GetIniFile("" & words(0) & ".txt","op","Set","")="0" then WriteIniFile"" & words(0) & ".txt","Sync","Throw",GetIniFile("" & words(0) & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & words(0) & ".txt","Sync","Throwtype",GetIniFile("" & words(0) & ".txt","Sync","Throwtype","") + "-o" Active = Active -- 1 End If End If If isvoice(Sname,words(0),ServerNumber) and not GetIniFile("" & words(0) & ".txt",Shost,"Host","")=Shost then WriteIniFile"" & words(0) & ".txt","Sync","Throw",GetIniFile("" & words(0) & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & words(0) & ".txt","Sync","Throwtype",GetIniFile("" & words(0) & ".txt","Sync","Throwtype","") + "-v" Active = Active -- 1 End If If not IsOp(Sname,words(0),ServerNumber) then If GetIniFile("" & words(0) & ".txt",Shost,"Mod","")="Yes" and GetIniFile("" & words(0) & ".txt","op","Set","")="2" then WriteIniFile"" & words(0) & ".txt","Sync","Throw",GetIniFile("" & words(0) & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & words(0) & ".txt","Sync","Throwtype",GetIniFile("" & words(0) & ".txt","Sync","Throwtype","") + "+o" Active = Active -- 1 ElseIf GetIniFile("" & words(0) & ".txt",Shost,"Admin","")="Yes" and not GetIniFile("" & words(0) & ".txt",Shost,"Protect","")="Yes" and not GetIniFile("" & words(0) & ".txt","op","Set","")="0" then WriteIniFile"" & words(0) & ".txt","Sync","Throw",GetIniFile("" & words(0) & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & words(0) & ".txt","Sync","Throwtype",GetIniFile("" & words(0) & ".txt","Sync","Throwtype","") + "+o" Active = Active -- 1 ElseIf GetIniFile("" & words(0) & ".txt",Shost,"Protect","")="Yes" then WriteIniFile"" & words(0) & ".txt","Sync","Throw",GetIniFile("" & words(0) & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & words(0) & ".txt","Sync","Throwtype",GetIniFile("" & words(0) & ".txt","Sync","Throwtype","") + "+o" Active = Active -- 1 End If End If If not isvoice(Sname,words(0),ServerNumber) and GetIniFile("" & words(0) & ".txt",Shost,"Host","")=Shost then If GetIniFile("" & words(0) & ".txt",Shost,"Admin","")="Yes" then If not GetIniFile("" & words(0) & ".txt",Shost,"Protect","")="Yes" and GetIniFile("" & words(0) & ".txt","op","Set","")="0" then WriteIniFile"" & words(0) & ".txt","Sync","Throw",GetIniFile("" & words(0) & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & words(0) & ".txt","Sync","Throwtype",GetIniFile("" & words(0) & ".txt","Sync","Throwtype","") + "+v" Active = Active -- 1 End If ElseIf GetIniFile("" & words(0) & ".txt",Shost,"Mod","")="Yes" then If not GetIniFile("" & words(0) & ".txt",Shost,"Admin","")="Yes" and not GetIniFile("" & words(0) & ".txt","op","Set","")="2" then WriteIniFile"" & words(0) & ".txt","Sync","Throw",GetIniFile("" & words(0) & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & words(0) & ".txt","Sync","Throwtype",GetIniFile("" & words(0) & ".txt","Sync","Throwtype","") + "+v" Active = Active -- 1 End If ElseIf GetIniFile("" & words(0) & ".txt",Shost,"Host","")=Shost then WriteIniFile"" & words(0) & ".txt","Sync","Throw",GetIniFile("" & words(0) & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & words(0) & ".txt","Sync","Throwtype",GetIniFile("" & words(0) & ".txt","Sync","Throwtype","") + "+v" Active = Active -- 1 End If End If If Active = "5" or Active = "6" then SendCommand "/mode " & words(0) & " " & GetIniFile("" & words(0) & ".txt","Sync","Throwtype","") & " " & GetIniFile("" & words(0) & ".txt","Sync","Throw","") & "",ServerNumber Writeinifile"" & words(0) & ".txt","Sync","Throwtype","" WriteIniFile"" & words(0) & ".txt","Sync","Throw","" Active = "0" End If End If ElseIf not GetIniFile("" & words(0) & ".txt","Sync","Throwtype","")="" then SendCommand "/mode " & words(0) & " " & GetIniFile("" & words(0) & ".txt","Sync","Throwtype","") & " " & GetIniFile("" & words(0) & ".txt","Sync","Throw","") & "",ServerNumber Writeinifile"" & words(0) & ".txt","Sync","Throwtype","" WriteIniFile"" & words(0) & ".txt","Sync","Throw","" Active = "0" SendCommand "/notice " & Nickname & " The list is up to date",ServerNumber Else SendCommand "/notice " & Nickname & " The list is up to date",ServerNumber End If Loop End If Case "move" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" then If Not Setup="" or not Pass="" or not Snick="" or not Snick2="" then SendCommand "/notice " & Nickname & " Error: This service is currently busy. Please try again in 30 seconds",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Nick","")="" and GetIniFile("" & Words(0) & ".txt",words(2),"Host","")="" then SendCommand "/notice " & Nickname & " User " & words(2) & " does not exist",ServerNumber ElseIf words(2)=Getidentifier("$me",ServerNumber) or words(3)=Getidentifier("$me",ServerNumber) then SendCommand "/notice " & Nickname & " Error: You cannot perform this action!",Servernumber ElseIf words(2)=Nickname and GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Special","") ="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot perform this action!",Servernumber ElseIf Left(GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host",""),1)="s" or Left(GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " " & words(2) & " is suspended!",ServerNumber ElseIf GetIdentifier("$mask($nick(" & Words(0) & "," & words(3) & ").mask,2)",ServerNumber)="$null" then SendCommand "/notice " & Nickname & " Error: You can only move an account to an active user!",ServerNumber ElseIf words(3)=Nickname then SendCommand "/notice " & Nickname & " Error: You cannot overwrite your own profile!",Servernumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Words(0) & "," & words(3) & ").mask,2)",ServerNumber) then SendCommand "/notice " & Nickname & " Error: You aren't moving anything or the user has the same host",ServerNumber ElseIf not GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & words(3) & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & words(0) & "," & words(3) & ").mask,2)",ServerNumber) then If words(2)=Nickname then SendCommand "/notice " & Nickname & " WARNING: You will lose all bot control in your channel and trade ownership to " & words(3) & "",ServerNumber End If SendCommand "/notice " & Nickname & " User " & words(3) & " has an account which will be overwritten! Proceed? (&Yes,&No)",ServerNumber Setup="5" If not GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host","")="" then Snick=GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host","") Else Snick=GetIniFile("" & Words(0) & ".txt",words(2),"Host","") End If Snick2=GetIdentifier("$mask($nick(" & Words(0) & "," & words(3) & ").mask,2)",ServerNumber) Pass=Host SendCommand "/timer sdog1 1 30 /! OnMove",ServerNumber SendCommand "/timer sdog3 1 30 /notice " & Nickname & " Transfer cancelled!",ServerNumber ElseIf not GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(3),"Host",""),"Host","")="" and not words(2)=words(3) then SendCommand "/notice " & Nickname & " Error: " & words(3) & " is using a registered nickname. " & words(3) & " must change nicknames, authenticate or use the original account holder nickname",ServerNumber Else If words(2)=Nickname then SendCommand "/notice " & Nickname & " WARNING: You will lose all bot control in your channel and trade ownership to " & words(3) & "",ServerNumber End If SendCommand "/notice " & Nickname & " User " & words(3) & " does not have an account and will gain only permissions from " & words(2) & ". Proceed? (&Yes,&No)",ServerNumber Setup="5" Pass=Host If not GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host","")="" then Snick=GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host","") Else Snick=GetIniFile("" & Words(0) & ".txt",words(2),"Host","") End If Snick2=GetIdentifier("$mask($nick(" & Words(0) & "," & words(3) & ").mask,2)",ServerNumber) SendCommand "/timer sdog1 1 30 /! OnMove",Servernumber SendCommand "/timer sdog3 1 30 /notice " & Nickname & " Transfer cancelled!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End If Case "yes" If Setup="5" and Host=Pass then SendCommand "/timer sdog1 off" SendCommand "/timer sdog3 off" Notemem="0" Do while not Notemem > 49 Notemem = Notemem -- 1 If not Getinifile("Note.txt",Snick,Notemem,"")="" then Writeinifile"Note.txt",Snick2,Notemem,Getinifile("Note.txt",Snick,Notemem,"") End If Loop WriteIniFile"" & Words(0) & ".txt",Getinifile("" & Words(0) & ".txt",Snick2,"Nick",""),"Host","" WriteIniFile"" & Words(0) & ".txt",Snick2,"Nick",GetIniFile("" & Words(0) & ".txt",Snick,"Nick","") WriteIniFile"" & Words(0) & ".txt",Snick2,"Host",Snick2 WriteIniFile"" & Words(0) & ".txt",Snick2,"Mod",GetIniFile("" & Words(0) & ".txt",Snick,"Mod","") WriteIniFile"" & Words(0) & ".txt",Snick2,"Admin",GetIniFile("" & Words(0) & ".txt",Snick,"Admin","") WriteIniFile"" & Words(0) & ".txt",Snick2,"Protect",GetIniFile("" & Words(0) & ".txt",Snick,"Protect","") WriteIniFile"" & Words(0) & ".txt",Snick2,"Join",GetIniFile("" & Words(0) & ".txt",Snick,"Join","") WriteIniFile"" & Words(0) & ".txt",Snick2,"Note",GetIniFile("" & Words(0) & ".txt",Snick,"Note","") WriteIniFile"" & Words(0) & ".txt",Snick2,"Seen",GetIniFile("" & Words(0) & ".txt",Snick,"Seen","") writeinifile"" & Words(0) & ".txt",Snick2,"Op",GetIniFile("" & Words(0) & ".txt",Snick,"Op","") WriteIniFile"" & Words(0) & ".txt",Snick2,"Special",GetIniFile("" & Words(0) & ".txt",Snick,"Special","") WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Snick2,"Nick",""),"Host",Snick2 WriteIniFile"" & Words(0) & ".txt",Snick,"Nick"," Unregistered on " & Date & "" WriteIniFile"" & Words(0) & ".txt",Snick,"Host"," Moved accounts to " & Snick2 & "" WriteIniFile"" & Words(0) & ".txt",Snick,"Mod","" WriteIniFile"" & Words(0) & ".txt",Snick,"Admin","" WriteIniFile"" & Words(0) & ".txt",Snick,"Protect","" WriteIniFile"" & Words(0) & ".txt",Snick,"Join","" WriteIniFile"" & Words(0) & ".txt",Snick,"Note","" WriteIniFile"" & Words(0) & ".txt",Snick,"Seen","" writeinifile"" & Words(0) & ".txt",Snick,"Op","" WriteIniFile"" & Words(0) & ".txt",Snick,"Special","" Setup="" Pass="" Snick="" Snick2="" SendCommand "/notice " & nickname & " The account has been moved successfully!",ServerNumber End if Case "no" If Setup="5" and Host=Pass then SendCommand "/timer sdog1 off" SendCommand "/timer sdog3 off" Setup="" Pass="" Snick="" Snick2="" SendCommand "/notice " & nickname & " The account has not been moved or altered!",ServerNumber End if Case "trefresh" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then If getIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","")="Yes" then SendCommand "/topic " & Words(0) & " " & GetIniFile("" & Words(0) & ".txt","Topic","Ident","") & " " & GetIniFile("" & Words(0) & ".txt","Topic","Topic","") & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End If Case "me" If Left(GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " Your account is currently suspended!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then If Not GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Join","")="" and Not Left(GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Join",""),1)="&" then SendCommand "/notice " & Nickname & " Join Message: " & GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Join","") & "",ServerNumber End If If not GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Note","")="" then SendCommand "/notice " & Nickname & " Your note: " & GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Note","") & "",ServerNumber End If If getinifile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Op","")="Off" then SendCommand "/notice " & Nickname & " Automatic channel op on join is disabled",ServerNumber End If If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Special","")="S" then Spad="-R-" End If SendCommand "/notice " & Nickname & " " & GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Nick","") & ": Is a mod= " & getIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","") & " ; Has admin= " & Spad & "" & GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") & " ; Is Protected= " & GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") & " ; Host= " & GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","") & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End if Case "note" If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then If Mid(Message,7)="" and not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Note","")="" then SendCommand "/notice " & Nickname & " Your note has been cleared!",ServerNumber WriteIniFile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Note","" ElseIf Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3)="" and GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Note","")="" then SendCommand "/notice " & Nickname & " Error: Nothing to clear!",ServerNumber Else WriteIniFile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Note",Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3) SendCommand "/notice " & Nickname & " Note: " & Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3) & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End If Case "kick", "k" If words(2)=GetIdentifier("$me",ServerNumber) then SendCommand "/Notice " & Nickname & " Nope :P",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then If getIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","")="Yes" then If words(2) = Nickname then SendCommand "/kick " & Words(0) & " " & words(2) & " Ha, you kicked yourself...",ServerNumber ElseIf GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber)="$null" then SendCommand "/notice " & Nickname & " Error: This is not an active user!",ServerNumber Elseif GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Sorry, that user is protected",ServerNumber ElseIf getIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","")="No" and getIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Admin","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot kick a higher power",ServerNumber ElseIf getIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","")="Yes" and getIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Mod","")="Yes" and not getIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","")="Yes"then SendCommand "/notice " & Nickname & " Error: You cannot kick other mods!",ServerNumber Else SendCommand "/kick " & Words(0) & " " & words(2) & " " & Mid(Message,Len(Words(0)) + Len(Words(1)) + Len(Words(2)) -- 4) & " ~ " & Nickname & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End if Case "setop" If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" then If Lcase(words(2))="0" then If GetIniFile("" & words(0) & ".txt","op","Set","")="0" then SendCommand "/notice " & Nickname & " Error: Auto op is already set to owner only!",ServerNumber Else writeIniFile"" & words(0) & ".txt","op","Set","0" SendCommand "/notice " & Nickname & " Only channel owner will now get op",ServerNumber End If ElseIf Lcase(words(2))="1" then If GetIniFile("" & words(0) & ".txt","op","Set","")="1" then SendCommand "/notice " & Nickname & " Error: Auto op is already set to admins and higher!",ServerNumber Else writeIniFile"" & words(0) & ".txt","op","Set","1" SendCommand "/notice " & Nickname & " Only channel admins and higher will now get op",ServerNumber End If ElseIf Lcase(words(2))="2" then If GetIniFile("" & words(0) & ".txt","op","Set","")="2" then SendCommand "/notice " & Nickname & " Error: Auto op is already set to moderators and higher!",ServerNumber Else writeIniFile"" & words(0) & ".txt","op","Set","2" SendCommand "/notice " & Nickname & " Warning: Only channel moderators and higher will now get op (Not recommended)",ServerNumber End If End If Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End If Case "unban", "ub" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then If getIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","")="Yes" then SendCommand "/msg chanserv " & Words(0) & " delban " & words(2) & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End if Case "snuggle" If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then If GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber)="$null" then SendCommand "/notice " & Nickname & " D: But this person isn't here! Or you mispelled the nick...",ServerNumber Else SendCommand "/describe " & words(0) & " snuggles " & words(2) & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Ew: Not registered!",ServerNumber End if Case "undoban", "udb" If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then If getIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","")="Yes" then If GetIniFile("" & words(0) & ".txt","Lastban","Ban","")="" then SendCommand "/notice " & Nickname & " Error: No recent bans!",ServerNumber Else SendCommand "/msg chanserv " & words(0) & " delban " & GetIniFile("" & words(0) & ".txt","Lastban","Ban","") & "",ServerNumber WriteIniFile"" & words(0) & ".txt","Lastban","Ban","" End If Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End if Case "user" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then If not GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host","")= "" and not GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Admin","")= "" then If not Left(GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host",""),1)="s" then If Not GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Join","")="" and not Left(GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Join",""),1)="&" then SendCommand "/notice " & Nickname & " Join Message: " & GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Join","") & "",ServerNumber End If If GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Special","")="S" then Spad="-R-" End If SendCommand "/notice " & Nickname & " " & GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Nick","") & ": Is a mod= " & getIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Mod","") & " ; Has admin= "& Spad & "" & GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Admin","") & " ; Is protected= " & GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Protect","") & " ; Host= " & GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host","") & "",ServerNumber Else SendCommand "/notice " & Nickname & " This account is currently suspended!",ServerNumber End If ElseIf Not GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Host","")="" and not GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Admin","")="" then If not Left(GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Host",""),1)="s" then If Not GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Join","")="" and not Left(GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Join",""),1)="&" then SendCommand "/notice " & Nickname & " Join Message: " & GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Join","") & "",ServerNumber End If If not GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber)="$null" then SendCommand "/notice " & Nickname & " Warning: This active user may be a fake or is not authed!",ServerNumber End If If GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Special","")="S" then Spad="-R-" End If SendCommand "/notice " & Nickname & " " & GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Nick","") & ": Is a mod= " & getIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Mod","") & " ; Has admin= " & Spad & "" & GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Admin","") & " ; Is protected= " & GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Protect","") & " ; Host= " & GetIniFile("" & Words(0) & ".txt",words(2),"Host","") & "",ServerNumber Else SendCommand "/notice " & Nickname & " This account is currently suspended!",ServerNumber End if Else SendCommand "/notice " & Nickname & " User " & words(2) & " does not exist",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End If Case "ban", "b" If words(2)=GetIdentifier("$me",ServerNumber) then SendCommand "/Notice " & Nickname & " Nope :P",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","")="Yes" then If GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " " & words(2) & " is protected!",ServerNumber ElseIf GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber)="$null" then SendCommand "/notice " & Nickname & " Error: This is not an active user!",ServerNumber ElseIf getIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","")="Yes" and getIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Admin","")="Yes" and not getIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot ban other admins!",ServerNumber ElseIf getIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","")="Yes" and not getIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Admin","")="Yes" and not getIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot ban a higher power",ServerNumber ElseIf getIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","")="Yes" and getIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Mod","")="Yes" and not getIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot ban other mods!",ServerNumber Else WriteIniFile"" & Channel & ".txt","Lastban","Ban",Nickname SendCommand "/ban " & Words(0) & " " & words(2) & "",ServerNumber SendCommand "/kick " & Words(0) & " " & words(2) & " " & Mid(Message,Len(Words(0)) + Len(Words(1)) + Len(Words(2)) -- 4) & " ~ " & Nickname & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Case "suspend" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") ="Yes" then If GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Nick","")="" and GetIniFile("" & Words(0) & ".txt",words(2),"Host","")="" then SendCommand "/notice " & Nickname & " User " & words(2) & " does not exist",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Special","")="S" then SendCommand "/notice " & Nickname & " Sorry, you are restricted from using this command!",ServerNumber Elseif GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Admin","") ="Yes" and not GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot suspend other admins!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Admin","")="Yes" and not GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot suspend other admins!",ServerNumber ElseIf Left(GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host",""),1)="s" or Left(GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " Error: This user is already suspended!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Protect","")="Yes" or GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " " & words(2) & " is protected!",ServerNumber ElseIf not GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Host","")="" then Banner = GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Mod","") WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Mod","s " & Banner & "" Banner = GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Admin","") WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Admin","s " & Banner & "" Banner = GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Host","") WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Host","s " & Banner & "" SendCommand "/notice " & Nickname & " User suspended!",ServerNumber If IsOp(words(2),words(0),ServerNumber) then sendcommand "/mode " & Words(0) & " -o " & words(2) & "",ServerNumber If IsVoice(words(2),words(0),ServerNumber) then sendcommand "/mode " & Words(0) & " -v " & words(2) & "",ServerNumber Else Banner = Getinifile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Mod","") WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Mod","s " & Banner & "" Banner = Getinifile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Admin","") WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Admin","s " & Banner & "" Banner = GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber) WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host","s " & Banner & "" SendCommand "/notice " & Nickname & " User suspended!",ServerNumber If IsOp(words(2),Channel,ServerNumber) then sendcommand "/mode " & Words(0) & " -o " & words(2) & "",ServerNumber If IsVoice(words(2),Channel,ServerNumber) then sendcommand "/mode " & Words(0) & " -v " & words(2) & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel admin!",ServerNumber End If Case "addban" If not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: Not a channel owner",ServerNumber Else WriteIniFile"" & Channel & ".txt","Lastban","Ban",words(2) SendCommand "/msg ChanServ " & words(0) & " Addban " & words(2) & "",ServerNumber End If Case "delban" If not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: Not a channel owner",ServerNumber Else SendCommand "/msg ChanServ " & words(0) & " delban " & words(2) & "",ServerNumber End If Case "unsuspend" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") ="Yes" then If GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Nick","")="" and GetIniFile("" & Words(0) & ".txt",words(2),"Host","")="" then SendCommand "/notice " & Nickname & " User " & words(2) & " does not exist",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Special","")="S" then SendCommand "/notice " & Nickname & " Sorry, you are restricted from using this command!",ServerNumber Elseif GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Admin","") ="Yes" and not GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot unsuspend other admins!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Admin","")="Yes" and not GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot unsuspend other admins!",ServerNumber ElseIf not Left(GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host",""),1)="s" and not Left(GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " Error: This user is not suspended!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Protect","")="Yes" or GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " " & words(2) & " is protected!",ServerNumber ElseIf not GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Host","")="" then Banner = Mid(GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Mod",""),3) Writeinifile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Mod",Banner Banner = Mid(GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Admin",""),3) Writeinifile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Admin",Banner Banner = Mid(GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Host",""),3) WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Host",Banner SendCommand "/notice " & Nickname & " User unsuspended!",ServerNumber sendcommand "/mode " & Words(0) & " +v " & words(2) & "",ServerNumber Else Banner = Mid(Getinifile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Mod",""),3) WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Mod",Banner Banner = Mid(Getinifile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Admin",""),3) WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Admin",Banner Banner = GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber) WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host",Banner SendCommand "/notice " & Nickname & " User unsuspended!",ServerNumber sendcommand "/mode " & Words(0) & " +v " & words(2) & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel admin!",ServerNumber End If Case "restrict" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" then If GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Host","")="" and GetIniFile("" & Words(0) & ".txt",Words(2),"Host","")="" then SendCommand "/Notice " & Nickname & " That user does not exist!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Host",""),"Protect","")="Yes" or GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " That user is protected!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Host",""),"Admin","")="No" or GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Admin","")="No" then SendCommand "/notice " & Nickname & " Error: This command only works on admins!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Host",""),"Special","")="S" or GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Special","")="S" then SendCommand "/notice " & Nickname & " That user is already restricted!",ServerNumber ElseIf not GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Host","")="" then WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Special","S" SendCommand "/notice " & Nickname & " User is now on admin restrictions!",ServerNumber Else WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Special","S" SendCommand "/notice " & Nickname & " User is now on admin restrictions!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End If Case "unrestrict" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" then If GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Host","")="" and GetIniFile("" & Words(0) & ".txt",Words(2),"Host","")="" then SendCommand "/Notice " & Nickname & " That user does not exist!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Host",""),"Protect","")="Yes" or GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " That user is protected!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Host",""),"Special","")="" and GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Special","")="" then SendCommand "/notice " & Nickname & " That user is not restricted!",ServerNumber ElseIf not GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Host","")="" then WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Special","" SendCommand "/notice " & Nickname & " User is no longer on admin restrictions!",ServerNumber Else WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Special","" SendCommand "/notice " & Nickname & " User is no longer on admin restrictions!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End If Case "greet" If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","") ="Yes" then If GetIniFile("" & words(0) & ".txt","Topic","Lock","")="On" and not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") ="Yes" then SendCommand "/notice " & Nickname & " Cannot change greet! Reason: Locked by an admin",ServerNumber ElseIf Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3)="" and Getinifile("" & words(0) & ".txt","Joinmsg","Msg","")="" then SendCommand "/notice " & Nickname & " Error: Nothing to clear",ServerNumber Elseif Lcase(Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3))="off" and Getinifile("" & words(0) & ".txt","Joinmsg","Msg","")="&" then SendCommand "/notice " & nickname & " Error: Greet is already off!",ServerNumber Elseif Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3)="" then Writeinifile"" & words(0) & ".txt","Joinmsg","Msg","Welcome back!" SendCommand "/notice " & Nickname & " Default Greet message used", ServerNumber ElseIf Lcase(Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3))="off" then Writeinifile"" & words(0) & ".txt","Joinmsg","Msg","&" SendCommand "/notice " & Nickname & " Greet message off", ServerNumber Else Writeinifile"" & words(0) & ".txt","Joinmsg","Msg",Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3) SendCommand "/notice " & Nickname & " " & Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3) & "", ServerNumber End if Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Case "infolock" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") ="Yes" then If GetIniFile("" & Words(0) & ".txt","Topic","Lock","")="On" then WriteIniFile"" & Words(0) & ".txt","Topic","Lock","Off" SendCommand "/notice " & Nickname & " Info is now free to edit!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt","Topic","Lock","")="Off" then WriteIniFile"" & Words(0) & ".txt","Topic","Lock","On" SendCommand "/notice " & Nickname & " Info is now locked to editors!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel admin",ServerNumber End If Case "dtopic" If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" then If Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3)="" then If Getinifile("" & words(0) & ".txt","Topic","Ident","")="" then SendCommand "/notice " & nickname & " Error: Nothing to clear!",ServerNumber Else SendCommand "/topic " & words(0) & " Welcome to " & words(0) & " || " & Getinifile("" & words(0) & ".txt","Topic","Topic","") & "",ServerNumber Writeinifile"" & words(0) & ".txt","Topic","Ident","Welcome to " & words(0) & " ||" Sendcommand "/msg Chanserv " & words(0) & " set defaulttopic Welcome to " & words(0) & " || " & Getinifile("" & words(0) & ".txt","Topic","Topic","") & "",ServerNumber SendCommand "/notice " & Nickname & " Default topic ident used!",ServerNumber End If ElseIf not Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3)="" then If Getinifile("" & words(0) & ".txt","Topic","Ident","")= Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3) then SendCommand "/notice " & nickname & " Error: You are using the same default! Try &Trefresh to resolve any errors.",ServerNumber Else SendCommand "/topic " & words(0) & " " & Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3) & " " & Getinifile("" & words(0) & ".txt","Topic","Topic","") & "",ServerNumber Sendcommand "/msg Chanserv " & words(0) & " set defaulttopic " & Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3) & " " & Getinifile("" & words(0) & ".txt","Topic","Topic","") & "",ServerNumber Writeinifile"" & words(0) & ".txt","Topic","Ident",Mid(Message,Len(Words(0)) + Len(Words(1)) -- 3) End If End if Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End If Case "tool" If not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" or not words(0)=Getinifile("Settings.txt","Settings","Channel","") then Sendcommand "/notice " & Nickname & " Error: No permission!",ServerNumber Elseif Tool = words(1) then Sendcommand "/notice " & Nickname & " Error: You already have this as your current tool!",ServerNumber Else Tool = Lcase(Left(words(1),1)) Sendcommand "/notice " & Nickname & " Success: Your new tool is " & Tool & "",ServerNumber End If Case "clearinfo" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") ="Yes" then If GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host","")="" and GetIniFile("" & Words(0) & ".txt",words(2),"Host","")="" then SendCommand "/Notice " & Nickname & " That user does not exist!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host",""),"Protect","")="Yes" or GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " That user is protected!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host",""),"Join","")="" and GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Join","")="" then SendCommand "/notice " & Nickname & " That user has no info to clear!",ServerNumber ElseIf Left(GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host",""),"Join",""),1)="&" or Left(GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Join",""),1)="&" then SendCommand "/notice " & Nickname & " Error: An admin has already cleared this user's info!",ServerNumber ElseIf not GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Join","")="" then WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",words(2),"Host",""),"Join","& " & GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Nick","") & "" SendCommand "/notice " & Nickname & " Info cleared!",ServerNumber Else WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Join","& " & GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Nick","") & "" SendCommand "/notice " & Nickname & " Info cleared!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel admin!",ServerNumber End If Case "op" oword = Split(Mid(Message,Len(words(0)) + Len(Words(1)) -- 3) + " s"," ") ovoc = "0" Thumb = "" othumb = "" If Lcase(words(2))="off" and GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","") ="Yes" then If getinifile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Op","")="Off" then SendCommand "/notice " & Nickname & " Error: You already disabled automatic op for yourself!",ServerNumber Else writeinifile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Op","Off" SendCommand "/notice " & Nickname & " Auto op now off",ServerNumber End If ElseIf Lcase(words(2))="on" and GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","") ="Yes" then If getinifile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Op","")="" then SendCommand "/notice " & Nickname & " Error: You already enabled automatic op for yourself!",ServerNumber Else writeinifile"" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Op","" SendCommand "/notice " & Nickname & " Auto op now on (If applicable)",ServerNumber End If ElseIf GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" then Do while not ovoc > "7" If oword(ovoc) = "s" or ovoc = "7" then If not othumb = "" then SendCommand "/mode " & words(0) & " +oooooo " & othumb & "",ServerNumber End If If Not Thumb = "" then SendCommand "/notice " & Nickname & " Already opped users: " & Thumb & "",ServerNumber End If ovoc = "7" ElseIf IsOp(oword(ovoc),words(0),ServerNumber) and not GetIdentifier("$mask($nick(" & words(0) & "," & oword(ovoc) & ").mask,2)",ServerNumber)="$null" then Thumb = Thumb + " " & oword(ovoc) & "" Elseif not GetIdentifier("$mask($nick(" & words(0) & "," & oword(ovoc) & ").mask,2)",ServerNumber)="$null" then othumb = othumb + " " & oword(ovoc) & "" End If ovoc = ovoc -- 1 Loop ElseIf GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") ="Yes" and not GetIniFile("" & words(0) & ".txt","op","Set","")="0" then Do while not ovoc > "7" If oword(ovoc) = "s" or ovoc = "7" then If not othumb = "" then SendCommand "/mode " & words(0) & " +oooooo " & othumb & "",ServerNumber End If If Not Thumb = "" then SendCommand "/notice " & Nickname & " Already opped users: " & Thumb & "",ServerNumber End If ovoc = "7" ElseIf IsOp(oword(ovoc),words(0),ServerNumber) and not GetIdentifier("$mask($nick(" & words(0) & "," & oword(ovoc) & ").mask,2)",ServerNumber)="$null" then Thumb = Thumb + " " & oword(ovoc) & "" Elseif not GetIdentifier("$mask($nick(" & words(0) & "," & oword(ovoc) & ").mask,2)",ServerNumber)="$null" then othumb = othumb + " " & oword(ovoc) & "" End If ovoc = ovoc -- 1 Loop Else SendCommand "/notice " & Nickname & " Error: No permission!",Servernumber End If Case "deop" Oword = Split(Mid(Message,Len(words(0)) + Len(Words(1)) -- 3) + " s"," ") Ovoc = "0" Thumb = "" Othumb = "" OPthumb = "" If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" then Do while not Ovoc > "7" If Oword(Ovoc) = "s" or Ovoc = "7" then If not Othumb = "" then SendCommand "/mode " & Words(0) & " -oooooo " & Othumb & "",ServerNumber End If If Not Thumb = "" and not OPthumb="" then SendCommand "/notice " & Nickname & " Already deopped users: " & Thumb & " - You cannot deop these users: " & OPthumb & "",ServerNumber Else If not OPthumb = "" then SendCommand "/notice " & Nickname & " You cannot deop these users: " & OPthumb & "",ServerNumber End If If Not Thumb = "" then SendCommand "/notice " & Nickname & " Already deopped users: " & Thumb & "",ServerNumber End If End If Ovoc = "7" ElseIf not IsOp(Oword(Ovoc),words(0),ServerNumber) and not GetIdentifier("$mask($nick(" & words(0) & "," & Oword(Ovoc) & ").mask,2)",ServerNumber)="$null" then Thumb = Thumb + " " & Oword(Ovoc) & "" Elseif GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Oword(Ovoc) & ").mask,2)",ServerNumber),"Protect","")="Yes" and not GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Oword(Ovoc) & ").mask,2)",ServerNumber),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then OPthumb = OPthumb + " " & Oword(Ovoc) & "" Elseif not GetIdentifier("$mask($nick(" & words(0) & "," & Oword(Ovoc) & ").mask,2)",ServerNumber)="$null" then Othumb = Othumb + " " & Oword(Ovoc) & "" End If Ovoc = Ovoc -- 1 Loop ElseIf GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") ="Yes" and not GetIniFile("" & words(0) & ".txt","op","Set","")="0" then Do while not Ovoc > "7" If Oword(Ovoc) = "s" or Ovoc = "7" then If not Othumb = "" then SendCommand "/mode " & Words(0) & " -oooooo " & Othumb & "",ServerNumber End If If Not Thumb = "" and not OPthumb="" then SendCommand "/notice " & Nickname & " Already deopped users: " & Thumb & " - You cannot deop these users: " & OPthumb & "",ServerNumber Else If not OPthumb = "" then SendCommand "/notice " & Nickname & " You cannot deop these users: " & OPthumb & "",ServerNumber End If If Not Thumb = "" then SendCommand "/notice " & Nickname & " Already deopped users: " & Thumb & "",ServerNumber End If End If Ovoc = "7" ElseIf not IsOp(Oword(Ovoc),words(0),ServerNumber) and not GetIdentifier("$mask($nick(" & words(0) & "," & Oword(Ovoc) & ").mask,2)",ServerNumber)="$null" then Thumb = Thumb + " " & Oword(Ovoc) & "" Elseif GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Oword(Ovoc) & ").mask,2)",ServerNumber),"Admin","")="Yes" and not GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Oword(Ovoc) & ").mask,2)",ServerNumber),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then OPthumb = OPthumb + " " & Oword(Ovoc) & "" Elseif not GetIdentifier("$mask($nick(" & words(0) & "," & Oword(Ovoc) & ").mask,2)",ServerNumber)="$null" then Othumb = Othumb + " " & Oword(Ovoc) & "" End If Ovoc = Ovoc -- 1 Loop Else SendCommand "/notice " & Nickname & " Error: No permission!",Servernumber End If Case "voice", "v" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","") ="Yes" or IsOp(Nickname,words(0),ServerNumber) then Vword = Split(Mid(Message,Len(words(0)) + Len(Words(1)) -- 3) + " s"," ") Lvoc = "0" Thumb = "" Vthumb = "" Do while not Lvoc > "7" If Vword(Lvoc) = "s" or Lvoc = "7" then If not Vthumb = "" then SendCommand "/mode " & Words(0) & " +vvvvvv " & Vthumb & "",ServerNumber End If If Not Thumb = "" then SendCommand "/notice " & Nickname & " Already voiced users: " & Thumb & "",ServerNumber End If Lvoc = "7" ElseIf IsVoice(Vword(Lvoc),words(0),ServerNumber) and not GetIdentifier("$mask($nick(" & words(0) & "," & Vword(Lvoc) & ").mask,2)",ServerNumber)="$null" then Thumb = Thumb + " " & Vword(Lvoc) & "" Elseif not GetIdentifier("$mask($nick(" & words(0) & "," & Vword(Lvoc) & ").mask,2)",ServerNumber)="$null" then Vthumb = Vthumb + " " & Vword(Lvoc) & "" End If Lvoc = Lvoc -- 1 Loop Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Case "devoice", "dv" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","") ="Yes" or IsOp(Nickname,words(0),ServerNumber) then Vword = Split(Mid(Message,Len(words(0)) + Len(Words(1)) -- 3) + " s"," ") Lvoc = "0" Thumb = "" Vthumb = "" VPthumb = "" Do while not Lvoc > "7" If Vword(Lvoc) = "s" or Lvoc = "7" then If not Vthumb = "" then SendCommand "/mode " & Words(0) & " -vvvvvv " & Vthumb & "",ServerNumber End If If Not Thumb = "" and not VPthumb="" then SendCommand "/notice " & Nickname & " Already devoiced users: " & Thumb & " - You cannot devoice these users: " & VPthumb & "",ServerNumber Else If not VPthumb = "" then SendCommand "/notice " & Nickname & " You cannot devoice these users: " & VPthumb & "",ServerNumber End If If Not Thumb = "" then SendCommand "/notice " & Nickname & " Already devoiced users: " & Thumb & "",ServerNumber End If End If Lvoc = "7" ElseIf not IsVoice(Vword(Lvoc),words(0),ServerNumber) and not GetIdentifier("$mask($nick(" & words(0) & "," & Vword(Lvoc) & ").mask,2)",ServerNumber)="$null" then Thumb = Thumb + " " & Vword(Lvoc) & "" Elseif GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Vword(Lvoc) & ").mask,2)",ServerNumber),"Mod","")="Yes" and not GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Vword(Lvoc) & ").mask,2)",ServerNumber),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") and not IsOp(Nickname,words(0),ServerNumber) then VPthumb = VPthumb + " " & Vword(Lvoc) & "" Elseif not GetIdentifier("$mask($nick(" & words(0) & "," & Vword(Lvoc) & ").mask,2)",ServerNumber)="$null" then Vthumb = Vthumb + " " & Vword(Lvoc) & "" End If Lvoc = Lvoc -- 1 Loop Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Case "moderate" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") ="Yes" then If GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Nick","")="" and GetIniFile("" & Words(0) & ".txt",Words(2),"Host","")="" then SendCommand "/notice " & Nickname & " User " & Words(2) & " does not exist",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Special","")="S" then SendCommand "/notice " & Nickname & " Sorry, you are restricted from using this command!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Mod","")="Yes" or GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Mod","")="Yes" then SendCommand "/notice " & Nickname & " " & Words(2) & " Already has moderation",ServerNumber ElseIf Left(GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Host",""),1)="s" or Left(GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " " & Words(2) & " is suspended!",ServerNumber ElseIf not GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Host","")="" then WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Mod","Yes" SendCommand "/notice " & Nickname & " " & Words(2) & " is now a moderator",ServerNumber If GetIniFile("" & Words(0) & ".txt","op","Set","")="2" then SendCommand "/mode " & Words(0) & " +o " & Words(2) & "",ServerNumber End If Else WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Mod","Yes" SendCommand "/notice " & Nickname & " " & Words(2) & " is now a moderator",ServerNumber If GetIniFile("" & Words(0) & ".txt","op","Set","")="2" then SendCommand "/mode " & Words(0) & " +o " & Words(2) & "",ServerNumber End If End If Else SendCommand "/notice " & Nickname & " Error: Not a channel admin!",ServerNumber End If Case "demoderate" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") ="Yes" then If GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Nick","")="" and GetIniFile("" & Words(0) & ".txt",Words(2),"Host","")="" then SendCommand "/notice " & Nickname & " User " & Words(2) & " does not exist",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Special","")="S" then SendCommand "/notice " & Nickname & " Sorry, you are restricted from using this command!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Protect","")="Yes" or GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " " & Words(2) & " is protected!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Mod","")="No" or GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Mod","")="No" then SendCommand "/notice " & Nickname & " " & Words(2) & " is not a moderator",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Admin","")="Yes" or GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Admin","")="Yes" then If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then If not GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Host","")="" then WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Mod","No" WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Admin","No" SendCommand "/notice " & Nickname & " " & Words(2) & " is no longer a moderator or admin",ServerNumber SendCommand "/mode " & Words(0) & " -o " & Words(2) & "",ServerNumber SendCommand "/mode " & Words(0) & " +v " & Words(2) & "",ServerNumber Else WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Mod","No" WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Admin","No" SendCommand "/notice " & Nickname & " " & Words(2) & " is no longer a moderator or admin",ServerNumber SendCommand "/mode " & Words(0) & " -o " & Words(2) & "",ServerNumber SendCommand "/mode " & Words(0) & " +v " & Words(2) & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: You cannot delete this admin!",ServerNumber End If ElseIf not GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Host","")="" then WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Mod","No" SendCommand "/notice " & Nickname & " " & Words(2) & " is no longer a moderator",ServerNumber SendCommand "/mode " & Words(0) & " -o " & Words(2) & "",ServerNumber Else WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Mod","No" SendCommand "/notice " & Nickname & " " & Words(2) & " is no longer a moderator",ServerNumber SendCommand "/mode " & Words(0) & " -o " & Words(2) & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel admin!",ServerNumber End if Case "pass" If not Pass="5" or not Setup=Host then Exit Sub ElseIf not IsOp(Nickname,words(0),ServerNumber) or not IsOp(Getidentifier("$me",ServerNumber),words(0),ServerNumber) then SendCommand "/notice " & nickname & " Setup error: We must both be opped! Make sure I have at least 400 power with ChanServ.",ServerNumber ElseIf Not IsOp(ChanServ,words(0),ServerNumber) then SendCommand "/msg " & Channel & " Error: I require the use of ChanServ to satisfy networking issues.",ServerNumber Elseif Mid(Message,Len(Words(0)) + Len(words(0)) -- 3)="" then Sendcommand "/notice " & Nickname & " Please state a password to use",ServerNumber Elseif not Len(Words(2)) > "5" then Sendcommand "/notice " & Nickname & " Error, please use a password that is 6 characters long or longer!",ServerNumber Else SendCommand "/timer setb off",ServerNumber Pass="" Setup="" WriteIniFile"Settings.txt","Settings","Channel",words(0) WriteIniFile"Settings.txt","Settings","Pass",words(2) WriteIniFile"Settings.txt","Settings","Bhost",GetIdentifier("$mask($nick(" & words(0) & ",$me).mask,2)",ServerNumber) writeIniFile"Settings.txt","Settings","Users","0" Bhost = GetIdentifier("$mask($nick(" & words(0) & ",$me).mask,2)",ServerNumber) WriteIniFile"" & words(0) & ".txt","Register","Allowed","Yes" writeIniFile"" & words(0) & ".txt","op","Set","1" writeIniFile"" & words(0) & ".txt","DCC","Allowed","2" WriteIniFile"" & words(0) & ".txt","Topic","Ident","Welcome to " & words(0) & " ||" WriteIniFile"" & words(0) & ".txt","Topic","Topic","" WriteIniFile"" & words(0) & ".txt","Topic","Lock","Off" Writeinifile"" & words(0) & ".txt","Joinmsg","Msg","Welcome back!" WriteIniFile"" & words(0) & ".txt","Allowpm","Set","Yes" WriteIniFile"" & words(0) & ".txt","Spam","Nospam","Off" WriteIniFile"" & words(0) & ".txt","Spam","Message","0" WriteIniFile"" & words(0) & ".txt","Spam","Num","4" WriteIniFile"" & words(0) & ".txt","Spam","Ops","On" WriteIniFile"" & words(0) & ".txt",Bhost,"Nick",Getidentifier("$me",ServerNumber) WriteIniFile"" & words(0) & ".txt",Bhost,"Host",Bhost WriteIniFile"" & words(0) & ".txt",Bhost,"Mod","Yes" WriteIniFile"" & words(0) & ".txt",Bhost,"Admin","Yes" WriteIniFile"" & words(0) & ".txt",Bhost,"Protect","Yes" WriteIniFile"" & words(0) & ".txt",Bhost,"Join","Bot Reactivated" WriteIniFile"" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber),"Nick", Nickname WriteIniFile"" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber),"Host", GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber) WriteIniFile"" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber),"Mod","Yes" WriteIniFile"" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber),"Admin","Yes" WriteIniFile"" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber),"Protect","Yes" WriteIniFile"" & words(0) & ".txt",GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber),"Nick",""),"Host",GetIdentifier("$mask($nick(" & words(0) & "," & Nickname & ").mask,2)",ServerNumber) SendCommand "/msg " & words(0) & " You are now registered as " & Nickname & " $mask($nick(" & words(0) & "," & Nickname & ").mask,2) ",ServerNumber End If Case "admin" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" then If GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Nick","")="" and GetIniFile("" & Words(0) & ".txt",Words(2),"Host","")="" then SendCommand "/notice " & Nickname & " User " & Words(2) & " does not exist",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Admin","")="Yes" or GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Admin","")="Yes" then SendCommand "/notice " & Nickname & " " & Words(2) & " Already has admin",ServerNumber ElseIf Left(GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Host",""),1)="s" or Left(GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " " & Words(2) & " is suspended!",ServerNumber ElseIf not GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Host","")="" then If GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Mod","")="No" then WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Mod","Yes" End If WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Admin","Yes" If not GetIniFile("" & Words(0) & ".txt","op","Set","")="0" then SendCommand "/mode " & Words(0) & " +o " & Words(2) & "",ServerNumber End If SendCommand "/notice " & Nickname & " " & Words(2) & " Now has admin",ServerNumber Else If GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Mod","")="No" then WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Mod","Yes" End If WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Admin","Yes" If not GetIniFile("" & Words(0) & ".txt","op","Set","")="0" then SendCommand "/mode " & Words(0) & " +o " & Words(2) & "",ServerNumber End If SendCommand "/notice " & Nickname & " " & Words(2) & " Now has admin",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End If Case "deadmin" If GetIniFile("" & Words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" then If GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Nick","")="" and GetIniFile("" & Words(0) & ".txt",Words(2),"Host","")="" then SendCommand "/notice " & Nickname & " User " & Words(2) & " does not exist",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Protect","")="Yes" or GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " " & Words(2) & " is protected!",ServerNumber ElseIf GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Admin","")="No" or GetIniFile("" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Admin","")="No" then SendCommand "/notice " & Nickname & " " & Words(2) & " Does not have admin",ServerNumber ElseIf not GetIniFile("" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Host","")="" then WriteIniFile"" & Words(0) & ".txt",GetIdentifier("$mask($nick(" & Words(0) & "," & Words(2) & ").mask,2)",ServerNumber),"Admin","No" If not GetIniFile("" & Words(0) & ".txt","op","Set","")="2" then SendCommand "/mode " & Words(0) & " -o " & Words(2) & "",ServerNumber End if SendCommand "/mode " & Words(0) & " +v " & Words(2) & "",ServerNumber SendCommand "/notice " & Nickname & " " & Words(2) & " No longer has admin",ServerNumber Else WriteIniFile"" & Words(0) & ".txt",GetIniFile("" & Words(0) & ".txt",Words(2),"Host",""),"Admin","No" SendCommand "/mode " & Words(0) & " -o " & Words(2) & "",ServerNumber SendCommand "/mode " & Words(0) & " +v " & Words(2) & "",ServerNumber SendCommand "/notice " & Nickname & " " & Words(2) & " No longer has admin",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End if Case "deluser" If GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") ="Yes" then If Mid(Message,Len(Words(0)) + Len(words(1)) -- 3)="" then Sendcommand "/notice " & Nickname & " Error: Please state a host or nickname to delete!",ServerNumber ElseIf Left(words(2),3)="*!*" then If GetIniFile("" & words(0) & ".txt",words(2),"Admin","")="" then SendCommand "/Notice " & Nickname & " Host " & words(2) & " does not direct to any user profile!",ServerNumber ElseIf GetIniFile("" & words(0) & ".txt",words(2),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: This user is protected!",ServerNumber ElseIf GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Special","")="S" then SendCommand "/notice " & Nickname & " Sorry, you are restricted from using this command!",ServerNumber ElseIf Left(GetIniFile("" & words(0) & ".txt",words(2),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " Error: This user is suspended!",ServerNumber Elseif not GetIniFile("" & words(0) & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" and GetIniFile("" & words(0) & ".txt",words(2),"Admin","")="Yes" then Sendcommand "/notice " & Nickname & " Error: You cannot delete other admins!",ServerNumber Else SendCommand "/Notice " & Nickname & " " & GetIniFile("" & words(0) & ".txt",words(2),"Nick","") & " has been unregistered!",ServerNumber WriteIniFile"" & words(0) & ".txt",GetIniFile("" & words(0) & ".txt",words(2),"Nick",""),"Host","" WriteIniFile"" & words(0) & ".txt",words(2),"Nick", "Unregistered on " & Date & "" WriteIniFile"" & words(0) & ".txt",words(2),"Host", "Unregistered by " & Host & "" WriteIniFile"" & words(0) & ".txt",words(2),"Mod","" WriteIniFile"" & words(0) & ".txt",words(2),"Admin","" WriteIniFile"" & words(0) & ".txt",words(2),"Protect","" WriteIniFile"" & words(0) & ".txt",words(2),"Join","" WriteIniFile"" & words(0) & ".txt",words(2),"Note","" WriteIniFile"" & words(0) & ".txt",words(2),"Seen","" writeinifile"" & words(0) & ".txt",words(2),"Op","" WriteIniFile"" & words(0) & ".txt",words(2),"Special","" End If ElseIf GetIniFile("" & words(0) & ".txt",words(2),"Host","")="" and GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host","")="" then SendCommand "/Notice " & Nickname & " User " & words(2) & " does not exist",ServerNumber Else If GetIniFile("" & words(0) & ".txt",GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host",""),"Admin","")="" then SendCommand "/notice " & Nickname & " Please state " & GetIniFile("" & words(0) & ".txt",GetIniFile("" & words(0) & ".txt",words(2),"Host",""),"Nick","") & "'s log to deluser: (" & Tool & "Deluser " & GetIniFile("" & words(0) & ".txt",GetIniFile("" & words(0) & ".txt",words(2),"Host",""),"Host","") & ") ",ServerNumber Else SendCommand "/Notice " & Nickname & " Please state " & GetIniFile("" & words(0) & ".txt",GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host",""),"Nick","") & "'s log to deluser: (" & Tool & "Deluser " & GetIniFile("" & words(0) & ".txt",GetIniFile("" & words(0) & ".txt",GetIdentifier("$mask($nick(" & words(0) & "," & words(2) & ").mask,2)",ServerNumber),"Host",""),"Host","") & ") ",ServerNumber End If End If Else SendCommand "/notice " & Nickname & " Error: Not a channel admin!",ServerNumber End If End Select End If End Sub Sub ONJOIN(Nickname,Host,Channel,ServerNumber) If Nickname=GetIdentifier("$me",ServerNumber) then if not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","")="" then SendCommand "/timer " & Channel & "" & Nickname & " 1 1 /msg " & Channel & " " & Nickname & ": " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","") & "",ServerNumber End If Exit Sub End if If Channel=Left(Setup,6) and Pass = "1" then If GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber)=Snick then SendCommand "/timer rsjh 1 1 /msg " & Channel & " Please state your new channel by " & Tool & "new <#channel> and without the <>. Make sure I have at least 400 clvl with chanserv first!",ServerNumber Pass="3" End If ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","")="Yes" then If not getinifile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Op","")="Off" and not GetIniFile("" & Channel & ".txt","op","Set","")="0" then SendCommand "/mode " & Channel & " +o " & Nickname & "",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" and not getinifile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Op","")="Off" then SendCommand "/mode " & Channel & " +o " & Nickname & "",ServerNumber Else SendCommand "/mode " & Channel & " +v " & Nickname & "",ServerNumber End If If Left(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join",""),1)="&" then SendCommand "/notice " & Nickname & " " & Nickname & ", your join information was cleared by " & Mid(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join",""),3) & "",ServerNumber WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","" ElseIf not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","")="" and not Lcase(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join",""))="off" then SendCommand "/timer " & Channel & "" & Nickname & " 1 1 /msg " & Channel & " " & Nickname & ": " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","") & "",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","")="" and not Lcase(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join",""))="off" and not Getinifile("" & Channel & ".txt","Joinmsg","Msg","")="&" then SendCommand "/notice " & Nickname & " " & Channel & ": " & Getinifile("" & Channel & ".txt","Joinmsg","Msg","") & "",ServerNumber End If WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Seen",Date ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","")="Yes" then If not getinifile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Op","")="Off" and GetIniFile("" & Channel & ".txt","op","Set","")="2" then SendCommand "/mode " & Channel & " +o " & Nickname & "",ServerNumber Else SendCommand "/mode " & Channel & " +v " & Nickname & "",ServerNumber End If If Left(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join",""),1)="&" then SendCommand "/notice " & Nickname & " " & Nickname & ", your join information was cleared by " & Mid(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join",""),3) & "",ServerNumber WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","" ElseIf not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","")="" and not Lcase(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join",""))="off" then SendCommand "/timer " & Channel & "" & Nickname & " 1 1 /msg " & Channel & " " & Nickname & ": " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","") & "",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","")="" and not Lcase(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join",""))="off" and not Getinifile("" & Channel & ".txt","Joinmsg","Msg","")="&" then SendCommand "/notice " & Nickname & " " & Channel & ": " & Getinifile("" & Channel & ".txt","Joinmsg","Msg","") & "",ServerNumber End If WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Seen",Date ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then SendCommand "/mode " & Channel & " +v " & Nickname & "",ServerNumber If Left(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join",""),1)="&" then SendCommand "/notice " & Nickname & " " & Nickname & ", your join information was cleared by " & Mid(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join",""),3) & "",ServerNumber WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","" ElseIf not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","")="" and not Lcase(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join",""))="off" then SendCommand "/timer " & Channel & "" & Nickname & " 1 1 /msg " & Channel & " " & Nickname & ": " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","") & "",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","")="" and not Lcase(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join",""))="off" and not Getinifile("" & Channel & ".txt","Joinmsg","Msg","")="&" then SendCommand "/notice " & Nickname & " " & Channel & ": " & Getinifile("" & Channel & ".txt","Joinmsg","Msg","") & "",ServerNumber End If WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Seen",Date ElseIf not Getinifile("" & Channel & ".txt","Joinmsg","Msg","")="&" and not getIniFile("" & Channel & ".txt","Register","Allowed","")="" then SendCommand "/notice " & Nickname & " " & Channel & ": " & Getinifile("" & Channel & ".txt","Joinmsg","Msg","") & "",ServerNumber ElseIf getIniFile("" & Channel & ".txt","Register","Allowed","")="" then 'SendCommand "/timer " & Channel & "1 1 1 /msg " & Channel & " " & GetIdentifier("$randphrase(hello.txt)",ServerNumber) & "",ServerNumber End If If not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Note","")="" then SendCommand "/timer notice 1 2 /notice " & Nickname & " Your note: " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Note","") & "",ServerNumber End If If not Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Checked","")="1" then Notemem="0" Scount="" Unote="0" Do while not Notemem > 50 Notemem = Notemem -- 1 If not Notemem > 50 then If not Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Notemem,"")="" then If Left(Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Notemem,""),1)="&" then Unote = Unote -- 1 Scount = Scount + ", *" & Notemem & "" End If End If Elseif not Unote="0" then Sendcommand "/timer " & Channel & "N" & Nickname & " 1 2 /notice " & Nickname & " You have " & Unote & " unread message(s) marked with * on " & Mid(Scount,2) & "",ServerNumber Writeinifile"Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Checked","1" NCRhost = GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) Sendcommand "/timer " & Channel & "N1c" & Nickname & " 1 180 /! Mnote " & NCRhost & "",ServerNumber End If Loop End If End Sub Sub MNote(NCRhost) Writeinifile"Note.txt",NCRhost,"Checked","0" End Sub Sub FixNick(Nickname) Writeinifile"Spammers.txt","Count",Nickname,"0" End Sub Sub ONTEXT(Message,Channel,Nickname,Host,ServerNumber) If not Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Checked","")="1" then Notemem="0" Scount="" Unote="0" Do while not Notemem > 50 Notemem = Notemem -- 1 If not Notemem > 50 then If not Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Notemem,"")="" then If Left(Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Notemem,""),1)="&" then Unote = Unote -- 1 Scount = Scount + ", *" & Notemem & "" End If End If Elseif not Unote="0" then Sendcommand "/notice " & Nickname & " You have " & Unote & " unread message(s) marked with * on " & Mid(Scount,2) & "",ServerNumber Writeinifile"Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Checked","1" NCRhost = GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) Sendcommand "/timer " & Channel & "N1c" & Nickname & " 1 180 /! Mnote " & NCRhost & "",ServerNumber End If Loop End If words = split(message," ") Num = "0" Thumb = "" SPcount = Len(Nickname) Do while not Num = SPcount -- 1 Num = Num -- 1 If not Mid(Left(Nickname,Num -- 0),Num -- 0)="|" and Not Mid(Left(Nickname,Num -- 0),Num -- 0)="[" and Not Mid(Left(Nickname,Num -- 0),Num -- 0)="]" and not Mid(Left(Nickname,Num -- 0),Num -- 0)="" then Thumb = Thumb + "" & Mid(Left(Nickname,Num -- 0),Num -- 0) & "" ElseIf Mid(Left(Nickname,Num -- 0),Num -- 0)="" then End If Loop If GetIniFile("Spammers.txt","Count",Thumb,"")="" then Writeinifile"Spammers.txt","Count",Thumb,"0" End If If GetIniFile("" & Channel & ".txt","Spam","Nospam","")="On" then If GetIniFile("" & Channel & ".txt","Spam","Ops","")="Off" and IsOp(Nickname,Channel,ServerNumber) then If GetIniFile("Spammers.txt","Count",Thumb,"")>"1" then Sendcommand "/ignore " & Thumb & "",ServerNumber Sendcommand "/timer " & Thumb & "1 1 30 /ignore " & Thumb & "",ServerNumber Writeinifile"Spammers.txt","Count",Thumb,"0" Sendcommand "/timer " & Thumb & " off" Exit Sub Else Writeinifile"Spammers.txt","Count",Thumb,GetIniFile("Spammers.txt","Count",Thumb,"") -- 1 Sendcommand "/timer " & Thumb & " off" Sendcommand "/timer " & Thumb & " 1 2 /! FixNick " & Thumb & "",ServerNumber End If ElseIf GetIniFile("Spammers.txt","Count",Thumb,"") - GetIniFile("" & Channel & ".txt","Spam","Message","")="2" or GetIniFile("Spammers.txt","Count",Thumb,"") - GetIniFile("" & Channel & ".txt","Spam","Message","")="3" then Sendcommand "/notice " & Nickname & " Please stop sending messages so fast",ServerNumber Writeinifile"Spammers.txt","Count",Thumb,GetIniFile("Spammers.txt","Count",Thumb,"") -- 1 Sendcommand "/timer " & Thumb & " off" Sendcommand "/timer " & Thumb & " 1 " & GetIniFile("" & Channel & ".txt","Spam","Num","") & " /! FixNick " & Thumb & "",ServerNumber ElseIf GetIniFile("Spammers.txt","Count",Thumb,"") - GetIniFile("" & Channel & ".txt","Spam","Message","")>"3" then Writeinifile"Spammers.txt","Count",Thumb,"0" Sendcommand "/kick " & Channel & " " & Nickname & " Spamming is against the channel rules",ServerNumber Sendcommand "/timer " & Thumb & " off" Exit Sub Else Writeinifile"Spammers.txt","Count",Thumb,GetIniFile("Spammers.txt","Count",Thumb,"") -- 1 Sendcommand "/timer " & Thumb & " off" Sendcommand "/timer " & Thumb & " 1 " & GetIniFile("" & Channel & ".txt","Spam","Num","") & " /! FixNick " & Thumb & "",ServerNumber End If ElseIf GetIniFile("Spammers.txt","Count",Thumb,"")>"1" then Sendcommand "/ignore " & Thumb & "",ServerNumber Sendcommand "/timer " & Thumb & "1 1 30 /ignore " & Thumb & "",ServerNumber Writeinifile"Spammers.txt","Count",Thumb,"0" Sendcommand "/timer " & Thumb & " off" Else Writeinifile"Spammers.txt","Count",Thumb,GetIniFile("Spammers.txt","Count",Thumb,"") -- 1 Sendcommand "/timer " & Thumb & " off" Sendcommand "/timer " & Thumb & " 1 2 /! FixNick " & Thumb & "",ServerNumber End If If Lcase(Words(0))="&toolreset" then If not GetIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" or not channel=Getinifile("Settings.txt","Settings","Channel","") then Sendcommand "/notice " & Nickname & " Error: No permission!",ServerNumber Elseif Tool = "&" then Sendcommand "/notice " & Nickname & " Error: You already have this as your current tool!",ServerNumber Else Tool = "&" Sendcommand "/notice " & Nickname & " Success: Your new tool is " & Tool & "",ServerNumber End If End If If Left(Message,1) = Tool Then Select Case Replace(LCase(words(0)),Tool,"") Case "spam" If Not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","")="Yes" then Sendcommand "/notice " & Nickname & " Error: No permission!",ServerNumber ElseIf Lcase(words(1))="count" then If not Words(2)>4 or not Words(2)<10 then Sendcommand "/notice " & Nickname & " Error: Please set your kick number between 5 and 9 messages",ServerNumber Else WriteIniFile"" & Channel & ".txt","Spam","Message",words(2) - 5 Sendcommand "/notice " & Nickname & " Users will now be kicked for sending " & Words(2) & " messages in " & GetIniFile("" & Channel & ".txt","Spam","Num","") & " Seconds",ServerNumber End If ElseIf Lcase(words(1))="time" then If Not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","")="Yes" then ElseIf not Words(2)>1 or not Words(2)<10 then Sendcommand "/notice " & Nickname & " Error: Please set your kick time reset between 2 and 6 seconds",ServerNumber Else WriteIniFile"" & Channel & ".txt","Spam","Num",words(2) Sendcommand "/notice " & Nickname & " Users will now be kicked for sending " & GetIniFile("" & Channel & ".txt","Spam","Message","") -- 5 & " messages in " & words(2) & " seconds",ServerNumber End If ElseIf Lcase(words(1))="info" then If GetIniFile("" & Channel & ".txt","Spam","Nospam","")="On" then If GetIniFile("" & Channel & ".txt","Spam","Ops","")="On" then Sendcommand "/notice " & Nickname & " Spam detection is enabled: All users will be kicked for sending " & GetIniFile("" & Channel & ".txt","Spam","Message","") -- 5 & " messages in " & GetIniFile("" & Channel & ".txt","Spam","Num","") & " seconds",ServerNumber Else Sendcommand "/notice " & Nickname & " Spam detection is enabled: Users excluding ops will be kicked for sending " & GetIniFile("" & Channel & ".txt","Spam","Message","") -- 5 & " messages in " & GetIniFile("" & Channel & ".txt","Spam","Num","") & " seconds",ServerNumber End If Else Sendcommand "/notice " & Nickname & " Spam detection is currently off. You can enable this feature by " & Tool & "Spam Set On",ServerNumber End If ElseIf Lcase(words(1))="set" then If Lcase(words(2))="on" then If GetIniFile("" & Channel & ".txt","Spam","Nospam","")="On" then Sendcommand "/notice " & Nickname & " Error: Already enabled!",ServerNumber Else WriteIniFile"" & Channel & ".txt","Spam","Nospam","On" Sendcommand "/notice " & Nickname & " Spam detection now enabled!",ServerNumber End If ElseIf Lcase(words(2))="off" then If GetIniFile("" & Channel & ".txt","Spam","Nospam","")="Off" then Sendcommand "/notice " & Nickname & " Error: Already disabled!",ServerNumber Else WriteIniFile"" & Channel & ".txt","Spam","Nospam","Off" Sendcommand "/notice " & Nickname & " Spam detection now disabled!",ServerNumber End If End If ElseIf Lcase(words(1))="opdetect" then If Lcase(words(2))="on" then If GetIniFile("" & Channel & ".txt","Spam","Ops","")="On" then Sendcommand "/notice " & Nickname & " Error: Already enabled!",ServerNumber Else WriteIniFile"" & Channel & ".txt","Spam","Ops","On" Sendcommand "/notice " & Nickname & " Spam detection for ops now enabled!",ServerNumber End If ElseIf Lcase(words(2))="off" then If GetIniFile("" & Channel & ".txt","Spam","Ops","")="Off" then Sendcommand "/notice " & Nickname & " Error: Already disabled!",ServerNumber Else WriteIniFile"" & Channel & ".txt","Spam","Ops","Off" Sendcommand "/notice " & Nickname & " Spam detection for ops now disabled!",ServerNumber End If End If End If Case "newchan" If not Getinifile("Settings.txt","Settings","Channel","")="" and Mid(Message,10)="" and GetIniFile("" & Getinifile("Settings.txt","Settings","Channel","") & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" and Channel=Getinifile("Settings.txt","Settings","Channel","") then SendCommand "/notice " & nickname & " Correct syntax is " & Tool & "Newchan ",ServerNumber ElseIf Getinifile("Settings.txt","Settings","Channel","")="" and Pass="" and Lcase(Mid(Message,10))="" then Pass="5" Setup=Host SendCommand "/timer setb 1 500 /! OnSetup",ServerNumber SendCommand "/notice " & Nickname & " Welcome to authscript! Thank you for using a script packed with features to keep you in control of your channel opposed to other bots.",ServerNumber SendCommand "/timer set1 1 5 /notice " & Nickname & " This is the setup wizard which will put your bot into service within moments of your time.",ServerNumber SendCommand "/timer set2 1 10 /notice " & Nickname & " Lets get started with a quick tutorial. &Help will be your most useful command.",ServerNumber SendCommand "/timer set3 1 15 /notice " & Nickname & " Use it to get a description of the channel commands you can use and to get information on what other commands do.",ServerNumber SendCommand "/timer set4 1 20 /notice " & Nickname & " Syntax for additional info is used as &Help Command.",ServerNumber SendCommand "/timer set5 1 25 /notice " & Nickname & " Adding a new channel to your bot control list is an easy &Newchan .",ServerNumber SendCommand "/timer set6 1 30 /notice " & Nickname & " To unregister a channel, simply delete the created txt file in your default file location.",ServerNumber SendCommand "/timer set7 1 35 /notice " & Nickname & " Don't forget that when you add a new channel, you must add that channel to your bot's autojoin list!",ServerNumber SendCommand "/timer set8 1 40 /notice " & Nickname & " As bot owner, you get to set a password in which you can use to gain bot control in any channel via &Override",ServerNumber SendCommand "/timer set9 1 45 /notice " & Nickname & " There are three types of override, 1 gives admin and 2 gives protection, use &Help for the third. Syntax is &Override .",ServerNumber SendCommand "/timer set10 1 50 /notice " & Nickname & " Override is a PM only command. However the command will only work for you, the main channel owner.",ServerNumber SendCommand "/timer set11 1 55 /notice " & Nickname & " Lets set up your password now. Remember that the channel you enter is what I will use for your main channel.",ServerNumber SendCommand "/timer set13 1 60 /notice " & Nickname & " Please /msg " & Getidentifier("$me",ServerNumber) & " <#Channel> &Pass replacing the brackets with your info",ServerNumber SendCommand "/timer set12 1 65 /notice " & Nickname & " Remember that you can change this pass at any time in your settings.txt file.",ServerNumber ElseIf Getinifile("Settings.txt","Settings","Channel","")="" then SendCommand "/msg " & Channel & " Sorry, authscript is not set up yet",ServerNumber ElseIf Not Mid(Message,10)="" and channel=Getinifile("Settings.txt","Settings","Channel","") and GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" then If not Snick="" or not Setup="" or not Pass="" then SendCommand "/notice " & Nickname & " Error: This service is currently busy. Please try again in 30 seconds",ServerNumber ElseIf not GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber)="$null" then SendCommand "/msg " & Channel & " Please wait...",ServerNumber Setup= "#r" & GetIdentifier("$rnd(1000,9999)",ServerNumber) & " " & GetIdentifier("$rnd(1000,9999)",ServerNumber) & "" Pass="1" SendCommand "/join " & Left(Setup,6) & "",ServerNumber Snick= GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber) SendCommand "/timer dsg 1 2 /mode " & Left(Setup,6) & " +k " & Mid(Setup,8) & "",ServerNumber SendCommand "/timer nchan 1 300 /! OnNewchan",ServerNumber SendCommand "/timer nchan2 1 300 /part " & Left(Setup,6) & "",ServerNumber SendCommand "/timer nchan3 1 300 /part " & Pass & "",ServerNumber SendCommand "/timer djfry 1 3 /notice " & Mid(Message,10) & " Please /join " & Setup & " and know that you have 5 minutes to complete this task",ServerNumber Else SendCommand "/notice " & Nickname & " Please state an active new owner!",ServerNumber End If End If Case "cancel" If Channel = Left(Setup,6) then If GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber)=Snick then SendCommand "/part " & Pass & "" SendCommand "/part " & Left(Setup,6) & "",ServerNumber Snick="" Setup="" Pass="" SendCommand "/timer nchan off" SendCommand "/timer nchan3 off" SendCommand "/timer nchan2 off" End If End If Case "new" If Channel = Left(Setup,6) and Pass = "3" then If Getinifile("" & Words(1) & ".txt","Register","Allowed","")="" then If not Words(1) = "" then Pass = Mid(Message,6) SendCommand "/join " & words(1) & "" SendCommand "/msg " & Left(Setup,6) & " Please restate to confirm (" & Tool & "use " & Pass & ") or you can say " & Tool & "retry. I should have joined your channel just now",ServerNumber Else SendCommand "/msg " & Left(Setup,6) & " Please use a space for your channel",ServerNumber End If Else SendCommand "/msg " & Left(Setup,6) & " Sorry, this channel is already registered.",ServerNumber End If End If Case "retry" If Channel = Left(Setup,6) and not Pass="3" then SendCommand "/part " & Pass & "" Pass = "3" SendCommand "/msg " & Left(Setup,6) & " Please state your new channel using " & Tool & "new <#channel>. Make sure that you have chanserv and that I get auto op before continuing!",ServerNumber End If Case "use" If Channel = Left(Setup,6) and Pass = Mid(Message,6) then If Not IsOp(Getidentifier("$me",ServerNumber),words(1),ServerNumber) then SendCommand "/notice " & Nickname & " Error: I'm not a channel op! Please !adduser " & Getidentifier("$me",ServerNumber) & " 400.",ServerNumber ElseIf Not IsOp(Nickname,words(1),ServerNumber) or GetIdentifier("$mask($nick(" & words(1) & "," & Nickname & ").mask,2)",ServerNumber)="$null" then SendCommand "/notice " & Nickname & " Error: Your not a channel op! Please claim op status.",ServerNumber Else WriteIniFile"" & words(1) & ".txt","Register","Allowed","Yes" writeIniFile"" & words(1) & ".txt","op","Set","1" WriteIniFile"" & words(1) & ".txt","Topic","Ident","Welcome to " & words(1) & " ||" WriteIniFile"" & words(1) & ".txt","Topic","Topic","" WriteIniFile"" & words(1) & ".txt","Topic","Lock","Off" writeIniFile"" & words(1) & ".txt","DCC","Allowed","2" Writeinifile"" & words(1) & ".txt","Joinmsg","Msg","Welcome back!" WriteIniFile"" & words(1) & ".txt","Allowpm","Set","Yes" WriteIniFile"" & words(1) & ".txt","Spam","Nospam","Off" WriteIniFile"" & words(1) & ".txt","Spam","Message","0" WriteIniFile"" & Words(1) & ".txt","Spam","Num","4" WriteIniFile"" & words(1) & ".txt","Spam","Ops","On" WriteIniFile"" & words(1) & ".txt",Getinifile("Settings.txt","Settings","Bhost",""),"Nick",GetIdentifier("$me",ServerNumber) WriteIniFile"" & words(1) & ".txt",Getinifile("Settings.txt","Settings","Bhost",""),"Host",Getinifile("Settings.txt","Settings","Bhost","") WriteIniFile"" & words(1) & ".txt",Getinifile("Settings.txt","Settings","Bhost",""),"Mod","Yes" WriteIniFile"" & words(1) & ".txt",Getinifile("Settings.txt","Settings","Bhost",""),"Admin","Yes" WriteIniFile"" & words(1) & ".txt",Getinifile("Settings.txt","Settings","Bhost",""),"Protect","Yes" WriteIniFile"" & words(1) & ".txt",Getinifile("Settings.txt","Settings","Bhost",""),"Join","Bot Reactivated" SendCommand "/msg " & Left(Setup,6) & " Your channel is now ready to go. Enjoy!",ServerNumber SendCommand "/timer wergwe 1 1 /part " & Left(Setup,6) & "",ServerNumber Snick="" Setup="" Pass="" SendCommand "/timer nchan off" SendCommand "/timer nchan3 off" SendCommand "/timer nchan2 off" WriteIniFile"" & words(1) & ".txt",GetIdentifier("$mask($nick(" & words(1) & "," & Nickname & ").mask,2)",ServerNumber),"Nick", Nickname WriteIniFile"" & words(1) & ".txt",GetIdentifier("$mask($nick(" & words(1) & "," & Nickname & ").mask,2)",ServerNumber),"Host", GetIdentifier("$mask($nick(" & words(1) & "," & Nickname & ").mask,2)",ServerNumber) WriteIniFile"" & words(1) & ".txt",GetIdentifier("$mask($nick(" & words(1) & "," & Nickname & ").mask,2)",ServerNumber),"Mod","Yes" WriteIniFile"" & words(1) & ".txt",GetIdentifier("$mask($nick(" & words(1) & "," & Nickname & ").mask,2)",ServerNumber),"Admin","Yes" WriteIniFile"" & words(1) & ".txt",GetIdentifier("$mask($nick(" & words(1) & "," & Nickname & ").mask,2)",ServerNumber),"Protect","Yes" WriteIniFile"" & words(1) & ".txt",GetIniFile("" & words(1) & ".txt",GetIdentifier("$mask($nick(" & words(1) & "," & Nickname & ").mask,2)",ServerNumber),"Nick",""),"Host",GetIdentifier("$mask($nick(" & words(1) & "," & Nickname & ").mask,2)",ServerNumber) Tutorial=Host SendCommand "/timer tutorial 1 30 /! OnTutorial",Servernumber SendCommand "/msg " & words(1) & " You are now registered as " & Nickname & " $mask($nick(" & words(1) & "," & Nickname & ").mask,2) ",ServerNumber SendCommand "/timer asktutorial 1 1 /msg " & words(1) & " " & Nickname & ": Would you like to take a tutorial? (" & Tool & "Yes," & Tool & "No)",ServerNumber End If End If Case "chaninfo" If GetIniFile("" & channel & ".txt","DCC","Allowed","")="0" then dchk="Channel Owner" ElseIf GetIniFile("" & channel & ".txt","DCC","Allowed","")="1" then dchk="Admins" ElseIf GetIniFile("" & channel & ".txt","DCC","Allowed","")="2" then dchk="Moderators" ElseIf GetIniFile("" & channel & ".txt","DCC","Allowed","")="3" then dchk="Registered Users" End If SendCommand "/notice " & Nickname & " Allow automatic registration: " & Getinifile("" & Channel & ".txt","Register","Allowed","") & " ; Locked topic: " & Getinifile("" & Channel & ".txt","Topic","Lock","") & " ; Op mode: " & GetIniFile("" & Channel & ".txt","op","Set","") & " ; Userlist Availability: " & dchk & " ; PM commands: " & Getinifile("" & Channel & ".txt","Allowpm","Set","") & "",ServerNumber SendCommand "/notice " & Nickname & " Default topic: " & Getinifile("" & Channel & ".txt","Topic","Ident","") & " Real topic: " & Getinifile("" & Channel & ".txt","Topic","Topic","") & "",ServerNumber If Getinifile("" & Channel & ".txt","Joinmsg","Msg","")="" then SendCommand "/notice " & Nickname & " Greet message: Welcome back (Default) ",ServerNumber ElseIf Getinifile("" & Channel & ".txt","Joinmsg","Msg","")="&" then SendCommand "/notice " & Nickname & " Greet message is disabled",ServerNumber Else SendCommand "/notice " & Nickname & " Greet Message: " & Getinifile("" & Channel & ".txt","Joinmsg","Msg","") & "",ServerNumber End If Case "botinfo" If GetIniFile("" & channel & ".txt",GetIdentifier("$mask($nick(" & channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & channel & "," & Nickname & ").mask,2)",ServerNumber) then If Getinifile("Settings.txt","Settings","Users","")="1" then list="In Chat" Else list="DCC" End If Sendcommand "/notice " & Nickname & " Main Channel: " & Getinifile("Settings.txt","Settings","Channel","") & " - Registered bot host: " & Getinifile("Settings.txt","Settings","Bhost","") & " - Userlist Download Type: " & list & "",ServerNumber Else Sendcommand "/notice " & nickname & " Error: Not registered!",ServerNumber End If Case "tool" If not GetIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" or not channel=Getinifile("Settings.txt","Settings","Channel","") then Sendcommand "/notice " & Nickname & " Error: No permission!",ServerNumber ElseIf not Mid(Message,8)="" then Sendcommand "/notice " & Nickname & " Error: Please only use a single character tool!",ServerNumber Elseif Tool = words(1) then Sendcommand "/notice " & Nickname & " Error: You already have this as your current tool!",ServerNumber Else Tool = Lcase(words(1)) Sendcommand "/notice " & Nickname & " Success: Your new tool is " & Tool & "",ServerNumber End If Case "help" If mid(Message,6)="" then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","")="" then SendCommand "/notice " & Nickname & " Your commands are: " & Tool & "Register, " & Tool & "Chaninfo, " & Tool & "Help, " & Tool & "Botinfo",ServerNumber ElseIf Left(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " Your commands are: " & Tool & "Chaninfo, " & Tool & "Help, " & Tool & "Unregister, " & Tool & "Botinfo",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","")="No" then SendCommand "/notice " & Nickname & " Your commands are: " & Tool & "Up, " & Tool & "Down, " & Tool & "Me, " & Tool & "User, " & Tool & "Users, " & Tool & "Setinfo, " & Tool & "Update, " & Tool & "Note, " & Tool & "Chaninfo, " & Tool & "Seen, " & Tool & "Help, " & Tool & "Unregister, " & Tool & "Snuggle, " & Tool & "Message, " & Tool & "Botinfo",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","")="Yes" and GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","")="No" then SendCommand "/notice " & Nickname & " Your commands are: " & Tool & "Up, " & Tool & "Down, " & Tool & "Voice, " & Tool & "Devoice, " & Tool & "Me, " & Tool & "User, " & Tool & "Users, " & Tool & "Kick, " & Tool & "Ban, " & Tool & "Unban, " & Tool & "Undoban, " & Tool & "Setinfo, " & Tool & "Topic, " & Tool & "Trefresh, " & Tool & "Greet, " & Tool & "Update, " & Tool & "Note, " & Tool & "Chaninfo, " & Tool & "Seen, " & Tool & "Help, " & Tool & "Unregister, " & Tool & "Snuggle, " & Tool & "Fix, " & Tool & "Sync, " & Tool & "Message, " & Tool & "Botinfo",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","")="Yes" then SendCommand "/notice " & Nickname & " Your commands are: " & Tool & "Up, " & Tool & "Down, " & Tool & "Voice, " & Tool & "Devoice, " & Tool & "Me, " & Tool & "User, " & Tool & "Users, " & Tool & "Kick, " & Tool & "Ban, " & Tool & "Unban, " & Tool & "Undoban, " & Tool & "Setinfo, " & Tool & "Topic, " & Tool & "Trefresh, " & Tool & "Greet, " & Tool & "Update, " & Tool & "Note, " & Tool & "Chaninfo, " & Tool & "Seen, " & Tool & "Help, " & Tool & "Unregister, " & Tool & "Snuggle, " & Tool & "Fix, " & Tool & "Sync, " & Tool & "Message, " & Tool & "Botinfo",ServerNumber SendCommand "/notice " & Nickname & " Admin commands: " & Tool & "Deluser, " & Tool & "Op, " & Tool & "Deop, " & Tool & "Moderate, " & Tool & "Demoderate, " & Tool & "Clearinfo, " & Tool & "Infolock, " & Tool & "Suspend, " & Tool & "Unsuspend, " & Tool & "Spam",ServerNumber If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" then If Channel=Getinifile("Settings.txt","Settings","Channel","") then SendCommand "/notice " & Nickname & " Special Commands: " & Tool & "Override (Via PM), " & Tool & "Newchan , " & Tool & "Admin, " & Tool & "Deadmin, " & Tool & "Dtopic, " & Tool & "Setop, " & Tool & "Registration, " & Tool & "Addban, " & Tool & "Delban, " & Tool & "Restrict, " & Tool & "Unrestrict, " & Tool & "Move, " & Tool & "Flip, " & Tool & "Tool, " & Tool & "Allowpm, " & Tool & "Userlist",ServerNumber Else SendCommand "/notice " & Nickname & " Special Commands: " & Tool & "Admin, " & Tool & "Deadmin, " & Tool & "Dtopic, " & Tool & "Setop, " & Tool & "Registration, " & Tool & "Addban, " & Tool & "Delban, " & Tool & "Restrict, " & Tool & "Unrestrict, " & Tool & "Move, " & Tool & "Flip, " & Tool & "Allowpm, " & Tool & "Userlist",ServerNumber End If End If End If Else Select Case Lcase(words(1)) Case "up" SendCommand "/notice " & Nickname & " Use this to gain the highest attainable user mode in a channel based on your user level and channel settings",ServerNumber Case "down" SendCommand "/notice " & Nickname & " Use this to remove all channel user modes",ServerNumber Case "register" SendCommand "/notice " & Nickname & " Use this to register with the channel and gain basic bot commands",ServerNumber Case "voice" SendCommand "/notice " & Nickname & " Use this to give voice to another user. Shortcut " & Tool & "V",ServerNumber Case "devoice" SendCommand "/notice " & Nickname & " Use this to devoice another user. Shortcut " & Tool & "DV",ServerNumber Case "me" SendCommand "/notice " & Nickname & " Use this to get your own personal account information including your note if you have one",ServerNumber Case "user" SendCommand "/notice " & Nickname & " Use this to get another user's account information. You cannot see their note if they have one",ServerNumber Case "kick" SendCommand "/notice " & Nickname & " Use this to kick a user from your channel. Shortcut " & Tool & "K",ServerNumber Case "ban" SendCommand "/notice " & Nickname & " Use this to ban an active user from your channel. Shortcut " & Tool & "B",ServerNumber Case "unban" SendCommand "/notice " & Nickname & " Use this to unban an active network user from your channel. Shortcut " & Tool & "UB",ServerNumber Case "undoban" SendCommand "/notice " & Nickname & " Use this to undo the last set ban on a user in your channel. It only works on the last one. Shortcut " & Tool & "UDB or " & Tool & "Sorry",ServerNumber Case "setinfo" SendCommand "/notice " & Nickname & " Use this to set a message to be displayed when you enter a channel. Simply state the command only to clear your info",ServerNumber Case "topic" SendCommand "/notice " & Nickname & " Use this to change the end part of your channel's topic",ServerNumber Case "trefresh" SendCommand "/notice " & Nickname & " Use this to reset the last set topic if somehow it is different than before",ServerNumber Case "greet" SendCommand "/notice " & Nickname & " Use this to set a message to display to users who join your channel. Users with setinfo activated do not see your greet message. You can also set it to off",ServerNumber Case "update" SendCommand "/notice " & Nickname & " Use this to change your on file nickname to your current one",ServerNumber Case "note" SendCommand "/notice " & Nickname & " Use this to set a reminder or note. It displays each time you join the channel you set it on and from your account info using &Me",ServerNumber Case "chaninfo" SendCommand "/notice " & Nickname & " Use this to get basic channel information such as the topic and greet message",ServerNumber Case "seen" SendCommand "/notice " & Nickname & " Use this to get the date of when a specific user joined last",ServerNumber Case "help" SendCommand "/notice " & Nickname & " A universal command. &Help alone will display all of your available channel commands based on your permissions. Use &Help followed by a regular channel command to get info on what a command does",ServerNumber Case "unregister" SendCommand "/notice " & Nickname & " Use this to remove yourself and all permissions from the bot user list and channel",ServerNumber Case "snuggle" SendCommand "/notice " & Nickname & " A universal command. Use this toy to make the bot snuggle yourself by not declaring a nickname after the command or you can state another user",ServerNumber Case "deluser" SendCommand "/notice " & Nickname & " Use this to completely delete a registered user from your channel's service",ServerNumber Case "op" SendCommand "/notice " & Nickname & " A universal command. Use this to op a registered user on your channel. You can also state either on or off after &op to control whether or not you are opped automatically as a user mode.",ServerNumber Case "deop" SendCommand "/notice " & Nickname & " Use this to deop a registered user on your channel",ServerNumber Case "moderate" SendCommand "/notice " & Nickname & " Use this to give a registered user moderation control over your channel",ServerNumber Case "demoderate" SendCommand "/notice " & Nickname & " Use this to remove moderation (and admin if present) power from a registered user in your channel",ServerNumber Case "clearinfo" SendCommand "/notice " & Nickname & " Use this to clear a registered user's channel join message",ServerNumber Case "infolock" SendCommand "/notice " & Nickname & " Use this to remove the topic and greet editing permissions from being changed by moderators",ServerNumber Case "suspend" SendCommand "/notice " & Nickname & " Use this to basically unregister a user to basic power while being able to reinstate the user at any later time",ServerNumber Case "unsuspend" SendCommand "/notice " & Nickname & " Use this to reinstate a user's power to your channel. Moderation and admin power is automatically restored",ServerNumber Case "override" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" and channel=Getinifile("Settings.txt","Settings","Channel","") then SendCommand "/notice " & Nickname & " " & Tool & "Override 1 sets you at admin level for a channel and " & Tool & "Override 2 sets you at ownership level. " & Tool & "Override 3 allows you to recieve auth script files via dcc. Only use this command via pm",ServerNumber SendCommand "/notice " & Nickname & " Typing " & Tool & "Override 3 script will send you your last updated auth script. Specify a channel such as " & channel & " in place of the word script will send you that txt file",ServerNumber SendCommand "/notice " & Nickname & " Having DCC problems? Make sure your firewall lets your client send files through DCC ports and that your DCC send file location is directed at your scripts folder and not your my documents folder",ServerNumber Else Sendcommand "/notice " & Nickname & " No viewable help information",ServerNumber End If Case "newchan" SendCommand "/notice " & Nickname & " Use this to register a new channel with an active new owner",ServerNumber Case "admin" SendCommand "/notice " & Nickname & " Use this to grant admin powers to a registered user on your channel",ServerNumber Case "deadmin" SendCommand "/notice " & Nickname & " Use this to remove admin powers from a registered user on your channel",ServerNumber Case "dtopic" SendCommand "/notice " & Nickname & " Use this to set the default topic in your channel which is also the first part of the topic",ServerNumber Case "setop" SendCommand "/notice " & Nickname & " Use this to set who can claim op status in your channel. 0 is owner only, 1 is admins and up, 2 is mods and up.",ServerNumber Case "registration" SendCommand "/notice " & Nickname & " Use this to allow automatic user registration (On) or disable it (Off)",Servernumber Case "addban" SendCommand "/notice " & Nickname & " Use this to ban any hostmask or user name without doing a typical user check",ServerNumber Case "restrict" SendCommand "/notice " & Nickname & " Use this to disallow an admin from changing other user permissions",ServerNumber Case "unrestrict" SendCommand "/notice " & Nickname & " Use this to allow an admin to change other user permissions",ServerNumber Case "move" SendCommand "/notice " & Nickname & " Use this to move a user's account to another account say if their host happened to change. &Move account1 account2",ServerNumber Case "delban" SendCommand "/notice " & Nickname & " Use this to remove any hostmask or user name without doing a typical user check",Servernumber Case "userlist" If GetIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" and channel=Getinifile("Settings.txt","Settings","Channel","") then Sendcommand "/notice " & Nickname & " You can set DCC or in chat viewable content: &Userlist view DCC or &Userlist view Chat",ServerNumber End If SendCommand "/notice " & Nickname & " Use this to set who can download by DCC your channel user list (0 = Channel Owner, 1 = Admins, 2 = Mods, 3 = Any Registered User)",ServerNumber Case "flip" SendCommand "/notice " & Nickname & " Use this to reverse the mode(s) set on a user whether it be op or voice (Case sensitive)",ServerNumber Case "sync" SendCommand "/notice " & Nickname & " Use this to set all active channel users to their correct channel modes",ServerNumber Case "fix" SendCommand "/notice " & Nickname & " Use this to set a user to their correct channel mode if it has otherwise been changed (Case sensitive)",ServerNumber Case "tool" SendCommand "/notice " & Nickname & " Use this to set the character you wish to use to activate your commands. Default tool: &. If you forget your tool, simply type &Toolreset.",ServerNumber Case "allowpm" SendCommand "/notice " & Nickname & " Use this to control whether or not users may use bot commands via PM (Yes,No)",ServerNumber Case "spam" SendCommand "/notice " & Nickname & " Use this to kick users for spamming your channel. " & Tool & "Spam Count will set the amount of messages to kick for, " & Tool & "Spam Time will set how many messages may be sent at once",ServerNumber SendCommand "/notice " & Nickname & " " & Tool & "Spam Info will give you your current settings. " & Tool & "Spam Opdetect (On,Off) controls whether I kick ops for spamming. " & Tool & "Spam (On,Off) controls whether I kick users for spamming",ServerNumber Case "message" Sendcommand "/notice " & Nickname & " You can &Message Check, &Message Read , &Message Delete , &Message Send , &Message Preview , &Message Block , &Message Unblock ",ServerNumber Case "users" Sendcommand "/notice " & Nickname & " Use this to view the registered users in a channel by either DCC or in chat as set by the bot owner",ServerNumber Case "botinfo" SendCommand "/notice " & Nickname & " Use this to see bot information",ServerNumber Case Else SendCommand "/notice " & Nickname & " I did not recognize this command. Make sure it is a vald command for channel control",ServerNumber End Select End If Case "register" If not Tutorial="" then SendCommand "/notice " & Nickname & " Error: This service is currently busy. Please try again in 30 seconds",ServerNumber ElseIf not IsVoice(Nickname,Channel,ServerNumber) then SendCommand "/notice " & Nickname & " You cannot register! Reason: Not voiced as a requirement!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then SendCommand "/notice " & Nickname & " You cannot register! Reason: You are already registered",ServerNumber ElseIf Mid(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host",""),3)=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then SendCommand "/notice " & Nickname & " You cannot register! Reason: You are using a suspended account",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",Nickname,"Host","") = "" then SendCommand "/notice " & Nickname & " This nickname is already in use!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt","Register","Allowed","")="Yes" then WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Nick", Nickname WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host", GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","No" WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","No" WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","No" WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Seen",Date WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Nick",""),"Host",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) Tutorial=Host SendCommand "/timer tutorial 1 30 /! OnTutorial",ServerNumber SendCommand "/msg " & Channel & " You are now registered as " & Nickname & " $mask($nick(" & Channel & "," & Nickname & ").mask,2) ",ServerNumber SendCommand "/timer asktutorial 1 1 /msg " & Channel & " " & Nickname & ": Would you like to take a tutorial? (" & Tool & "Yes," & Tool & "No)" Else SendCommand "/notice " & Nickname & " You cannot register! Reason: Automatic registration disabled",ServerNumber End If Case "yes" If Tutorial=Host then SendCommand "/timer tutorial off" Tutorial="" SendCommand "/timer listone 1 1 /notice " & Nickname & " Use the " & Tool & "Help command to view a list of your available user commands. You can use help to get information on a command as well" SendCommand "/timer listtwo 1 6 /notice " & Nickname & " Most PM commands work by /msg " & GetIdentifier("$me",ServerNumber) & " #channel " & Tool & "command" SendCommand "/timer listthree 1 11 /notice " & Nickname & " Admins can moderate other users and even delete them completely" SendCommand "/timer listfour 1 16 /notice " & Nickname & " Protected users cannot be changed by others. There is no admin command to become protected" SendCommand "/timer listfive 1 21 /notice " & Nickname & " Chanserv is here only to protect me, whereas I will be in full opping control for the channel" SendCommand "/timer listsix 1 26 /Notice " & Nickname & " Thats about it! Remember, " & Tool & "Help is your friend",ServerNumber End If If Host=Pass then If Setup="5" then SendCommand "/timer sdog1 off" SendCommand "/timer sdog3 off" Notemem="0" Do while not Notemem > 49 Notemem = Notemem -- 1 If not Getinifile("Note.txt",Snick,Notemem,"")="" then Writeinifile"Note.txt",Snick2,Notemem,Getinifile("Note.txt",Snick,Notemem,"") Writeinifile"Note.txt",Snick,Notemem,"" End If Loop WriteIniFile"" & Channel & ".txt",Snick2,"Nick",GetIniFile("" & Channel & ".txt",Snick,"Nick","") WriteIniFile"" & Channel & ".txt",Snick2,"Host",Snick2 WriteIniFile"" & Channel & ".txt",Snick2,"Mod",GetIniFile("" & Channel & ".txt",Snick,"Mod","") WriteIniFile"" & Channel & ".txt",Snick2,"Admin",GetIniFile("" & Channel & ".txt",Snick,"Admin","") WriteIniFile"" & Channel & ".txt",Snick2,"Protect",GetIniFile("" & Channel & ".txt",Snick,"Protect","") WriteIniFile"" & Channel & ".txt",Snick2,"Join",GetIniFile("" & Channel & ".txt",Snick,"Join","") WriteIniFile"" & Channel & ".txt",Snick2,"Note",GetIniFile("" & Channel & ".txt",Snick,"Note","") WriteIniFile"" & Channel & ".txt",Snick2,"Seen",GetIniFile("" & Channel & ".txt",Snick,"Seen","") writeinifile"" & Channel & ".txt",Snick2,"Op",GetIniFile("" & Channel & ".txt",Snick,"Op","") WriteIniFile"" & Channel & ".txt",Snick2,"Special",GetIniFile("" & Channel & ".txt",Snick,"Special","") WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Snick2,"Nick",""),"Host",Snick2 WriteIniFile"" & Channel & ".txt",Snick,"Nick"," Unregistered on " & Date & "" WriteIniFile"" & Channel & ".txt",Snick,"Host"," Moved accounts to " & Snick2 & "" WriteIniFile"" & Channel & ".txt",Snick,"Mod","" WriteIniFile"" & Channel & ".txt",Snick,"Admin","" WriteIniFile"" & Channel & ".txt",Snick,"Protect","" WriteIniFile"" & Channel & ".txt",Snick,"Join","" WriteIniFile"" & Channel & ".txt",Snick,"Note","" WriteIniFile"" & Channel & ".txt",Snick,"Seen","" writeinifile"" & Channel & ".txt",Snick,"Op","" WriteIniFile"" & Channel & ".txt",Snick,"Special","" Setup="" Pass="" Snick="" Snick2="" SendCommand "/notice " & nickname & " The account has been moved successfully!",ServerNumber End if End If Case "no" If Tutorial=Host then SendCommand "/timer tutorial off" Tutorial="" SendCommand "/msg " & Channel & " Acknowledged, thanks!" End if If Host=Pass Then If Setup="5" then SendCommand "/timer sdog1 off" SendCommand "/timer sdog3 off" Setup="" Pass="" Snick="" Snick2="" SendCommand "/notice " & nickname & " The account has not been moved or altered!",ServerNumber End if End If Case "allowpm" If not GetIniFile("" & channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: Not a channel owner",ServerNumber ElseIf Lcase(words(1))="no" then If GetIniFile("" & Channel & ".txt","Allowpm","Set","")="No" then Sendcommand "/notice " & Nickname & " Error: PM commands have already been disabled!",ServerNumber Else writeIniFile"" & Channel & ".txt","Allowpm","Set","No" Sendcommand "/notice " & Nickname & " PM commands are now disabled!",ServerNumber End If ElseIf Lcase(words(1))="yes" then If GetIniFile("" & Channel & ".txt","Allowpm","Set","")="Yes" then Sendcommand "/notice " & Nickname & " Error: PM commands have already been enabled!",ServerNumber Else writeIniFile"" & Channel & ".txt","Allowpm","Set","Yes" Sendcommand "/notice " & Nickname & " PM commands are now enabled!",ServerNumber End If End If Case "unregister" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) or Left(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host",""),1)="s" then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" and not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Special","")="Yes" then SendCommand "/notice " & Nickname & " Error: Channel owners cannot remove themselves!",ServerNumber Else WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Nick",""),"Host","" WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Nick", "Unregistered on " & Date & "" WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host", "Unregistered by " & Host & "" WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","" WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","" WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","" WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","" WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Note","" WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Seen","" writeinifile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Op","" WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Special","" SendCommand "/mode " & Channel & " -ov " & Nickname & " " & Nickname & "" SendCommand "/msg " & Channel & " You are now unregistered as " & GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " You cannot Unregister! Reason: Not registered!",ServerNumber End If Case "userlist" If Mid(Message,11)="" then SendCommand "/notice " & Nickname & " Please view help information for this command",ServerNumber Elseif getIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","")="Yes" then If Lcase(words(1))="view" then If Channel = Getinifile("Settings.txt","Settings","Channel","") then If Lcase(Mid(Message,16))="dcc" then If Getinifile("Settings.txt","Settings","Users","")="0" then Sendcommand "/notice " & Nickname & " Error: Already set to DCC",ServerNumber Else Writeinifile"Settings.txt","Settings","Users","0" Sendcommand "/notice " & Nickname & " Userlist is now set to be viewed by DCC download",ServerNumber End If ElseIf Lcase(Mid(Message,16))="chat" then If Getinifile("Settings.txt","Settings","Users","")="1" then Sendcommand "/notice " & Nickname & " Error: Already set to Chat",ServerNumber Else Writeinifile"Settings.txt","Settings","Users","1" Sendcommand "/notice " & Nickname & " Userlist is now set to be viewed in chat",ServerNumber End If End If End If Elseif Mid(Message,11)="0" then If not GetIniFile("" & channel & ".txt","DCC","Allowed","")="0" then writeIniFile"" & channel & ".txt","DCC","Allowed","0" SendCommand "/notice " & Nickname & " Only channel owner may now get the user list",ServerNumber Else SendCommand "/notice " & Nickname & " Error: Already set!",ServerNumber End If ElseIf Mid(Message,11)="1" then If not GetIniFile("" & channel & ".txt","DCC","Allowed","")="1" then writeIniFile"" & channel & ".txt","DCC","Allowed","1" SendCommand "/notice " & Nickname & " Channel admins and up may now get the user list",ServerNumber Else SendCommand "/notice " & Nickname & " Error: already set!",ServerNumber End If ElseIf Mid(Message,11)="2" then If not GetIniFile("" & channel & ".txt","DCC","Allowed","")="2" then writeIniFile"" & channel & ".txt","DCC","Allowed","2" SendCommand "/notice " & Nickname & " Channel moderators and up may now get the user list",ServerNumber Else SendCommand "/notice " & Nickname & " Error: already set!",ServerNumber End If ElseIf Mid(Message,11)="3" then If not GetIniFile("" & channel & ".txt","DCC","Allowed","")="3" then writeIniFile"" & channel & ".txt","DCC","Allowed","3" SendCommand "/notice " & Nickname & " Channel users and up may now get the user list",ServerNumber Else SendCommand "/notice " & Nickname & " Error: already set!",ServerNumber End If End If Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End If Case "users" If not GetIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Host","") = "" and GetIniFile("" & channel & ".txt","DCC","Allowed","")>"2" then If GetIniFile("Settings.txt","Settings","Users","")="0" then SendCommand "/notice " & Nickname & " Sending you your requested channel info...",ServerNumber SendCommand "/dcc send " & Nickname & " " & channel & ".txt",ServerNumber Else Sendcommand "/! Ulist " & Nickname & "|" & Channel & "|" & ServerNumber & "" End If ElseIf GetIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","") = "Yes" and GetIniFile("" & channel & ".txt","DCC","Allowed","")>"1" then If GetIniFile("Settings.txt","Settings","Users","")="0" then SendCommand "/notice " & Nickname & " Sending you your requested channel info...",ServerNumber SendCommand "/dcc send " & Nickname & " " & channel & ".txt",ServerNumber Else Sendcommand "/! Ulist " & Nickname & "|" & Channel & "|" & ServerNumber & "" End If ElseIf GetIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") = "Yes" and GetIniFile("" & channel & ".txt","DCC","Allowed","")>"0" then If GetIniFile("Settings.txt","Settings","Users","")="0" then SendCommand "/notice " & Nickname & " Sending you your requested channel info...",ServerNumber SendCommand "/dcc send " & Nickname & " " & channel & ".txt",ServerNumber Else Sendcommand "/! Ulist " & Nickname & "|" & Channel & "|" & ServerNumber & "" End If Elseif GetIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") = "Yes" then If GetIniFile("Settings.txt","Settings","Users","")="0" then SendCommand "/notice " & Nickname & " Sending you your requested channel info...",ServerNumber SendCommand "/dcc send " & Nickname & " " & channel & ".txt",ServerNumber Else Sendcommand "/! Ulist " & Nickname & "|" & Channel & "|" & ServerNumber & "" End If Else SendCommand "/notice " & Nickname & " Error: No permission! - " & GetIniFile("" & channel & ".txt","DCC","Allowed","") & "",ServerNumber End If Case "up" If IsOp(Nickname,Channel,ServerNumber) then SendCommand "/notice " & Nickname & " Error: You are up",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then SendCommand "/notice " & Nickname & " Cannot up! Reason: Not registered",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","")="Yes" then If not GetIniFile("" & Channel & ".txt","op","Set","")="0" or GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/mode " & Channel & " +o " & Nickname & "",ServerNumber Elseif not IsVoice(Nickname,Channel,ServerNumber) then SendCommand "/mode " & Channel & " +v " & Nickname & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: You are up!",ServerNumber End If ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","")="Yes" then If GetIniFile("" & Channel & ".txt","op","Set","")="2" then SendCommand "/mode " & Channel & " +o " & Nickname & "",ServerNumber Elseif not IsVoice(Nickname,Channel,ServerNumber) then SendCommand "/mode " & Channel & " +v " & Nickname & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: You are up!",ServerNumber End If ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then If IsVoice(Nickname,Channel,ServerNumber) then SendCommand "/notice " & Nickname & " Error: You are up!",ServerNumber Else SendCommand "/mode " & Channel & " +v " & Nickname & "",ServerNumber End If End If Case "down" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) and not IsVoice(Nickname,Channel,ServerNumber) and not IsOp(Nickname,Channel,ServerNumber) then SendCommand "/notice " & Nickname & " Cannot down! Reason: You are not voiced or opped!",ServerNumber Else SendCommand "/mode " & Channel & " -ov " & Nickname & " " & Nickname & " ",ServerNumber End If Case "flip" If not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Cannot flip! Reason: Not a channel owner",ServerNumber ElseIf Words(1)=GetIdentifier("$Me",ServerNumber) then SendCommand "/notice " & Nickname & " Error: You cannot alter my channel modes!",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Words(1) & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Words(1) & ").mask,2)",ServerNumber) then SendCommand "/notice " & Nickname & " Error: " & Words(1) & " is not a registered user!",ServerNumber ElseIf IsOp(Words(1),Channel,ServerNumber) or IsVoice(Words(1),channel,servernumber) then SendCommand "/mode " & Channel & " -ov " & Words(1) & " " & Words(1) & " ",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Words(1) & ").mask,2)",ServerNumber),"Admin","")="Yes" then If not GetIniFile("" & Channel & ".txt","op","Set","")="0" or GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Words(1) & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/mode " & Channel & " +o " & Words(1) & "",ServerNumber Elseif not IsVoice(Words(1),Channel,ServerNumber) then SendCommand "/mode " & Channel & " +v " & Words(1) & "",ServerNumber End If ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Words(1) & ").mask,2)",ServerNumber),"Mod","")="Yes" then If GetIniFile("" & Channel & ".txt","op","Set","")="2" then SendCommand "/mode " & Channel & " +o " & Words(1) & "",ServerNumber Elseif not IsVoice(Words(1),Channel,ServerNumber) then SendCommand "/mode " & Channel & " +v " & Words(1) & "",ServerNumber End If Else SendCommand "/mode " & Channel & " +v " & Words(1) & "",ServerNumber End If Case "fix" If not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","")="Yes" then SendCommand "/notice " & Nickname & " Cannot fix! Reason: Not a channel moderator",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,6) & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,6) & ").mask,2)",ServerNumber) then If IsOp(Mid(Message,6),Channel,ServerNumber) or isvoice(Mid(Message,6),Channel,ServerNumber) then SendCommand "/mode " & Channel & " -ov " & Mid(Message,6) & " " & Mid(Message,6) & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: This user is at their appropriate user settings!",ServerNumber End if ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Words(1) & ").mask,2)",ServerNumber),"Admin","")="Yes" then If not GetIniFile("" & Channel & ".txt","op","Set","")="0" or GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Words(1) & ").mask,2)",ServerNumber),"Protect","")="Yes" then If Not IsOp(Words(1),Channel,ServerNumber) then SendCommand "/mode " & Channel & " +o " & Words(1) & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: This user is at their appropriate user settings!",ServerNumber End If ElseIf IsOp(Words(1),Channel,ServerNumber) and GetIniFile("" & Channel & ".txt","op","Set","")="0" and not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Words(1) & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/mode " & Channel & " -o+v " & Words(1) & " " & Words(1) & "",ServerNumber Elseif not IsVoice(Words(1),Channel,ServerNumber) then SendCommand "/mode " & Channel & " +v " & Words(1) & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: This user is at their appropriate user settings!",ServerNumber End If ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Words(1) & ").mask,2)",ServerNumber),"Mod","")="Yes" then If GetIniFile("" & Channel & ".txt","op","Set","")="2" and not IsOp (Words(1),Channel,ServerNumber) then SendCommand "/mode " & Channel & " +o " & Words(1) & "",ServerNumber ElseIf IsOp(Words(1),Channel,ServerNumber) and not GetIniFile("" & Channel & ".txt","op","Set","")="2" then SendCommand "/mode " & Channel & " -o+v " & Words(1) & " " & Words(1) & "",ServerNumber Elseif not IsVoice(Words(1),Channel,ServerNumber) then SendCommand "/mode " & Channel & " +v " & Words(1) & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: This user is at their appropriate user settings!",ServerNumber End If ElseIf IsOp(Words(1),Channel,ServerNumber) then SendCommand "/mode " & Channel & " -o+v " & Words(1) & " " & Words(1) & "",ServerNumber ElseIf not IsVoice(Words(1),Channel,ServerNumber) then SendCommand "/mode " & Channel & " +v " & Words(1) & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: This user is at their appropriate user settings!",ServerNumber End If Case "setinfo" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then If Mid(Message,10)="" and not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","")="" then SendCommand "/notice " & Nickname & " Your info has been cleared!",ServerNumber WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","" ElseIf Lcase(Mid(Message,10))="" and GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","")="" then SendCommand "/notice " & Nickname & " Error: Nothing to clear!",ServerNumber ElseIf Lcase(Left(Message,10))="&setinfo &" then SendCommand "/notice " & Nickname & " Error: Your info message cannot begin with the & symbol",ServerNumber Else WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join",Mid(Message,10) If Lcase(Mid(Message,10))="off" then SendCommand "/notice " & Nickname & " I will no longer greet you on channel join",ServerNumber Else SendCommand "/notice " & Nickname & " " & Mid(Message,10) & "",ServerNumber End If End If Else Sendcommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End If Case "topic" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then If getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","")="Yes" then If GetIniFile("" & Channel & ".txt","Topic","Lock","")="On" and not getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","")="Yes" then SendCommand "/notice " & Nickname & " Cannot change topic! Reason: Locked by an admin",ServerNumber Else SendCommand "/topic " & Channel & " " & GetIniFile("" & Channel & ".txt","Topic","Ident","") & " " & Mid(Message,8) & "",ServerNumber Writeinifile"" & Channel & ".txt","Topic","Topic",Mid(Message,8) Sendcommand "/msg Chanserv " & Channel & " set defaulttopic " & GetIniFile("" & Channel & ".txt","Topic","Ident","") & " " & Mid(Message,8) & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End If Case "seen" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & words(1) & ").mask,2)",ServerNumber),"Nick","")="" and GetIniFile("" & Channel & ".txt",words(1),"Host","")="" then SendCommand "/notice " & Nickname & " Error: This user does not exist!",ServerNumber ElseIf not GetIdentifier("$mask($nick(" & Channel & "," & words(1) & ").mask,2)",ServerNumber)="$null" then SendCommand "/notice " & Nickname & " " & Words(1) & " is active on the channel",ServerNumber ElseIf getIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",words(1),"Host",""),"Seen","")="" then SendCommand "/notice " & Nickname & " Error: This user has insufficient data. Please try again later",ServerNumber Else SendCommand "/notice " & Nickname & " " & Words(1) & " last seen " & getIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",words(1),"Host",""),"Seen","") & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End If Case "registration" If Not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber ElseIf Not getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber ElseIf Lcase(Mid(Message,15))="on" then If GetIniFile("" & Channel & ".txt","Register","Allowed","")="Yes" then SendCommand "/notice " & Nickname & " Error: Automatic registration is already enabled",ServerNumber Else writeIniFile"" & Channel & ".txt","Register","Allowed","Yes" SendCommand "/notice " & Nickname & " Automatic registration is now on",ServerNumber End if ElseIf Lcase(Mid(Message,15))="off" then If GetIniFile("" & Channel & ".txt","Register","Allowed","")="No" then SendCommand "/notice " & Nickname & " Error: Automatic registration is already disabled",ServerNumber Else writeIniFile"" & Channel & ".txt","Register","Allowed","No" SendCommand "/notice " & Nickname & " Automatic registration is now off",ServerNumber End if End If Case "trefresh" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then If getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","")="Yes" then SendCommand "/topic " & Channel & " " & GetIniFile("" & Channel & ".txt","Topic","Ident","") & " " & GetIniFile("" & Channel & ".txt","Topic","Topic","") & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End If Case "me" If Left(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " Your account is currently suspended!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then If Not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","")="" and Not Left(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join",""),1)="&" then SendCommand "/notice " & Nickname & " Join Message: " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Join","") & "",ServerNumber End If If not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Note","")="" then SendCommand "/notice " & Nickname & " Your note: " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Note","") & "",ServerNumber End If If getinifile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Op","")="Off" then SendCommand "/notice " & Nickname & " Automatic channel op on join is disabled",ServerNumber End If If GetIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Special","")="S" then Spad="-R-" End If SendCommand "/notice " & Nickname & " " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Nick","") & ": Is a mod= " & getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","") & " ; Has admin= " & Spad & "" & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","") & " ; Is Protected= " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","") & " ; Host= " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","") & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End if Case "note" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then If Mid(Message,7)="" and not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Note","")="" then SendCommand "/notice " & Nickname & " Your note has been cleared!",ServerNumber WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Note","" ElseIf Lcase(Mid(Message,7))="" and GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Note","")="" then SendCommand "/notice " & Nickname & " Error: Nothing to clear!",ServerNumber Else WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Note",Mid(Message,7) SendCommand "/notice " & Nickname & " Note: " & Mid(Message,7) & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End If Case "message" If Getinifile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")="" then Sendcommand "/notice " & Nickname & " Error: Not registered!",ServerNumber ElseIf Mid(Message,10)="" then Sendcommand "/notice " & Nickname & " You can &Message Check, &Message Read , &Message Delete , &Message Send , &Message Preview , &Message Block , &Message Unblock ",ServerNumber ElseIf Lcase(Words(1))="check" then Notemem="0" Snote="0" Scount="" Unote="0" Do while not Notemem > 50 Notemem = Notemem -- 1 If not Notemem > 50 then If not Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Notemem,"")="" then If Left(Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Notemem,""),1)="&" then Snote = Snote -- 1 Unote = Unote -- 1 Scount = Scount + ", *" & Notemem & "" Else Snote = Snote -- 1 Scount = Scount + ", " & Notemem & "" End If End If ElseIf Snote = "0" then Sendcommand "/notice " & Nickname & " You have no received or saved messages",ServerNumber Elseif Unote = "0" then Sendcommand "/notice " & Nickname & " You have " & Snote & " saved messages on " & Mid(Scount,2) & "",ServerNumber If Snote > 40 and not Snote="50" then Sendcommand "/notice " & Nickname & " Warning: You have used more than 80% of your inbox space! Consider deleting messages",ServerNumber Elseif Snote="50" then Sendcommand "/notice " & Nickname & " Warning: Your inbox is full and you will not be able to receive any more messages!",ServerNumber End If Else Sendcommand "/notice " & Nickname & " You have " & Snote & " saved messages, " & Unote & " unread marked with * on " & Mid(Scount,2) & "",ServerNumber If Snote > 40 and not Snote="50" then Sendcommand "/notice " & Nickname & " Warning: You have used more than 80% of your inbox space! Consider deleting messages",ServerNumber Elseif Snote="50" then Sendcommand "/notice " & Nickname & " Warning: Your inbox is full and you will not be able to receive any more messages!",ServerNumber End If End If Loop ElseIf Lcase(Words(1))="read" then If Mid(Message,15)="" then Sendcommand "/notice " & Nickname & " Error: Please state a message number to read",ServerNumber ElseIf Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Mid(Message,15),"")="" then Sendcommand "/notice " & Nickname & " Error: Invalid message",ServerNumber Else Note = Split(Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Mid(Message,15),"")," ") If Left(Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Mid(Message,15),""),1)="&" then Writeinifile"Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Mid(Message,15),Mid(Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Mid(Message,15),""),2) Sendcommand "/notice " & Nickname & " Sent by " & Mid(Note(0),2) & " on " & Note(1) & ": " & Mid(Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Mid(Message,15),""),Len(Note(0)) + Len(Note(1)) -- 3) Else Sendcommand "/notice " & Nickname & " Sent by " & Note(0) & " on " & Note(1) & ": " & Mid(Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Mid(Message,15),""),Len(Note(0)) + Len(Note(1)) -- 3) End If End If ElseIf Lcase(Words(1))="preview" then If Mid(Message,18)="" then Sendcommand "/notice " & Nickname & " Error: Please state a message number to preview",ServerNumber ElseIf Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Mid(Message,18),"")="" then Sendcommand "/notice " & Nickname & " Error: Invalid message",ServerNumber Else Note = Split(Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Mid(Message,18),"")," ") If Left(Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Mid(Message,18),""),1)="&" then Sendcommand "/notice " & Nickname & " Message Info: Sent by " & Mid(Note(0),2) & " on " & Note(1) & "",ServerNumber Else Sendcommand "/notice " & Nickname & " Message Info: Sent by " & Note(0) & " on " & Note(1) & "",ServerNumber End If End If ElseIf Lcase(Words(1))="delete" then If Mid(Message,17)="" then Sendcommand "/notice " & Nickname & " Error: Please state a message number to delete",ServerNumber ElseIf Lcase(Mid(Message,17))="all" then Do while not Notemem > 50 Notemem = Notemem -- 1 If not Notemem > 50 then Writeinifile"Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Notemem,"" Else Sendcommand "/notice " & Nickname & " All messages deleted!",ServerNumber End If Loop ElseIf Getinifile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Mid(Message,17),"")="" then Sendcommand "/notice " & Nickname & " Error: Invalid message",ServerNumber Else Writeinifile"Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),Mid(Message,17),"" Sendcommand "/notice " & Nickname & " Message " & Mid(Message,17) & " erased",ServerNumber End if Elseif Lcase(Words(1))="send" then If Mid(Message,Len(Words(0)) + Len(Words(1)) + Len(Words(2)) -- 4)="" then Sendcommand "/notice " & Nickname & " Error: Please state a user followed by a message!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Words(2) & ").mask,2)",ServerNumber),"Host","")="" and GetIniFile("" & Channel & ".txt",words(2),"Host","")="" then Sendcommand "/notice " & Nickname & " Error: " & Words(2) & " is not a registered user to the channel! You can only send messages to registered users.",ServerNumber Elseif not GetIniFile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Words(2) & ").mask,2)",ServerNumber),GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"")="" or not GetIniFile("Note.txt",GetIniFile("" & Channel & ".txt",words(2),"Host",""),GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"")="" or Lcase(words(2)) = Lcase(Getidentifier("$me",ServerNumber)) then Sendcommand "/notice " & Nickname & " Error: You have been blocked from sending messages to this user!",ServerNumber ElseIf Len(Mid(Message,Len(Words(0)) + Len(Words(1)) + Len(Words(2)) -- 4)) > 215 then Sendcommand "/notice " & Nickname & " Error: Your message cannot be longer than 215 characters! (" & Len(Mid(Message,Len(Words(0)) + Len(Words(1)) + Len(Words(2)) -- 4)) & ")",ServerNumber Else Notemem="0" If GetIdentifier("$mask($nick(" & Channel & "," & Words(2) & ").mask,2)",ServerNumber)="$null" then Mhost=GetIniFile("" & Channel & ".txt",words(2),"Host","") Else Mhost=GetIdentifier("$mask($nick(" & Channel & "," & Words(2) & ").mask,2)",ServerNumber) End If Do while not Notemem > 49 Notemem = Notemem -- 1 If Getinifile("Note.txt",Mhost,Notemem,"")="" then Writeinifile"Note.txt",Mhost,Notemem,"&" & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Nick","") & " " & Getidentifier("$date",ServerNumber) & " " & Mid(Message,Len(Words(0)) + Len(Words(1)) + Len(Words(2)) -- 3) & "" Notemem = 50 If GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber)=Mhost then Sendcommand "/notice " & Nickname & " Draft saved!",ServerNumber Else Sendcommand "/notice " & Nickname & " Message sent!",ServerNumber End If If not GetIdentifier("$mask($nick(" & Channel & "," & Words(2) & ").mask,2)",ServerNumber)="$null" and not Words(2)=Nickname then Sendcommand "/notice " & words(2) & " You have received a new message from " & Nickname & "!",ServerNumber End If Elseif Notemem = "50" then Sendcommand "/notice " & Nickname & " Error: This user's inbox is full and cannot receive any more messages!",ServerNumber End if Loop End If ElseIf Lcase(Words(1))="block" then If Mid(Message,16)="" then Sendcommand "/notice " & Nickname & " Error: Please state a user to block!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Words(2) & ").mask,2)",ServerNumber),"Host","")="" and GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",words(2),"Host",""),"Host","")="" then Sendcommand "/notice " & Nickname & " Error: " & Words(2) & " is not a registered user to the channel! You can only block users who can currently send you messages",ServerNumber Elseif not GetIniFile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),GetIniFile("" & Channel & ".txt",words(2),"Host",""),"")="" or not GetIniFile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),GetIdentifier("$mask($nick(" & Channel & "," & Words(2) & ").mask,2)",ServerNumber),"")="" then Sendcommand "/notice " & Nickname & " Error: You have already blocked this user from sending you messages",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",words(2),"Host","")="" then WriteiniFile"Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),GetIniFile("" & Channel & ".txt",words(2),"Host",""),"Banned" Sendcommand "/notice " & Nickname & " Blocked " & GetIniFile("" & Channel & ".txt",words(2),"Host","") & "",ServerNumber Else WriteIniFile"Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),GetIdentifier("$mask($nick(" & Channel & "," & Words(2) & ").mask,2)",ServerNumber),"Banned" Sendcommand "/notice " & Nickname & " Blocked " & GetIdentifier("$mask($nick(" & Channel & "," & Words(2) & ").mask,2)",ServerNumber) & "",ServerNumber End If ElseIf Lcase(Words(1))="unblock" then If Mid(Message,18)="" then Sendcommand "/notice " & Nickname & " Error: Please state a user to unblock!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Words(2) & ").mask,2)",ServerNumber),"Host","")="" and GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",words(2),"Host",""),"Host","")="" then Sendcommand "/notice " & Nickname & " Error: " & Words(2) & " is not a registered user to the channel!",ServerNumber Elseif GetIniFile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),GetIniFile("" & Channel & ".txt",words(2),"Host",""),"")="" and GetIniFile("Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),GetIdentifier("$mask($nick(" & Channel & "," & Words(2) & ").mask,2)",ServerNumber),"")="" then Sendcommand "/notice " & Nickname & " Error: This user is not blocked from sending you messages",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",words(2),"Host","")="" then WriteiniFile"Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),GetIniFile("" & Channel & ".txt",words(2),"Host",""),"" Sendcommand "/notice " & Nickname & " Unlocked " & GetIniFile("" & Channel & ".txt",words(2),"Host","") & "",ServerNumber Else WriteIniFile"Note.txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),GetIdentifier("$mask($nick(" & Channel & "," & Words(2) & ").mask,2)",ServerNumber),"" Sendcommand "/notice " & Nickname & " Unlocked " & GetIdentifier("$mask($nick(" & Channel & "," & Words(2) & ").mask,2)",ServerNumber) & "",ServerNumber End If End If Case "snuggle" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then If Mid(Message,10)="" then SendCommand "/describe " & Channel & " snuggles " & Nickname & "",ServerNumber ElseIf GetIdentifier("$mask($nick(" & channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber)="$null" then SendCommand "/notice " & Nickname & " D: But this person isn't here! Or you mispelled the nick...",ServerNumber Else SendCommand "/describe " & Channel & " snuggles " & words(1) & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Ew: Not registered!",ServerNumber End if Case "update" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Nick","")=Nickname then SendCommand "/notice " & Nickname & " You cannot change your nickname if it's the same!",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",Nickname,"Host","") = "" then SendCommand "/Notice " & Nickname & " This nickname is already in use!",ServerNumber Else WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Nick",""),"Host","" WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Nick",Nickname WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Nick",""),"Host",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) SendCommand "/notice " & Nickname & " You have changed your nickname to " & Nickname & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End if Case "sync" If not GetIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","") ="Yes" then SendCommand "/notice " & Nickname & " Error: No permission!",ServerNumber Else Num = "0" Active ="0" SPcount = Getidentifier("$nick(" & channel & ",0),ServerNumber") Do while not Num = SPcount -- 1 Num = Num -- 1 Sname = Getidentifier("$nick(" & channel & "," & Num & "),ServerNumber") Shost = GetIdentifier("$mask($nick(" & channel & "," & Sname & ").mask,2)",ServerNumber) If Not Sname="$null" then If not Sname="ChanServ" then If IsOp(Sname,channel,ServerNumber) then If not GetIniFile("" & channel & ".txt",Shost,"Host","")=Shost then WriteIniFile"" & channel & ".txt","Sync","Throw",GetIniFile("" & channel & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & channel & ".txt","Sync","Throwtype",GetIniFile("" & channel & ".txt","Sync","Throwtype","") + "-o" Active = Active -- 1 ElseIf GetIniFile("" & channel & ".txt",Shost,"Host","")=Shost and not GetIniFile("" & channel & ".txt",Shost,"Mod","")="Yes" then WriteIniFile"" & channel & ".txt","Sync","Throw",GetIniFile("" & channel & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & channel & ".txt","Sync","Throwtype",GetIniFile("" & channel & ".txt","Sync","Throwtype","") + "-o" Active = Active -- 1 ElseIf GetIniFile("" & channel & ".txt",Shost,"Mod","")="Yes" and not GetIniFile("" & channel & ".txt",Shost,"Admin","")="Yes" and not GetIniFile("" & channel & ".txt","op","Set","")="2" then WriteIniFile"" & channel & ".txt","Sync","Throw",GetIniFile("" & channel & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & channel & ".txt","Sync","Throwtype",GetIniFile("" & channel & ".txt","Sync","Throwtype","") + "-o" Active = Active -- 1 ElseIf GetIniFile("" & channel & ".txt",Shost,"Admin","")="Yes" and not GetIniFile("" & channel & ".txt",Shost,"Protect","")="Yes" and GetIniFile("" & channel & ".txt","op","Set","")="0" then WriteIniFile"" & channel & ".txt","Sync","Throw",GetIniFile("" & channel & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & channel & ".txt","Sync","Throwtype",GetIniFile("" & channel & ".txt","Sync","Throwtype","") + "-o" Active = Active -- 1 End If End If If isvoice(Sname,channel,ServerNumber) and not GetIniFile("" & channel & ".txt",Shost,"Host","")=Shost then WriteIniFile"" & channel & ".txt","Sync","Throw",GetIniFile("" & channel & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & channel & ".txt","Sync","Throwtype",GetIniFile("" & channel & ".txt","Sync","Throwtype","") + "-v" Active = Active -- 1 End If If not IsOp(Sname,channel,ServerNumber) then If GetIniFile("" & channel & ".txt",Shost,"Mod","")="Yes" and GetIniFile("" & channel & ".txt","op","Set","")="2" then WriteIniFile"" & channel & ".txt","Sync","Throw",GetIniFile("" & channel & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & channel & ".txt","Sync","Throwtype",GetIniFile("" & channel & ".txt","Sync","Throwtype","") + "+o" Active = Active -- 1 ElseIf GetIniFile("" & channel & ".txt",Shost,"Admin","")="Yes" and not GetIniFile("" & channel & ".txt",Shost,"Protect","")="Yes" and not GetIniFile("" & channel & ".txt","op","Set","")="0" then WriteIniFile"" & channel & ".txt","Sync","Throw",GetIniFile("" & channel & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & channel & ".txt","Sync","Throwtype",GetIniFile("" & channel & ".txt","Sync","Throwtype","") + "+o" Active = Active -- 1 ElseIf GetIniFile("" & channel & ".txt",Shost,"Protect","")="Yes" then WriteIniFile"" & channel & ".txt","Sync","Throw",GetIniFile("" & channel & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & channel & ".txt","Sync","Throwtype",GetIniFile("" & channel & ".txt","Sync","Throwtype","") + "+o" Active = Active -- 1 End If End If If not isvoice(Sname,channel,ServerNumber) and GetIniFile("" & channel & ".txt",Shost,"Host","")=Shost then If GetIniFile("" & channel & ".txt",Shost,"Admin","")="Yes" then If not GetIniFile("" & channel & ".txt",Shost,"Protect","")="Yes" and GetIniFile("" & channel & ".txt","op","Set","")="0" then WriteIniFile"" & channel & ".txt","Sync","Throw",GetIniFile("" & channel & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & channel & ".txt","Sync","Throwtype",GetIniFile("" & channel & ".txt","Sync","Throwtype","") + "+v" Active = Active -- 1 End If ElseIf GetIniFile("" & channel & ".txt",Shost,"Mod","")="Yes" then If not GetIniFile("" & channel & ".txt",Shost,"Admin","")="Yes" and not GetIniFile("" & channel & ".txt","op","Set","")="2" then WriteIniFile"" & channel & ".txt","Sync","Throw",GetIniFile("" & channel & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & channel & ".txt","Sync","Throwtype",GetIniFile("" & channel & ".txt","Sync","Throwtype","") + "+v" Active = Active -- 1 End If ElseIf GetIniFile("" & channel & ".txt",Shost,"Host","")=Shost then WriteIniFile"" & channel & ".txt","Sync","Throw",GetIniFile("" & channel & ".txt","Sync","Throw","") + " " & Sname & "" Writeinifile"" & channel & ".txt","Sync","Throwtype",GetIniFile("" & channel & ".txt","Sync","Throwtype","") + "+v" Active = Active -- 1 End If End If If Active = "5" or Active = "6" then SendCommand "/mode " & channel & " " & GetIniFile("" & channel & ".txt","Sync","Throwtype","") & " " & GetIniFile("" & channel & ".txt","Sync","Throw","") & "",ServerNumber Writeinifile"" & channel & ".txt","Sync","Throwtype","" WriteIniFile"" & channel & ".txt","Sync","Throw","" Active = "0" End If End If ElseIf not GetIniFile("" & channel & ".txt","Sync","Throwtype","")="" then SendCommand "/mode " & channel & " " & GetIniFile("" & channel & ".txt","Sync","Throwtype","") & " " & GetIniFile("" & channel & ".txt","Sync","Throw","") & "",ServerNumber Writeinifile"" & channel & ".txt","Sync","Throwtype","" WriteIniFile"" & channel & ".txt","Sync","Throw","" Active = "0" SendCommand "/notice " & Nickname & " The list is up to date",ServerNumber Else SendCommand "/notice " & Nickname & " The list is up to date",ServerNumber End If Loop End If Case "move" If GetIniFile("" & Channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" then If Not Setup="" or not Pass="" or not Snick="" or not Snick2="" then SendCommand "/notice " & Nickname & " Error: This service is currently busy. Please try again in 30 seconds",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",words(1),"Host","")="" then SendCommand "/notice " & Nickname & " User " & words(1) & " does not exist! You need an exact nickname",ServerNumber ElseIf words(1)=Getidentifier("$me",ServerNumber) or words(2)=Getidentifier("$me",ServerNumber) then SendCommand "/notice " & Nickname & " Error: You cannot perform this action!",Servernumber ElseIf words(1)=Nickname and GetIniFile("" & Channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Special","") ="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot perform this action!",Servernumber ElseIf Left(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & words(1) & ").mask,2)",ServerNumber),"Host",""),1)="s" or Left(GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",words(1),"Host",""),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " " & words(1) & " is suspended!",ServerNumber ElseIf GetIdentifier("$mask($nick(" & Channel & "," & words(2) & ").mask,2)",ServerNumber)="$null" then SendCommand "/notice " & Nickname & " Error: You can only move an account to an active user!",ServerNumber ElseIf words(2)=Nickname then SendCommand "/notice " & Nickname & " Error: You cannot overwrite your own profile!",Servernumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & words(1) & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & words(2) & ").mask,2)",ServerNumber) then SendCommand "/notice " & Nickname & " Error: You aren't moving anything or the user has the same host",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & words(2) & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & words(2) & ").mask,2)",ServerNumber) then If words(1)=Nickname then SendCommand "/notice " & Nickname & " WARNING: You will lose all bot control in your channel and trade ownership to " & words(2) & "",ServerNumber End If SendCommand "/notice " & Nickname & " User " & words(2) & " has an account which will be overwritten! Proceed? (" & Tool & "Yes," & Tool & "No)",ServerNumber Setup="5" Snick=GetIniFile("" & Channel & ".txt",words(1),"Host","") Snick2=GetIdentifier("$mask($nick(" & Channel & "," & words(2) & ").mask,2)",ServerNumber) Pass=Host SendCommand "/timer sdog1 1 30 /! OnMove",ServerNumber SendCommand "/timer sdog3 1 30 /notice " & Nickname & " Transfer cancelled!",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",words(2),"Host",""),"Host","")="" and not words(1)=words(2) then SendCommand "/notice " & Nickname & " Error: " & words(2) & " is using a registered nickname. " & words(2) & " must change nicknames, authenticate or use the original account holder nickname",ServerNumber Else If words(1)=Nickname then SendCommand "/notice " & Nickname & " WARNING: You will lose all bot control in your channel and trade ownership to " & words(2) & "",ServerNumber End If SendCommand "/notice " & Nickname & " User " & words(2) & " does not have an account and will gain the profile of " & words(1) & ". Proceed? (" & Tool & "Yes," & Tool & "No)",ServerNumber Setup="5" Pass=Host Snick=GetIniFile("" & Channel & ".txt",words(1),"Host","") Snick2=GetIdentifier("$mask($nick(" & Channel & "," & words(2) & ").mask,2)",ServerNumber) SendCommand "/timer sdog1 1 30 /! OnMove",Servernumber SendCommand "/timer sdog3 1 30 /notice " & Nickname & " Transfer cancelled!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End If Case "kick", "k" If words(1)=GetIdentifier("$me",ServerNumber) then SendCommand "/msg " & Channel & " Nope :P",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then If getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","")="Yes" then If words(1) = Nickname then SendCommand "/kick " & Channel & " " & words(1) & " Ha, you kicked yourself...",ServerNumber ElseIf GetIdentifier("$mask($nick(" & channel & "," & words(1) & ").mask,2)",ServerNumber)="$null" then SendCommand "/notice " & Nickname & " Error: This is not an active user!",ServerNumber Elseif GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & words(1) & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Sorry, that user is protected",ServerNumber ElseIf getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","")="No" and getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & words(1) & ").mask,2)",ServerNumber),"Admin","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot kick a higher power",ServerNumber ElseIf getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","")="Yes" and getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & words(1) & ").mask,2)",ServerNumber),"Mod","")="Yes" and not getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot kick other mods!",ServerNumber ElseIf LCase(Words(0))="" & Tool & "k" then SendCommand "/kick " & Channel & " " & Mid(Message,4) & " ~ " & Nickname & "",ServerNumber Else SendCommand "/kick " & Channel & " " & Mid(Message,7) & " ~ " & Nickname & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End if Case "unban", "ub" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then If getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","")="Yes" then SendCommand "/msg chanserv " & Channel & " delban " & words(1) & "",ServerNumber Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End if Case "user" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Host","")=GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber) then If not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,7) & ").mask,2)",ServerNumber),"Host","")= "" and not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,7) & ").mask,2)",ServerNumber),"Admin","")= "" then If not Left(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,7) & ").mask,2)",ServerNumber),"Host",""),1)="s" then If Not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,7) & ").mask,2)",ServerNumber),"Join","")="" and not Left(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,7) & ").mask,2)",ServerNumber),"Join",""),1)="&" then SendCommand "/notice " & Nickname & " Join Message: " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,7) & ").mask,2)",ServerNumber),"Join","") & "",ServerNumber End If If GetIniFile("" & channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,7) & ").mask,2)",ServerNumber),"Special","")="S" then Spad="-R-" End If SendCommand "/notice " & Nickname & " " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,7) & ").mask,2)",ServerNumber),"Nick","") & ": Is a mod= " & getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,7) & ").mask,2)",ServerNumber),"Mod","") & " ; Has admin= " & Spad & "" & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,7) & ").mask,2)",ServerNumber),"Admin","") & " ; Is protected= " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,7) & ").mask,2)",ServerNumber),"Protect","") & " ; Host= " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,7) & ").mask,2)",ServerNumber),"Host","") & "",ServerNumber Else SendCommand "/notice " & Nickname & " This account is currently suspended!",ServerNumber End If ElseIf Not GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,7),"Host",""),"Host","")="" and not GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,7),"Host",""),"Admin","")="" then If not Left(GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,7),"Host",""),"Host",""),1)="s" then If Not GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,7),"Host",""),"Join","")="" and not Left(GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,7),"Host",""),"Join",""),1)="&" then SendCommand "/notice " & Nickname & " Join Message: " & GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,7),"Host",""),"Join","") & "",ServerNumber End If If not GetIdentifier("$mask($nick(" & channel & "," & words(1) & ").mask,2)",ServerNumber)="$null" then SendCommand "/notice " & Nickname & " Warning: This active user may be a fake or is not authed!",ServerNumber End If If GetIniFile("" & channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,7),"Host",""),"Special","")="S" then Spad="-R-" End If SendCommand "/notice " & Nickname & " " & GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,7),"Host",""),"Nick","") & ": Is a mod= " & getIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,7),"Host",""),"Mod","") & " ; Has admin= " & Spad & "" & GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,7),"Host",""),"Admin","") & " ; Is protected= " & GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,7),"Host",""),"Protect","") & " ; Host= " & GetIniFile("" & Channel & ".txt",Mid(Message,7),"Host","") & "",ServerNumber Else SendCommand "/notice " & Nickname & " This account is currently suspended!",ServerNumber End if Else SendCommand "/notice " & Nickname & " User " & Mid(Message,7) & " does not exist",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not registered!",ServerNumber End If Case "ban", "b" If words(1)=GetIdentifier("$me",ServerNumber) then SendCommand "/msg " & Channel & " Nope :P",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","")="Yes" then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & words(1) & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " " & words(1) & " is protected!",ServerNumber ElseIf GetIdentifier("$mask($nick(" & channel & "," & words(1) & ").mask,2)",ServerNumber)="$null" then SendCommand "/notice " & Nickname & " Error: This is not an active user!",ServerNumber ElseIf getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","")="Yes" and getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & words(1) & ").mask,2)",ServerNumber),"Admin","")="Yes" and not getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot ban other admins!",ServerNumber ElseIf getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","")="Yes" and getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & words(1) & ").mask,2)",ServerNumber),"Admin","")="Yes" and not getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot ban a higher power",ServerNumber ElseIf getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","")="Yes" and getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & words(1) & ").mask,2)",ServerNumber),"Mod","")="Yes" and not getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot ban other mods!",ServerNumber Else WriteIniFile"" & Channel & ".txt","Lastban","Ban",GetIdentifier("$mask($nick(" & Channel & "," & words(1) & ").mask,2)",ServerNumber) If LCase(Words(0))="" & Tool & "b" then SendCommand "/ban " & Channel & " " & words(1) & "",ServerNumber SendCommand "/kick " & Channel & " " & Mid(Message,4) & " ~ " & Nickname & "",ServerNumber Else SendCommand "/ban " & Channel & " " & words(1) & "",ServerNumber SendCommand "/kick " & Channel & " " & Mid(Message,6) & " ~ " & Nickname & "",ServerNumber SendCommand "/ban " & Channel & " " & words(1) & "",ServerNumber End If End If Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Case "addban" If not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: Not a channel owner",ServerNumber Elseif not mid(Message,9)="" then WriteIniFile"" & Channel & ".txt","Lastban","Ban",words(1) SendCommand "/msg ChanServ " & Channel & " Addban " & Mid(Message,9) & "",ServerNumber End If Case "delban" If not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: Not a channel owner",ServerNumber Else SendCommand "/msg ChanServ " & Channel & " delban " & Mid(Message,9) & "",ServerNumber End If Case "undoban", "udb", "sorry" If getIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","")="Yes" then If GetIniFile("" & Channel & ".txt","Lastban","Ban","")="" then SendCommand "/notice " & Nickname & " Error: No recent bans!",ServerNumber Else SendCommand "/msg chanserv " & Channel & " delban " & GetIniFile("" & Channel & ".txt","Lastban","Ban","") & "",ServerNumber WriteIniFile"" & Channel & ".txt","Lastban","Ban","" End If Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Case "suspend" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","") ="Yes" then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Nick","")="" and GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host","")="" then SendCommand "/notice " & Nickname & " User " & Mid(Message,10) & " does not exist",ServerNumber Elseif GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Admin","") ="Yes" and not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot suspend other admins!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Special","")="S" then SendCommand "/notice " & Nickname & " Sorry, you are restricted from using this command!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Admin","")="Yes" and not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot suspend other admins!",ServerNumber ElseIf Left(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Host",""),1)="s" or Left(GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " Error: This user is already suspended!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Protect","")="Yes" or GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " " & Mid(Message,10) & " is protected!",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Host","")="" then Banner = GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Mod","") WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Mod","s " & Banner & "" Banner = GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Admin","") WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Admin","s " & Banner & "" Banner = GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Host","") WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Host","s " & Banner & "" SendCommand "/notice " & Nickname & " User suspended!",ServerNumber If IsOp(Mid(Message,10),Channel,ServerNumber) then sendcommand "/mode " & Channel & " -o " & Mid(Message,10) & "",ServerNumber If IsVoice(Mid(Message,10),Channel,ServerNumber) then sendcommand "/mode " & Channel & " -v " & Mid(Message,10) & "",ServerNumber Else Banner = Getinifile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Mod","") WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Mod","s " & Banner & "" Banner = Getinifile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Admin","") WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Admin","s " & Banner & "" Banner = GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber) WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Host","s " & Banner & "" SendCommand "/notice " & Nickname & " User suspended!",ServerNumber If IsOp(Mid(Message,10),Channel,ServerNumber) then sendcommand "/mode " & Channel & " -o " & Mid(Message,10) & "",ServerNumber If IsVoice(Mid(Message,10),Channel,ServerNumber) then sendcommand "/mode " & Channel & " -v " & Mid(Message,10) & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel admin!",ServerNumber End If Case "unsuspend" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","") ="Yes" then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,12) & ").mask,2)",ServerNumber),"Nick","")="" and GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host","")="" then SendCommand "/notice " & Nickname & " User " & Mid(Message,12) & " does not exist",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Special","")="S" then SendCommand "/notice " & Nickname & " Sorry, you are restricted from using this command!",ServerNumber Elseif GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,12) & ").mask,2)",ServerNumber),"Admin","") ="Yes" and not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot unsuspend other admins!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host",""),"Admin","")="Yes" and not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: You cannot unsuspend other admins!",ServerNumber ElseIf not Left(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,12) & ").mask,2)",ServerNumber),"Host",""),1)="s" and not Left(GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host",""),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " Error: This user is not suspended!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,12) & ").mask,2)",ServerNumber),"Protect","")="Yes" or GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host",""),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " " & Mid(Message,12) & " is protected!",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host",""),"Host","")="" then Banner = Mid(GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host",""),"Mod",""),3) WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host",""),"Mod",Banner Banner = Mid(GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host",""),"Admin",""),3) WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host",""),"Admin",Banner Banner = Mid(GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host",""),"Host",""),3) WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host",""),"Host",Banner SendCommand "/notice " & Nickname & " User unsuspended!",ServerNumber sendcommand "/mode " & Channel & " +v " & Mid(Message,12) & "",ServerNumber Else Banner = Mid(Getinifile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,12) & ").mask,2)",ServerNumber),"Mod",""),3) WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,12) & ").mask,2)",ServerNumber),"Mod",Banner Banner = Mid(Getinifile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,12) & ").mask,2)",ServerNumber),"Admin",""),3) WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,12) & ").mask,2)",ServerNumber),"Admin",Banner Banner = GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,12) & ").mask,2)",ServerNumber) WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,12) & ").mask,2)",ServerNumber),"Host",Banner SendCommand "/notice " & Nickname & " User unsuspended!",ServerNumber sendcommand "/mode " & Channel & " +v " & Mid(Message,12) & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel admin!",ServerNumber End If Case "restrict" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","") ="Yes" then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,11) & ").mask,2)",ServerNumber),"Host","")="" and GetIniFile("" & Channel & ".txt",Mid(Message,11),"Host","")="" then SendCommand "/Notice " & Nickname & " That user does not exist!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,11) & ").mask,2)",ServerNumber),"Host",""),"Protect","")="Yes" or GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,11),"Host",""),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " That user is protected!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,11) & ").mask,2)",ServerNumber),"Host",""),"Admin","")="No" or GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,11),"Host",""),"Admin","")="No" then SendCommand "/notice " & Nickname & " Error: This command only works on admins!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,11) & ").mask,2)",ServerNumber),"Host",""),"Special","")="S" or GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,11),"Host",""),"Special","")="S" then SendCommand "/notice " & Nickname & " That user is already restricted!",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,11),"Host",""),"Host","")="" then WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,11),"Host",""),"Special","S" SendCommand "/notice " & Nickname & " User is now on admin restrictions!",ServerNumber Else WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,11) & ").mask,2)",ServerNumber),"Special","S" SendCommand "/notice " & Nickname & " User is now on admin restrictions!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End If Case "unrestrict" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","") ="Yes" then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(message,13) & ").mask,2)",ServerNumber),"Host","")="" and GetIniFile("" & Channel & ".txt",Mid(message,13),"Host","")="" then SendCommand "/Notice " & Nickname & " That user does not exist!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(message,13) & ").mask,2)",ServerNumber),"Host",""),"Protect","")="Yes" or GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(message,13),"Host",""),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " That user is protected!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(message,13) & ").mask,2)",ServerNumber),"Host",""),"Special","")="" and GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(message,13),"Host",""),"Special","")="" then SendCommand "/notice " & Nickname & " That user is not restricted!",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(message,13),"Host",""),"Host","")="" then WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(message,13),"Host",""),"Special","" SendCommand "/notice " & Nickname & " User is no longer on admin restrictions!",ServerNumber Else WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(message,13) & ").mask,2)",ServerNumber),"Special","" SendCommand "/notice " & Nickname & " User is no longer on admin restrictions!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End If Case "greet" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Mod","") ="Yes" then If GetIniFile("" & Channel & ".txt","Topic","Lock","")="On" and not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","") ="Yes" then SendCommand "/notice " & Nickname & " Cannot change greet! Reason: Locked by an admin",ServerNumber ElseIf Mid(Message,8)="" and Getinifile("" & Channel & ".txt","Joinmsg","Msg","")="" then SendCommand "/notice " & Nickname & " Error: Nothing to clear",ServerNumber Elseif Lcase(Mid(Message,8))="off" and Getinifile("" & Channel & ".txt","Joinmsg","Msg","")="&" then SendCommand "/notice " & nickname & " Error: Greet is already off!",ServerNumber Elseif Mid(Message,8)="" then Writeinifile"" & Channel & ".txt","Joinmsg","Msg","Welcome back!" SendCommand "/notice " & Nickname & " Default Greet message used", ServerNumber ElseIf Lcase(Mid(Message,8))="off" then Writeinifile"" & Channel & ".txt","Joinmsg","Msg","&" SendCommand "/notice " & Nickname & " Greet message off", ServerNumber Else Writeinifile"" & Channel & ".txt","Joinmsg","Msg",Mid(Message,8) SendCommand "/notice " & Nickname & " " & Mid(Message,8) & "", ServerNumber End if Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Case "infolock" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","") ="Yes" then If GetIniFile("" & Channel & ".txt","Topic","Lock","")="On" then WriteIniFile"" & Channel & ".txt","Topic","Lock","Off" SendCommand "/notice " & Nickname & " Info is now free to edit!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt","Topic","Lock","")="Off" then WriteIniFile"" & Channel & ".txt","Topic","Lock","On" SendCommand "/notice " & Nickname & " Info is now locked to editors!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel admin",ServerNumber End If Case "dtopic" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","") ="Yes" then If Mid(Message,9)="" then If Getinifile("" & Channel & ".txt","Topic","Ident","")="" then SendCommand "/notice " & nickname & " Error: Nothing to clear!",ServerNumber Else SendCommand "/topic " & channel & " Welcome to " & Channel & " || " & Getinifile("" & Channel & ".txt","Topic","Topic","") & "",ServerNumber Writeinifile"" & Channel & ".txt","Topic","Ident","Welcome to " & Channel & " ||" Sendcommand "/msg Chanserv " & Channel & " set defaulttopic Welcome to " & Channel & " || " & Getinifile("" & Channel & ".txt","Topic","Topic","") & "",ServerNumber SendCommand "/notice " & Nickname & " Default topic ident used!",ServerNumber End If ElseIf not Mid(Message,9)="" then If Getinifile("" & Channel & ".txt","Topic","Ident","")= Mid(Message,9) then SendCommand "/notice " & nickname & " Error: You are using the same default! Try &Trefresh to resolve any errors.",ServerNumber Else SendCommand "/topic " & channel & " " & Mid(Message,9) & " " & Getinifile("" & Channel & ".txt","Topic","Topic","") & "",ServerNumber Sendcommand "/msg Chanserv " & Channel & " set defaulttopic " & Mid(Message,9) & " " & Getinifile("" & Channel & ".txt","Topic","Topic","") & "",ServerNumber Writeinifile"" & Channel & ".txt","Topic","Ident",Mid(Message,9) End If End if Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End If Case "clearinfo" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","") ="Yes" then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,12) & ").mask,2)",ServerNumber),"Host","")="" and GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host","")="" then SendCommand "/Notice " & Nickname & " That user does not exist!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,12) & ").mask,2)",ServerNumber),"Host",""),"Protect","")="Yes" or GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host",""),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " That user is protected!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,12) & ").mask,2)",ServerNumber),"Host",""),"Join","")="" and GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host",""),"Join","")="" then SendCommand "/notice " & Nickname & " That user has no info to clear!",ServerNumber ElseIf Left(GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,12) & ").mask,2)",ServerNumber),"Host",""),"Join",""),1)="&" or Left(GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host",""),"Join",""),1)="&" then SendCommand "/notice " & Nickname & " Error: An admin has already cleared this user's info!",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host",""),"Join","")="" then WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,12),"Host",""),"Join","& " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Nick","") & "" SendCommand "/notice " & Nickname & " Info cleared!",ServerNumber Else WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,12) & ").mask,2)",ServerNumber),"Join","& " & GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Nick","") & "" SendCommand "/notice " & Nickname & " Info cleared!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel admin!",ServerNumber End If Case "op" oword = Split(Mid(Message,5) + " s"," ") ovoc = "0" Thumb = "" othumb = "" If Lcase(mid(Message,5))="off" and GetIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","") ="Yes" and GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,5) & ").mask,2)",ServerNumber)="$null" then If getinifile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Op","")="Off" then SendCommand "/notice " & Nickname & " Error: You already disabled automatic op for yourself!",ServerNumber Else writeinifile"" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Op","Off" SendCommand "/notice " & Nickname & " Auto op now off",ServerNumber End If ElseIf Lcase(mid(Message,5))="on" and GetIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","") ="Yes" and GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,5) & ").mask,2)",ServerNumber)="$null" then If getinifile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Op","")="" then SendCommand "/notice " & Nickname & " Error: You already enabled automatic op for yourself!",ServerNumber Else writeinifile"" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Op","" SendCommand "/notice " & Nickname & " Auto op now on (If applicable)",ServerNumber End If ElseIf GetIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" then Do while not ovoc > "7" If oword(ovoc) = "s" or ovoc = "7" then If not othumb = "" then SendCommand "/mode " & channel & " +oooooo " & othumb & "",ServerNumber End If If Not Thumb = "" then SendCommand "/notice " & Nickname & " Already opped users: " & Thumb & "",ServerNumber End If ovoc = "7" ElseIf IsOp(oword(ovoc),channel,ServerNumber) and not GetIdentifier("$mask($nick(" & channel & "," & oword(ovoc) & ").mask,2)",ServerNumber)="$null" then Thumb = Thumb + " " & oword(ovoc) & "" Elseif not GetIdentifier("$mask($nick(" & channel & "," & oword(ovoc) & ").mask,2)",ServerNumber)="$null" then othumb = othumb + " " & oword(ovoc) & "" End If ovoc = ovoc -- 1 Loop ElseIf GetIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") ="Yes" and not GetIniFile("" & channel & ".txt","op","Set","")="0" then Do while not ovoc > "7" If oword(ovoc) = "s" or ovoc = "7" then If not othumb = "" then SendCommand "/mode " & channel & " +oooooo " & othumb & "",ServerNumber End If If Not Thumb = "" then SendCommand "/notice " & Nickname & " Already opped users: " & Thumb & "",ServerNumber End If ovoc = "7" ElseIf IsOp(oword(ovoc),channel,ServerNumber) and not GetIdentifier("$mask($nick(" & channel & "," & oword(ovoc) & ").mask,2)",ServerNumber)="$null" then Thumb = Thumb + " " & oword(ovoc) & "" Elseif not GetIdentifier("$mask($nick(" & channel & "," & oword(ovoc) & ").mask,2)",ServerNumber)="$null" then othumb = othumb + " " & oword(ovoc) & "" End If ovoc = ovoc -- 1 Loop Else SendCommand "/notice " & Nickname & " Error: No permission!",Servernumber End If Case "deop" Oword = Split(Mid(Message,Len(words(0)) -- 2) + " s"," ") Ovoc = "0" Thumb = "" Othumb = "" OPthumb = "" If GetIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Protect","") ="Yes" then Do while not Ovoc > "7" If Oword(Ovoc) = "s" or Ovoc = "7" then If not Othumb = "" then SendCommand "/mode " & channel & " -oooooo " & Othumb & "",ServerNumber End If If Not Thumb = "" and not OPthumb="" then SendCommand "/notice " & Nickname & " Already deopped users: " & Thumb & " - You cannot deop these users: " & OPthumb & "",ServerNumber Else If not OPthumb = "" then SendCommand "/notice " & Nickname & " You cannot deop these users: " & OPthumb & "",ServerNumber End If If Not Thumb = "" then SendCommand "/notice " & Nickname & " Already deopped users: " & Thumb & "",ServerNumber End If End If Ovoc = "7" ElseIf not IsOp(Oword(Ovoc),channel,ServerNumber) and not GetIdentifier("$mask($nick(" & channel & "," & Oword(Ovoc) & ").mask,2)",ServerNumber)="$null" then Thumb = Thumb + " " & Oword(Ovoc) & "" Elseif GetIniFile("" & channel & ".txt",GetIdentifier("$mask($nick(" & channel & "," & Oword(Ovoc) & ").mask,2)",ServerNumber),"Protect","")="Yes" and not GetIniFile("" & channel & ".txt",GetIdentifier("$mask($nick(" & channel & "," & Oword(Ovoc) & ").mask,2)",ServerNumber),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then OPthumb = OPthumb + " " & Oword(Ovoc) & "" Elseif not GetIdentifier("$mask($nick(" & channel & "," & Oword(Ovoc) & ").mask,2)",ServerNumber)="$null" then Othumb = Othumb + " " & Oword(Ovoc) & "" End If Ovoc = Ovoc -- 1 Loop ElseIf GetIniFile("" & channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Admin","") ="Yes" and not GetIniFile("" & channel & ".txt","op","Set","")="0" then Do while not Ovoc > "7" If Oword(Ovoc) = "s" or Ovoc = "7" then If not Othumb = "" then SendCommand "/mode " & channel & " -oooooo " & Othumb & "",ServerNumber End If If Not Thumb = "" and not OPthumb="" then SendCommand "/notice " & Nickname & " Already deopped users: " & Thumb & " - You cannot deop these users: " & OPthumb & "",ServerNumber Else If not OPthumb = "" then SendCommand "/notice " & Nickname & " You cannot deop these users: " & OPthumb & "",ServerNumber End If If Not Thumb = "" then SendCommand "/notice " & Nickname & " Already deopped users: " & Thumb & "",ServerNumber End If End If Ovoc = "7" ElseIf not IsOp(Oword(Ovoc),channel,ServerNumber) and not GetIdentifier("$mask($nick(" & channel & "," & Oword(Ovoc) & ").mask,2)",ServerNumber)="$null" then Thumb = Thumb + " " & Oword(Ovoc) & "" Elseif GetIniFile("" & channel & ".txt",GetIdentifier("$mask($nick(" & channel & "," & Oword(Ovoc) & ").mask,2)",ServerNumber),"Admin","")="Yes" and not GetIniFile("" & channel & ".txt",GetIdentifier("$mask($nick(" & channel & "," & Oword(Ovoc) & ").mask,2)",ServerNumber),"Host","")=Getidentifier("$mask(" & Nickname & "!" & Host & ",2)") then OPthumb = OPthumb + " " & Oword(Ovoc) & "" Elseif not GetIdentifier("$mask($nick(" & channel & "," & Oword(Ovoc) & ").mask,2)",ServerNumber)="$null" then Othumb = Othumb + " " & Oword(Ovoc) & "" End If Ovoc = Ovoc -- 1 Loop Else SendCommand "/notice " & Nickname & " Error: No permission!",Servernumber End If Case "voice", "v" If GetIniFile("" & Channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","") ="Yes" then Vword = Split(Mid(Message,Len(Words(0)) -- 2) + " s"," ") Lvoc = "0" Thumb = "" Vthumb = "" Do while not Lvoc > "7" If Vword(Lvoc) = "s" or Lvoc = "7" then If not Vthumb = "" then SendCommand "/mode " & Channel & " +vvvvvv " & Vthumb & "",ServerNumber End If If Not Thumb = "" then SendCommand "/notice " & Nickname & " Already voiced users: " & Thumb & "",ServerNumber End If Lvoc = "7" ElseIf IsVoice(Vword(Lvoc),channel,ServerNumber) and not GetIdentifier("$mask($nick(" & Channel & "," & Vword(Lvoc) & ").mask,2)",ServerNumber)="$null" then Thumb = Thumb + " " & Vword(Lvoc) & "" Elseif not GetIdentifier("$mask($nick(" & Channel & "," & Vword(Lvoc) & ").mask,2)",ServerNumber)="$null" then Vthumb = Vthumb + " " & Vword(Lvoc) & "" End If Lvoc = Lvoc -- 1 Loop Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Case "devoice", "dv" If GetIniFile("" & Channel & ".txt",Getidentifier("$mask(" & Nickname & "!" & Host & ",2)"),"Mod","") ="Yes" then Vword = Split(Mid(Message,Len(Words(0)) -- 2) + " s"," ") Lvoc = "0" Thumb = "" Vthumb = "" VPthumb = "" Do while not Lvoc > "7" If Vword(Lvoc) = "s" or Lvoc = "7" then If not Vthumb = "" then SendCommand "/mode " & Channel & " -vvvvvv " & Vthumb & "",ServerNumber End If If Not Thumb = "" and not VPthumb = "" then SendCommand "/notice " & Nickname & " Already devoiced users: " & Thumb & " - You cannot devoice these users: " & VPthumb & "",ServerNumber Else If Not Thumb = "" then SendCommand "/notice " & Nickname & " Already devoiced users: " & Thumb & "",ServerNumber End If If not VPthumb = "" then SendCommand "/notice " & Nickname & " You cannot devoice these users: " & VPthumb & "",ServerNumber End If End If Lvoc = "7" ElseIf not IsVoice(Vword(Lvoc),channel,ServerNumber) and not GetIdentifier("$mask($nick(" & Channel & "," & Vword(Lvoc) & ").mask,2)",ServerNumber)="$null" then Thumb = Thumb + " " & Vword(Lvoc) & "" Elseif GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Vword(Lvoc) & ").mask,2)",ServerNumber),"Protect","")="Yes" then VPthumb = VPthumb + " " & Vword(Lvoc) & "" Elseif not GetIdentifier("$mask($nick(" & Channel & "," & Vword(Lvoc) & ").mask,2)",ServerNumber)="$null" then Vthumb = Vthumb + " " & Vword(Lvoc) & "" End If Lvoc = Lvoc -- 1 Loop Else SendCommand "/notice " & Nickname & " Error: Not a channel moderator!",ServerNumber End If Case "moderate" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","") ="Yes" then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,11) & ").mask,2)",ServerNumber),"Nick","")="" and GetIniFile("" & Channel & ".txt",Mid(Message,11),"Host","")="" then SendCommand "/notice " & Nickname & " User " & Mid(Message,11) & " does not exist",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,11) & ").mask,2)",ServerNumber),"Mod","")="Yes" or GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,11),"Host",""),"Mod","")="Yes" then SendCommand "/notice " & Nickname & " " & Mid(Message,11) & " Already has moderation",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Special","")="S" then SendCommand "/notice " & Nickname & " Sorry, you are restricted from using this command!",ServerNumber ElseIf Left(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,11) & ").mask,2)",ServerNumber),"Host",""),1)="s" or Left(GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,11),"Host",""),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " " & Mid(Message,11) & " is suspended!",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,11) & ").mask,2)",ServerNumber),"Host","")="" then WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,11) & ").mask,2)",ServerNumber),"Mod","Yes" SendCommand "/notice " & Nickname & " " & Mid(Message,11) & " is now a moderator",ServerNumber If GetIniFile("" & Channel & ".txt","op","Set","")="2" then SendCommand "/mode " & Channel & " +o " & Mid(Message,11) & "",ServerNumber End If Else WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,11),"Host",""),"Mod","Yes" SendCommand "/notice " & Nickname & " " & Mid(Message,11) & " is now a moderator",ServerNumber If GetIniFile("" & Channel & ".txt","op","Set","")="2" then SendCommand "/mode " & Channel & " +o " & Mid(Message,11) & "",ServerNumber End If End If Else SendCommand "/notice " & Nickname & " Error: Not a channel admin!",ServerNumber End If Case "demoderate" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","") ="Yes" then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,13) & ").mask,2)",ServerNumber),"Nick","")="" and GetIniFile("" & Channel & ".txt",Mid(Message,13),"Host","")="" then SendCommand "/notice " & Nickname & " User " & Mid(Message,13) & " does not exist",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,13) & ").mask,2)",ServerNumber),"Protect","")="Yes" or GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,13),"Host",""),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " " & Mid(Message,13) & " is protected!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Special","")="S" then SendCommand "/notice " & Nickname & " Sorry, you are restricted from using this command!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,13) & ").mask,2)",ServerNumber),"Mod","")="No" or GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,13),"Host",""),"Mod","")="No" then SendCommand "/notice " & Nickname & " " & Mid(Message,13) & " is not a moderator",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,13) & ").mask,2)",ServerNumber),"Admin","")="Yes" or GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,13),"Host",""),"Admin","")="Yes" then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","")="Yes" then If not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,13) & ").mask,2)",ServerNumber),"Host","")="" then WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,13) & ").mask,2)",ServerNumber),"Mod","No" WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,13) & ").mask,2)",ServerNumber),"Admin","No" SendCommand "/notice " & Nickname & " " & Mid(Message,13) & " is no longer a moderator or admin",ServerNumber SendCommand "/mode " & Channel & " -o " & Mid(Message,13) & "",ServerNumber SendCommand "/mode " & Channel & " +v " & Mid(Message,13) & "",ServerNumber Else WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,13),"Host",""),"Mod","No" WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,13),"Host",""),"Admin","No" SendCommand "/notice " & Nickname & " " & Mid(Message,13) & " is no longer a moderator or admin",ServerNumber SendCommand "/mode " & Channel & " -o " & Mid(Message,13) & "",ServerNumber SendCommand "/mode " & Channel & " +v " & Mid(Message,13) & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: You cannot delete this admin!",ServerNumber End If ElseIf not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,13) & ").mask,2)",ServerNumber),"Host","")="" then WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,13) & ").mask,2)",ServerNumber),"Mod","No" SendCommand "/notice " & Nickname & " " & Mid(Message,13) & " is no longer a moderator",ServerNumber SendCommand "/mode " & Channel & " -o " & Mid(Message,13) & "",ServerNumber Else WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,13),"Host",""),"Mod","No" SendCommand "/notice " & Nickname & " " & Mid(Message,13) & " is no longer a moderator",ServerNumber SendCommand "/mode " & Channel & " -o " & Mid(Message,13) & "",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel admin!",ServerNumber End if Case "admin" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","") ="Yes" then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,8) & ").mask,2)",ServerNumber),"Nick","")="" and GetIniFile("" & Channel & ".txt",Mid(Message,8),"Host","")="" then SendCommand "/notice " & Nickname & " User " & Mid(Message,8) & " does not exist",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,8) & ").mask,2)",ServerNumber),"Admin","")="Yes" or GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,8),"Host",""),"Admin","")="Yes" then SendCommand "/notice " & Nickname & " " & Mid(Message,8) & " Already has admin",ServerNumber ElseIf Left(GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,8) & ").mask,2)",ServerNumber),"Host",""),1)="s" or Left(GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,8),"Host",""),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " " & Mid(Message,8) & " is suspended!",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,8) & ").mask,2)",ServerNumber),"Host","")="" then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,8) & ").mask,2)",ServerNumber),"Mod","")="No" then WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,8) & ").mask,2)",ServerNumber),"Mod","Yes" End If WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,8) & ").mask,2)",ServerNumber),"Admin","Yes" If not GetIniFile("" & Channel & ".txt","op","Set","")="0" then SendCommand "/mode " & Channel & " +o " & Mid(Message,8) & "",ServerNumber End If SendCommand "/notice " & Nickname & " " & Mid(Message,8) & " Now has admin",ServerNumber Else If GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,8),"Host",""),"Mod","")="No" then WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,8),"Host",""),"Mod","Yes" End If WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,8),"Host",""),"Admin","Yes" If not GetIniFile("" & Channel & ".txt","op","Set","")="0" then SendCommand "/mode " & Channel & " +o " & Mid(Message,8) & "",ServerNumber End If SendCommand "/notice " & Nickname & " " & Mid(Message,8) & " Now has admin",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End If Case "deadmin" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","") ="Yes" then If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Nick","")="" and GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host","")="" then SendCommand "/notice " & Nickname & " User " & Mid(Message,10) & " does not exist",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Protect","")="Yes" or GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " " & Mid(Message,10) & " is protected!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Admin","")="No" or GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Admin","")="No" then SendCommand "/notice " & Nickname & " " & Mid(Message,10) & " Does not have admin",ServerNumber ElseIf not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Host","")="" then WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Admin","No" WriteIniFile"" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Special","" If not GetIniFile("" & Channel & ".txt","op","Set","")="2" then SendCommand "/mode " & Channel & " -o " & Mid(Message,10) & "",ServerNumber End if SendCommand "/mode " & Channel & " +v " & Mid(Message,10) & "",ServerNumber SendCommand "/notice " & Nickname & " " & Mid(Message,10) & " No longer has admin",ServerNumber Else WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Admin","No" WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Special","" SendCommand "/notice " & Nickname & " " & Mid(Message,10) & " No longer has admin",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End if Case "setop" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","") ="Yes" then If Lcase(Mid(Message,8))="0" then If GetIniFile("" & Channel & ".txt","op","Set","")="0" then SendCommand "/notice " & Nickname & " Error: Auto op is already set to owner only!",ServerNumber Else writeIniFile"" & Channel & ".txt","op","Set","0" SendCommand "/notice " & Nickname & " Only channel owner will now get op",ServerNumber End If ElseIf Lcase(Mid(Message,8))="1" then If GetIniFile("" & Channel & ".txt","op","Set","")="1" then SendCommand "/notice " & Nickname & " Error: Auto op is already set to admins and higher!",ServerNumber Else writeIniFile"" & Channel & ".txt","op","Set","1" SendCommand "/notice " & Nickname & " Only channel admins and higher will now get op",ServerNumber End If ElseIf Lcase(Mid(Message,8))="2" then If GetIniFile("" & Channel & ".txt","op","Set","")="2" then SendCommand "/notice " & Nickname & " Error: Auto op is already set to moderators and higher!",ServerNumber Else writeIniFile"" & Channel & ".txt","op","Set","2" SendCommand "/notice " & Nickname & " Warning: Only channel moderators and higher will now get op (Not recommended)",ServerNumber End If ElseIf Mid(Message,8)="" then SendCommand "/notice " & Nickname & " Error: Please enter/set this mode to either 0,1,2 following the command!",ServerNumber Else SendCommand "/notice " & Nickname & " Error: Please set this mode to either 0,1,2!",ServerNumber End If Else SendCommand "/notice " & Nickname & " Error: Not a channel owner!",ServerNumber End If Case "deluser" If GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Admin","") ="Yes" then If Left(words(1),3)="*!*" then If GetIniFile("" & Channel & ".txt",words(1),"Admin","")="" then SendCommand "/Notice " & Nickname & " Host " & words(1) & " does not direct to any user profile!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",words(1),"Protect","")="Yes" then SendCommand "/notice " & Nickname & " Error: This user is protected!",ServerNumber ElseIf GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Special","")="S" then SendCommand "/notice " & Nickname & " Sorry, you are restricted from using this command!",ServerNumber ElseIf Left(GetIniFile("" & Channel & ".txt",words(1),"Host",""),1)="s" then SendCommand "/notice " & Nickname & " Error: This user is suspended!",ServerNumber Elseif not GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Nickname & ").mask,2)",ServerNumber),"Protect","") ="Yes" and GetIniFile("" & Channel & ".txt",words(1),"Admin","")="Yes" then Sendcommand "/notice " & Nickname & " Error: You cannot delete other admins!",ServerNumber Else SendCommand "/Notice " & Nickname & " " & GetIniFile("" & Channel & ".txt",words(1),"Nick","") & " has been unregistered!",ServerNumber WriteIniFile"" & Channel & ".txt",GetIniFile("" & Channel & ".txt",words(1),"Nick",""),"Host","" WriteIniFile"" & Channel & ".txt",words(1),"Nick", "Unregistered on " & Date & "" WriteIniFile"" & Channel & ".txt",words(1),"Host", "Unregistered by " & Host & "" WriteIniFile"" & Channel & ".txt",words(1),"Mod","" WriteIniFile"" & Channel & ".txt",words(1),"Admin","" WriteIniFile"" & Channel & ".txt",words(1),"Protect","" WriteIniFile"" & Channel & ".txt",words(1),"Join","" WriteIniFile"" & Channel & ".txt",words(1),"Note","" WriteIniFile"" & Channel & ".txt",words(1),"Seen","" writeinifile"" & Channel & ".txt",words(1),"Op","" WriteIniFile"" & Channel & ".txt",words(1),"Special","" End If ElseIf GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host","")="" and GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Host","")="" then SendCommand "/Notice " & Nickname & " User " & Mid(Message,10) & " does not exist",ServerNumber Else If GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Host",""),"Admin","")="" then SendCommand "/notice " & Nickname & " Please state " & GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Nick","") & "'s log to deluser: (" & Tool & "Deluser " & GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",Mid(Message,10),"Host",""),"Host","") & ") ",ServerNumber Else SendCommand "/Notice " & Nickname & " Please state " & GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Host",""),"Nick","") & "'s log to deluser: (" & Tool & "Deluser " & GetIniFile("" & Channel & ".txt",GetIniFile("" & Channel & ".txt",GetIdentifier("$mask($nick(" & Channel & "," & Mid(Message,10) & ").mask,2)",ServerNumber),"Host",""),"Host","") & ") ",ServerNumber End If End If Else SendCommand "/notice " & Nickname & " Error: Not a channel admin!",ServerNumber End If End Select End If End Sub Sub OnTutorial() Tutorial="" End Sub Sub OnSetup() Pass="" Setup="" End Sub Sub OnNewchan() Snick="" Setup="" Pass="" End Sub Sub OnMove() Snick="" Snick2="" Pass="" Setup="" End Sub Sub Ulist(Nickname,Channel,ServerNumber) lcount = "0" Num = "1" lsus = "0" lmod = "0" lad = "0" Sendcommand "/notice " & Nickname & " Nickname - Mod - Admin - Protect - Seen - Host",ServerNumber Do while not Num > 1500 If Mid(Left(Getidentifier("$read(" & Channel & ".txt," & Num & ")",ServerNumber),5),5)="@" then Uhost=Mid(Left(Getidentifier("$read(" & Channel & ".txt," & Num & ")",ServerNumber),len(Getidentifier("$read(" & Channel & ".txt," & Num & ")",ServerNumber)) - 1),2) If not Getinifile("" & Channel & ".txt",Uhost,"Mod","")="" then lcount = lcount -- 1 If Left(Getinifile("" & Channel & ".txt",Uhost,"Host",""),1)="s" then lsus = lsus -- 1 End If If Getinifile("" & Channel & ".txt",Uhost,"Mod","")="Yes" and not Getinifile("" & Channel & ".txt",Uhost,"Admin","")="Yes" then lmod = lmod -- 1 End If If Getinifile("" & Channel & ".txt",Uhost,"Admin","")="Yes" then lad = lad -- 1 End If Sendcommand "/notice " & Nickname & " " & Getinifile("" & Channel & ".txt",Uhost,"Nick","") & " - " & Getinifile("" & Channel & ".txt",Uhost,"Mod","") & " - " & Getinifile("" & Channel & ".txt",Uhost,"Admin","") & " - " & Getinifile("" & Channel & ".txt",Uhost,"Protect","") & " - " & Getinifile("" & Channel & ".txt",Uhost,"Seen","") & " - " & Uhost & "" End If End If Num = Num -- 1 If Num > 1500 then Sendcommand "/notice " & Nickname & " Listed " & lcount & " registered users, " & lsus & " suspended, " & lmod & " moderators and " & lad & " admins",ServerNumber End If Loop End Sub