a little modification please - Page 2
 

News:

29 December 2022 - PtokaX 0.5.3.0 (20th anniversary edition) released...
11 April 2017 - PtokaX 0.5.2.2 released...
8 April 2015 Anti child and anti pedo pr0n scripts are not allowed anymore on this board!
28 September 2015 - PtokaX 0.5.2.1 for Windows 10 IoT released...
3 September 2015 - PtokaX 0.5.2.1 released...
16 August 2015 - PtokaX 0.5.2.0 released...
1 August 2015 - Crowdfunding for ADC protocol support in PtokaX ended. Clearly nobody want ADC support...
30 June 2015 - PtokaX 0.5.1.0 released...
30 April 2015 Crowdfunding for ADC protocol support in PtokaX
26 April 2015 New support hub!
20 February 2015 - PtokaX 0.5.0.3 released...
13 April 2014 - PtokaX 0.5.0.2 released...
23 March 2014 - PtokaX testing version 0.5.0.1 build 454 is available.
04 March 2014 - PtokaX.org sites were temporary down because of DDOS attacks and issues with hosting service provider.

Main Menu

a little modification please

Started by [NL]trucker, 12 February, 2004, 09:46:49

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

[NL]trucker

i,ve jut copied it and gonna test it :-)
Owner of FunnyHub
 
Funyhub.no-ip.info
       Forum Master of


[NL]trucker

Nerbos


i just tested it and got this error

Script started.
Syntax error: attempt to perform arithmetic on a nil value
stack traceback:
   1:  function `DataArrival' at line 62 [file `D:\==PTOTAX==\gekkobeta5\scripts\kick-bot.lua']

Syntax error: attempt to perform arithmetic on a nil value
stack traceback:
   1:  function `DataArrival' at line 62 [file `D:\==PTOTAX==\gekkobeta5\scripts\kick-bot.lua']

Script stopped.
Owner of FunnyHub
 
Funyhub.no-ip.info
       Forum Master of


[NL]trucker

this is the script; i added a few lines in forbidden files

--------------------------------------------------------------------

-- Simple Illegalist v0.1
-- Created by Ptaczek, Jan-3, 2003
-- Searches for specified patterns. Useful for illegal share checking
-- some changes by Skippy and RabidWombat and OpiumVolage and trucker
-- add tables warn and kick by nErBoS

BotName = "=[Konsole#]="

function Main()
frmHub:RegBot(BotName)
frmHub:EnableSearchData(1)
end

Files = {
["childsex"]="NO sick Porn inhere!",
["childporn"]="NO sick kid Porn inhere!",
["underage"]="NO sick kid Porn inhere!",
["animalsex"]="NO Animalsex files here!",
["svastika"]="NO Nazi/white power music HERE!!!",
[".temp.mp3"]="NO sharing of incomplete downloads",
["_INCOMPLETE_"]="NO sharing of incomplete downloads",
["download123456789.dat"]="NO sharing of incomplete downloads",
["part.met"]="NO sharing of incomplete downloads",
[".getright"]="NO sharing of incomplete downloads",
[".vob"]="NO sharing of incomplete downloads",
["share faker"]="NO tools for fake sharing allowed",
["share hacker"]="No tools for fake sharing allowed",
["Netlimiter"] = "no tools for limiting speed allowed",
["czdc"] = "no sharing of fake clients",
["bcdc"] = "no sharing of fake clients",
}

warn = {}
kick = {}
usersimune = {"nErBoS", "[NL]trucker","(uk-kingdom)John","(UKD)John","[NL]{VIP}Geroni",
"[NL]Coco","[NL]Dark_bad_girl","[NL]DiGARiX","[NL]GePe","[NL]M@non","[NL]movieman","[NL]SuusTweety",
"[NL]voodoo","[NL]ZeroX","Chupi?","DoJiN","hhps","[UKD]jiorgee","Quaraf","Sweet_Bitch",
"TheWickedRabbit","Serima","[NL]partyfever","[NL]AiR"} -- Usres you want to not be checked

kicklog = "kicks.txt" -- In script folder
main = "Active" --- write Deactive and will not send the kicks and bans to the main


function NewUserConnected(user)
if (warn[user.sName] == nill) then -- this will solve the nill problem i think
warn[user.sName] = 0
end
if (kick[user.sName] == nill) then
kick[user.sName] = 0
end

for i,v in Files do
user:SendData("$Search Hub:"..BotName.." F?F?0?1?"..i)
end
end

function DataArrival(user, data)
 
if( strsub(data, 1, 3) == "$SR" ) then
_,_,nick = strfind( data, "\05(%S*)|$" )
local s = 5 + strlen(user.sName)
local e = strfind(data, "%d+%s%d+/%d+") - 2
local path = strsub(data, s, e)
if( nick == BotName) then
   for i=1,getn(usersimune) do
   if (user.bOperator or user.sName == usersimune) then
   return 1
   end
   end
   if (GetProfileName(user.iProfile) == "VIP") then
      if (kick[user.sName] == 3) then
         Reason = FindWhat(data)
         SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got ban. Reason: "..Reason.." FILE: "..path)
         user:SendPM(BotName,"You have been banned. "..Reason)
         if (main == "Active" ) then
            SendToAll(BotName, "The user "..user.sName.." is been banned for "..Reason)
         end
         if (main == "Deactive") then
            return 1
         end
         user:Ban()
      elseif (warn[user.sName] == 3 or kick[user.sName] == 1 or kick[user.sName] == 2) then
         warn[user.sName] = warn[user.sName] + 1
         kick[user.sName] = kick[user.sName] + 1
         Reason = FindWhat(data)
         SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..kick[user.sName].." kicks. Reason: "..Reason.." FILE: "..path)
         user:SendPM(BotName,"You have been kicked "..kick[user.sName].." time(s) at 3 you will be ban. "..Reason.." FILE: "..path)
         appendto(kicklog)
         write("\r\n"..user.sName.."|"..Reason.."|"..path.."|"..kick[user.sName].."|"..GetTime())
         writeto()
         if (main == "Active" ) then
            SendToAll(BotName, "The user "..user.sName.." is been kicked for "..Reason)
         end
         if (main == "Deactive") then
            return 1
         end
         user:TempBan()
      elseif (warn[user.sName] == 0 or warn[user.sName] == 1 or warn[user.sName] == 2) then
         warn[user.sName] = warn[user.sName] + 1
         Reason = FindWhat(data)
         SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..warn[user.sName].." warns. Reason: "..Reason.." FILE: "..path)
         user:SendPM(BotName, "You have been warned "..warn[user.sName].." time(s) at 3 you will be kicked. "..Reason.." FILE: "..path)
         user:SendPM(BotName, "You can come back when you have corrected the problem")
         user:SendPM(BotName, "Disconnected...")
         user:Disconnect()
      end
   elseif not(user.bOperator and GetProfileName(user.iProfile) == "VIP" and user.sName == usersimune) then --this will solve the double log i think
      if (kick[user.sName] == 3) then
         Reason = FindWhat(data)
         SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got ban. Reason: "..Reason.." FILE: "..path)
         user:SendPM(BotName,"You have been banned. "..Reason)
         if (main == "Active" ) then
            SendToAll(BotName, "The user "..user.sName.." is been banned for "..Reason)
         end
         if (main == "Deactive") then
            return 1
         end
         user:Ban()
      elseif (kick[user.sName] == 0 or kick[user.sName] == 1 or kick[user.sName] == 2) then
         kick[user.sName] = kick[user.sName] + 1
         Reason = FindWhat(data)
         SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..kick[user.sName].." kicks. Reason: "..Reason.." FILE: "..path)
         user:SendPM(BotName,"You have been kicked "..kick[user.sName].." time(s) at 3 you will be ban. "..Reason.." FILE: "..path)
         appendto(kicklog)
         write("\r\n"..user.sName.."|"..Reason.."|"..path.."|"..kick[user.sName].."|"..GetTime())
         writeto()
         if (main == "Active" ) then
            SendToAll(BotName, "The user "..user.sName.." is been kicked for "..Reason)
         end
         if (main == "Deactive") then
            return 1
         end
         user:TempBan()
      end
   end
end
end
end

function FindWhat(data)
for i,v in Files do
if( strfind(strlower(data), i) ) then
return v
end
end
return "Other files"
end  

function GetTime()
   s = date("%S")
   h = date("%H")
   m = date("%M")
   d = date("%d")
   mm = date("%m")
   y = date("%y")
   Date = "Day: "..d.."/"..mm.."/20"..y.." Hour: "..h..":"..m..":"..s
   return Date

end
Owner of FunnyHub
 
Funyhub.no-ip.info
       Forum Master of


nErBoS

Hi,

try this one..

-- Simple Illegalist v0.1 
-- Created by Ptaczek, Jan-3, 2003 
-- Searches for specified patterns. Useful for illegal share checking 
-- some changes by Skippy and RabidWombat and OpiumVolage and trucker 
-- add tables warn and kick by nErBoS 

BotName = "=[Konsole#]=" 

function Main() 
frmHub:RegBot(BotName) 
frmHub:EnableSearchData(1) 
end 

Files = {
[".dll"]="NO sick Porn inhere!",
["childsex"]="NO sick Porn inhere!", 
["childporn"]="NO sick kid Porn inhere!", 
["underage"]="NO sick kid Porn inhere!", 
["animalsex"]="NO Animalsex files here!", 
["svastika"]="NO Nazi/white power music HERE!!!", 
[".temp.mp3"]="NO sharing of incomplete downloads", 
["_INCOMPLETE_"]="NO sharing of incomplete downloads", 
["download123456789.dat"]="NO sharing of incomplete downloads", 
["part.met"]="NO sharing of incomplete downloads", 
[".getright"]="NO sharing of incomplete downloads", 
[".vob"]="NO sharing of incomplete downloads", 
["share faker"]="NO tools for fake sharing allowed", 
["share hacker"]="No tools for fake sharing allowed", 
["Netlimiter"] = "no tools for limiting speed allowed", 
["czdc"] = "no sharing of fake clients", 
["bcdc"] = "no sharing of fake clients", 
} 

warn = {} 
kick = {} 
usersimune = {"nErBoS", "[NL]trucker","(uk-kingdom)John","(UKD)John","[NL]{VIP}Geroni", 
"[NL]Coco","[NL]Dark_bad_girl","[NL]DiGARiX","[NL]GePe","[NL]M@non","[NL]movieman","[NL]SuusTweety", 
"[NL]voodoo","[NL]ZeroX","Chupi?","DoJiN","hhps","[UKD]jiorgee","Quaraf","Sweet_Bitch", 
"TheWickedRabbit","Serima","[NL]partyfever","[NL]AiR"} -- Usres you want to not be checked 

kicklog = "kicks.txt" -- In script folder 
main = "Active" --- write Deactive and will not send the kicks and bans to the main 


function NewUserConnected(user) 
if (warn[user.sName] == nil) then -- this will solve the nill problem i think 
warn[user.sName] = 0 
end 
if (kick[user.sName] == nil) then 
kick[user.sName] = 0 
end 

for i,v in Files do 
user:SendData("$Search Hub:"..BotName.." F?F?0?1?"..i) 
end 
end 

function DataArrival(user, data) 

if( strsub(data, 1, 3) == "$SR" ) then 
_,_,nick = strfind( data, "\05(%S*)|$" ) 
local s = 5 + strlen(user.sName) 
local e = strfind(data, "%d+%s%d+/%d+") - 2 
local path = strsub(data, s, e) 
if( nick == BotName) then 
for i=1,getn(usersimune) do 
if (user.bOperator or user.sName == usersimune[i]) then 
return 1 
end 
end 
if (GetProfileName(user.iProfile) == "VIP") then 
if (kick[user.sName] == 3) then 
Reason = FindWhat(data) 
SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got ban. Reason: "..Reason.." FILE: "..path) 
user:SendPM(BotName,"You have been banned. "..Reason) 
if (main == "Active" ) then 
SendToAll(BotName, "The user "..user.sName.." is been banned for "..Reason) 
end 
if (main == "Deactive") then 
return 1 
end 
user:Ban() 
elseif (warn[user.sName] == 3 or kick[user.sName] == 1 or kick[user.sName] == 2) then 
warn[user.sName] = warn[user.sName] + 1 
kick[user.sName] = kick[user.sName] + 1 
Reason = FindWhat(data) 
SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..kick[user.sName].." kicks. Reason: "..Reason.." FILE: "..path) 
user:SendPM(BotName,"You have been kicked "..kick[user.sName].." time(s) at 3 you will be ban. "..Reason.." FILE: "..path) 
appendto(kicklog) 
write("\r\n"..user.sName.."|"..Reason.."|"..path.."|"..kick[user.sName].."|"..GetTime()) 
writeto() 
if (main == "Active" ) then 
SendToAll(BotName, "The user "..user.sName.." is been kicked for "..Reason) 
end 
if (main == "Deactive") then 
return 1 
end 
user:TempBan() 
elseif (warn[user.sName] == 0 or warn[user.sName] == 1 or warn[user.sName] == 2) then 
warn[user.sName] = warn[user.sName] + 1 
Reason = FindWhat(data) 
SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..warn[user.sName].." warns. Reason: "..Reason.." FILE: "..path) 
user:SendPM(BotName, "You have been warned "..warn[user.sName].." time(s) at 3 you will be kicked. "..Reason.." FILE: "..path) 
user:SendPM(BotName, "You can come back when you have corrected the problem") 
user:SendPM(BotName, "Disconnected...") 
user:Disconnect() 
end 
elseif not(user.bOperator and GetProfileName(user.iProfile) == "VIP" and user.sName == usersimune[i]) then --this will solve the double log i think 
if (kick[user.sName] == 3) then 
Reason = FindWhat(data) 
SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got ban. Reason: "..Reason.." FILE: "..path) 
user:SendPM(BotName,"You have been banned. "..Reason) 
if (main == "Active" ) then 
SendToAll(BotName, "The user "..user.sName.." is been banned for "..Reason) 
end 
if (main == "Deactive") then 
return 1 
end 
user:Ban() 
elseif (kick[user.sName] == 0 or kick[user.sName] == 1 or kick[user.sName] == 2) then 
kick[user.sName] = kick[user.sName] + 1 
Reason = FindWhat(data) 
SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..kick[user.sName].." kicks. Reason: "..Reason.." FILE: "..path) 
user:SendPM(BotName,"You have been kicked "..kick[user.sName].." time(s) at 3 you will be ban. "..Reason.." FILE: "..path) 
appendto(kicklog) 
write("\r\n"..user.sName.."|"..Reason.."|"..path.."|"..kick[user.sName].."|"..GetTime()) 
writeto() 
if (main == "Active" ) then 
SendToAll(BotName, "The user "..user.sName.." is been kicked for "..Reason) 
end 
if (main == "Deactive") then 
return 1 
end 
user:TempBan() 
end 
end 
end 
end 
end 

function FindWhat(data) 
for i,v in Files do 
if( strfind(strlower(data), i) ) then 
return v 
end 
end 
return "Other files" 
end 

function GetTime() 
s = date("%S") 
h = date("%H") 
m = date("%M") 
d = date("%d") 
mm = date("%m") 
y = date("%y") 
Date = "Day: "..d.."/"..mm.."/20"..y.." Hour: "..h..":"..m..":"..s 
return Date 

end

I think that us that why i used  ==nill and should be ==nil  :)
Let's hope this time works.

Best regards, nErBoS
--## nErBoS Spot ##--

[NL]trucker

Nerbos

?????
----------------------------------------------------
Files = {
[".dll"]="NO sick Porn inhere!",
-----------------------------------------------------

did you add this line?


btw gonna try new script.
Owner of FunnyHub
 
Funyhub.no-ip.info
       Forum Master of


nErBoS

Hi,

Never mind that i use that to test the script to get dlls.
You can remove

Best regards, nErBoS
--## nErBoS Spot ##--

[NL]trucker

#31
nerbos

as far as i can see  the logs are looking great :-)

----------------------------------------------------------------

[NL]--Liekerdjuh|NO sharing of incomplete downloads| d:\ISO\DVD - Rip\Pirates Of The Caribbean\VIDEO_TS.VOB|1|Day: 18/02/2004 Hour: 16:01:37

--------------------------------------------------------------------

perfect job there m8.

and i dont mind you adding things to script i just noticed it and wanted to be sure it was you who did it.

will comment later on about bot again.



grrrrr  :rolleyes:  ?(

got this error again

------------------------------------------------
Syntax error: attempt to perform arithmetic on a nil value
stack traceback:
   1:  function `DataArrival' at line 63 [file `D:\==PTOTAX==\gekkobeta5\scripts\kick-bot.lua']



and not only logs; bot is showing in main also :)

-----------------------------------------------------------------
<=[Konsole#]=> The user rups is been kicked for NO sharing of incomplete downloads
---------------------------------------------------------------------
Owner of FunnyHub
 
Funyhub.no-ip.info
       Forum Master of


nErBoS

Hi,

I noticed that you are using the ptokax 0.3.3.0 debug try to use on the TD4 and see if the error happens.

Best regards, nErBoS
--## nErBoS Spot ##--

*??G??*

Syntax error: attempt to perform arithmetic on a nil value.......i get this error alot when using this script and i also noticed that if the same user gets kicked more than once the total amount times they have been kicked doesn't go up, it just adds another line to the kick.txt and showing that they have only been kicked 1 time even though they have been kicked 2 times

+--**T?T?? X???m?**--+   @    titanxtreme.kicks-ass.net

nErBoS

Hi,

Try this one..

-- Simple Illegalist v0.1 
-- Created by Ptaczek, Jan-3, 2003 
-- Searches for specified patterns. Useful for illegal share checking 
-- some changes by Skippy and RabidWombat and OpiumVolage and trucker 
-- add tables warn and kick by nErBoS

BotName = "Illegalist" 

function Main()
frmHub:RegBot(BotName) 
frmHub:EnableSearchData(1) 
end 

Files = { 
["childsex"]="NO sick Porn inhere!", 
["childporn"]="NO sick kid Porn inhere!", 
["underage"]="NO sick kid Porn inhere!", 
["animalsex"]="NO Animalsex files here!", 
["svastika"]="NO Nazi/white power music HERE!!!", 
[".temp.mp3"]="NO sharing of incomplete downloads", 
["_INCOMPLETE_"]="NO sharing of incomplete downloads", 
["download123456789.dat"]="NO sharing of incomplete downloads", 
["part.met"]="NO sharing of incomplete downloads", 
[".getright"]="NO sharing of incomplete downloads", 
[".vob"]="NO sharing of incomplete downloads", 
["share faker"]="NO tools for fake sharing allowed", 
["share hacker"]="No tools for fake sharing allowed"} 

warn = {}
kick = {}
usersimune = {"nErBoS", "[NL]trucker","(uk-kingdom)John","(UKD)John","[NL]{VIP}Geroni", 
"[NL]Coco","[NL]Dark_bad_girl","[NL]DiGARiX","[NL]GePe","[NL]M@non","[NL]movieman","[NL]SuusTweety", 
"[NL]voodoo","[NL]ZeroX","Chupi?","DoJiN","hhps","[UKD]jiorgee","Quaraf","Sweet_Bitch", 
"TheWickedRabbit","Serima","[NL]partyfever","[NL]AiR"} -- Usres you want to not be checked 

kicklog = "kicks.txt" -- In script folder
main = "Active" --- write Deactive and will not send the kicks and bans to the main


function NewUserConnected(user)
if (warn[user.sName] == nill or warn[user.sName] == 4) then 
warn[user.sName] = 0
end
if (kick[user.sName] == nill or kick[user.sName] == 4) then
kick[user.sName] = 0
end

for i,v in Files do 
user:SendData("$Search Hub:"..BotName.." F?F?0?1?"..i) 
end 
end 

function DataArrival(user, data)
 
if( strsub(data, 1, 3) == "$SR" ) then 
_,_,nick = strfind( data, "\05(%S*)|$" ) 
local s = 5 + strlen(user.sName)
local e = strfind(data, "%d+%s%d+/%d+") - 2
local path = strsub(data, s, e)
if( nick == BotName) then
	for i=1,getn(usersimune) do 
	if (user.bOperator or user.sName == usersimune[i]) then
	return 1
	end
	end
	if (GetProfileName(user.iProfile) == "VIP") then
		if (kick[user.sName] == 3) then
			kick[user.sName] = kick[user.sName] + 1
			Reason = FindWhat(data) 
			SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got ban. Reason: "..Reason.." FILE: "..path) 
			user:SendPM(BotName,"You have been banned. "..Reason)
			if (main == "Active" ) then
				SendToAll(BotName, "The user "..user.sName.." is been banned for "..Reason)
			end
			if (main == "Deactive") then
				return 1
			end
			user:Ban() 
		elseif (warn[user.sName] == 3 or kick[user.sName] == 1 or kick[user.sName] == 2) then
			warn[user.sName] = warn[user.sName] + 1
			kick[user.sName] = kick[user.sName] + 1
			Reason = FindWhat(data) 
			SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..kick[user.sName].." kicks. Reason: "..Reason.." FILE: "..path) 
			user:SendPM(BotName,"You have been kicked "..kick[user.sName].." time(s) at 3 you will be ban. "..Reason.." FILE: "..path)
			appendto(kicklog) 
			write("\r\n"..user.sName.."|"..Reason.."|"..path.."|"..kick[user.sName].."|"..GetTime()) 
			writeto()
			if (main == "Active" ) then
				SendToAll(BotName, "The user "..user.sName.." is been kicked for "..Reason)
			end
			if (main == "Deactive") then
				return 1
			end
			user:TempBan() 
		elseif (warn[user.sName] == 0 or warn[user.sName] == 1 or warn[user.sName] == 2) then
			warn[user.sName] = warn[user.sName] + 1
			Reason = FindWhat(data) 
			SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..warn[user.sName].." warns. Reason: "..Reason.." FILE: "..path) 
			user:SendPM(BotName, "You have been warned "..warn[user.sName].." time(s) at 3 you will be kicked. "..Reason.." FILE: "..path)
			user:SendPM(BotName, "You can come back when you have corrected the problem")
			user:SendPM(BotName, "Disconnected...") 
			user:Disconnect() 
		end
	elseif not(user.bOperator and GetProfileName(user.iProfile) == "VIP" and user.sName == usersimune[i]) then --this will solve the double log i think
		if (kick[user.sName] == 3) then
			kick[user.sName] = kick[user.sName] + 1
			Reason = FindWhat(data) 
			SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got ban. Reason: "..Reason.." FILE: "..path) 
			user:SendPM(BotName,"You have been banned. "..Reason)
			if (main == "Active" ) then
				SendToAll(BotName, "The user "..user.sName.." is been banned for "..Reason)
			end
			if (main == "Deactive") then
				return 1
			end
			user:Ban() 
		elseif (kick[user.sName] == 0 or kick[user.sName] == 1 or kick[user.sName] == 2) then
			kick[user.sName] = kick[user.sName] + 1
			user:SendData(Bot, kick[user.sName])
			Reason = FindWhat(data) 
			SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..kick[user.sName].." kicks. Reason: "..Reason.." FILE: "..path) 
			user:SendPM(BotName,"You have been kicked "..kick[user.sName].." time(s) at 3 you will be ban. "..Reason.." FILE: "..path)
			appendto(kicklog) 
			write("\r\n"..user.sName.."|"..Reason.."|"..path.."|"..kick[user.sName].."|"..GetTime()) 
			writeto()
			if (main == "Active" ) then
				SendToAll(BotName, "The user "..user.sName.." is been kicked for "..Reason)
			end
			if (main == "Deactive") then
				return 1
			end
			user:TempBan() 
		end
	end
end 
end
end 

function FindWhat(data) 
for i,v in Files do 
if( strfind(strlower(data), i) ) then 
return v 
end 
end 
return "Other files" 
end  

function GetTime()
	s = date("%S")
	h = date("%H")
	m = date("%M")
	d = date("%d")
	mm = date("%m")
	y = date("%y")
	Date = "Day: "..d.."/"..mm.."/20"..y.." Hour: "..h..":"..m..":"..s
	return Date

end

I have tryied every conditions and had no sytanx errors.
Sometimes coulde be users which get connect a disconnect at same time and the bot can?t get their information.

Best regards, nErBoS
--## nErBoS Spot ##--

*??G??*

thnx.....will give this one a try

+--**T?T?? X???m?**--+   @    titanxtreme.kicks-ass.net

MetalPriest

Hello..

Here is the script...but error is there anyway

Syntax Error: attempt to perform arithmetic on a nil value...So help needed experts..

MetalPriest

----------------------------------------------------------------------

------ Code -----

BotName = "-=BadFilesBot=-"

function Main()
frmHub:RegBot(BotName)
frmHub:EnableSearchData(1)
end

Files = {
[".dll"]="NO dll files in here!",
[".toast"]="NO toast files inhere!",
["tmp"]="NO sharing of incomplete downloads",
[".vob"]="NO sharing of DVD files,who want's them ??",
[".ifo"]="NO sharing of DVD files,who want's them ??",
["_INCOMPLETE_"]="NO sharing of incomplete downloads",
["download123456789.dat"]="NO sharing of incomplete downloads",
["part.met"]="NO sharing of incomplete downloads",
[".getright"]="NO sharing of incomplete downloads",
["uniwise.exe"]="NO installed programs allowed"

}

warn = {}
kick = {}
usersimune = {""} -- Usres you want to not be checked

kicklog = "kicks.txt" -- In script folder
main = "Active" --- write Deactive and will not send the kicks and bans to the main


function NewUserConnected(user)
if (warn[user.sName] == nill or warn[user.sName] == 4) then
warn[user.sName] = 0
end
if (kick[user.sName] == nill or kick[user.sName] == 4) then
kick[user.sName] = 0
end

for i,v in Files do
user:SendData("$Search Hub:"..BotName.." F?F?0?1?"..i)
end
end

function DataArrival(user, data)
 
if( strsub(data, 1, 3) == "$SR" ) then
_,_,nick = strfind( data, "\05(%S*)|$" )
local s = 5 + strlen(user.sName)
local e = strfind(data, "%d+%s%d+/%d+") - 2
local path = strsub(data, s, e)
if( nick == BotName) then
   for i=1,getn(usersimune) do
   if (user.bOperator or user.sName == usersimune) then
   return 1
   end
   end
   if (GetProfileName(user.iProfile) == "VIP") then
      if (kick[user.sName] == 3) then
         kick[user.sName] = kick[user.sName] + 1
         Reason = FindWhat(data)
         SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got ban. Reason: "..Reason.." FILE: "..path)
         user:SendPM(BotName,"You have been banned. "..Reason)
         if (main == "Active" ) then
            SendToAll(BotName, "The user "..user.sName.." is been banned for "..Reason)
         end
         if (main == "Deactive") then
            return 1
         end
         user:Ban()
      elseif (warn[user.sName] == 3 or kick[user.sName] == 1 or kick[user.sName] == 2) then
         warn[user.sName] = warn[user.sName] + 1
         kick[user.sName] = kick[user.sName] + 1
         Reason = FindWhat(data)
         SendPmToOps(BotName, "*** User "..user.sName.." got "..kick[user.sName].." kicks. Reason: "..Reason.." FILE: "..path)
         user:SendPM(BotName,"You have been kicked "..kick[user.sName].." time(s) at 3 you will be ban. "..Reason.." FILE: "..path)
         appendto(kicklog)
         write("\r\n"..user.sName.."|"..Reason.."|"..path.."|"..kick[user.sName].."|"..GetTime())
         writeto()
         if (main == "Active" ) then
            SendToAll(BotName, "The user "..user.sName.." is been kicked for "..Reason)
         end
         if (main == "Deactive") then
            return 1
         end
         user:TempBan()
      elseif (warn[user.sName] == 0 or warn[user.sName] == 1 or warn[user.sName] == 2) then
         warn[user.sName] = warn[user.sName] + 1
         Reason = FindWhat(data)
         SendPmToOps(BotName, "*** User "..user.sName.." got "..warn[user.sName].." warns. Reason: "..Reason.." FILE: "..path)
         user:SendPM(BotName, "You have been warned "..warn[user.sName].." time(s) at 3 you will be kicked. "..Reason.." FILE: "..path)
         user:SendPM(BotName, "You can come back when you have corrected the problem")
         user:SendPM(BotName, "Disconnected...")
         user:Disconnect()
      end
   elseif not(user.bOperator and GetProfileName(user.iProfile) == "VIP" and user.sName == usersimune) then --this will solve the double log i think
      if (kick[user.sName] == 3) then
         kick[user.sName] = kick[user.sName] + 1
         Reason = FindWhat(data)
         SendPmToOps(BotName, "*** User "..user.sName.." got ban. Reason: "..Reason.." FILE: "..path)
         user:SendPM(BotName,"You have been banned. "..Reason)
         if (main == "Active" ) then
            SendToAll(BotName, "The user "..user.sName.." is been banned for "..Reason)
         end
         if (main == "Deactive") then
            return 1
         end
         user:Ban()
      elseif (kick[user.sName] == 0 or kick[user.sName] == 1 or kick[user.sName] == 2) then
         kick[user.sName] = kick[user.sName] + 1
         user:SendData(Bot, kick[user.sName])
         Reason = FindWhat(data)
         SendPmToOps(BotName, "*** User "..user.sName.." got "..kick[user.sName].." kicks. Reason: "..Reason.." FILE: "..path)
         user:SendPM(BotName,"You have been kicked "..kick[user.sName].." time(s) at 3 you will be ban. "..Reason.." FILE: "..path)
         appendto(kicklog)
         write("\r\n"..user.sName.."|"..Reason.."|"..path.."|"..kick[user.sName].."|"..GetTime())
         writeto()
         if (main == "Active" ) then
            SendToAll(BotName, "The user "..user.sName.." is been kicked for "..Reason)
         end
         if (main == "Deactive") then
            return 1
         end
         user:TempBan()
      end
   end
end
end
end

function FindWhat(data)
for i,v in Files do
if( strfind(strlower(data), i) ) then
return v
end
end
return "Other files"
end  

function GetTime()
   s = date("%S")
   h = date("%H")
   m = date("%M")
   d = date("%d")
   mm = date("%m")
   y = date("%y")
   Date = "Day: "..d.."/"..mm.."/20"..y.." Hour: "..h..":"..m..":"..s
   return Date

end

---------------------the end-----------------------------------------
   ?? ?.(*?.?( ?.??.??)?.?*).?? ?
    ???*?.?*???RoboCop???*.??.?*? ?
      ???*?.?Checks you here !!!.??.?*? ?
          (?.?* MetalSweden *?.?) ?.?)
 (?.?* metalsweden.servemp3.com *?.?)
             \'?.(*?.?( ?.? ?.??)?.?*).??

nErBoS

Hi,

Try this one...

-- Simple Illegalist v0.1 
-- Created by Ptaczek, Jan-3, 2003 
-- Searches for specified patterns. Useful for illegal share checking 
-- some changes by Skippy and RabidWombat and OpiumVolage and trucker 
-- add tables warn and kick by nErBoS

BotName = "Illegalist" 

function Main()
frmHub:RegBot(BotName) 
frmHub:EnableSearchData(1) 
end 

Files = { 
["childsex"]="NO sick Porn inhere!", 
["childporn"]="NO sick kid Porn inhere!", 
["underage"]="NO sick kid Porn inhere!", 
["animalsex"]="NO Animalsex files here!", 
["svastika"]="NO Nazi/white power music HERE!!!", 
[".temp.mp3"]="NO sharing of incomplete downloads", 
["_INCOMPLETE_"]="NO sharing of incomplete downloads", 
["download123456789.dat"]="NO sharing of incomplete downloads", 
["part.met"]="NO sharing of incomplete downloads", 
[".getright"]="NO sharing of incomplete downloads", 
[".vob"]="NO sharing of incomplete downloads", 
["share faker"]="NO tools for fake sharing allowed", 
["share hacker"]="No tools for fake sharing allowed"} 

warn = {}
kick = {}
usersimune = {"nErBoS", "[NL]trucker","(uk-kingdom)John","(UKD)John","[NL]{VIP}Geroni", 
"[NL]Coco","[NL]Dark_bad_girl","[NL]DiGARiX","[NL]GePe","[NL]M@non","[NL]movieman","[NL]SuusTweety", 
"[NL]voodoo","[NL]ZeroX","Chupi?","DoJiN","hhps","[UKD]jiorgee","Quaraf","Sweet_Bitch", 
"TheWickedRabbit","Serima","[NL]partyfever","[NL]AiR"} -- Usres you want to not be checked 

kicklog = "kicks.txt" -- In script folder
main = "Active" --- write Deactive and will not send the kicks and bans to the main


function NewUserConnected(user)
if (warn[user.sName] == nill or warn[user.sName] == 4) then 
warn[user.sName] = 0
end
if (kick[user.sName] == nill or kick[user.sName] == 4) then
kick[user.sName] = 0
end

for i,v in Files do 
user:SendData("$Search Hub:"..BotName.." F?F?0?1?"..i) 
end 
end 

function DataArrival(user, data)
 
if( strsub(data, 1, 3) == "$SR" ) then 
_,_,nick = strfind( data, "\05(%S*)|$" ) 
local s = 5 + strlen(user.sName)
local e = strfind(data, "%d+%s%d+/%d+") - 2
local path = strsub(data, s, e)
if( nick == BotName) then
	for i=1,getn(usersimune) do 
	if (user.bOperator or user.sName == usersimune[i]) then
	return 1
	end
	end
	if (GetProfileName(user.iProfile) == "VIP") then
		if (kick[user.sName] == 3) then
			ClearNill(user)
			kick[user.sName] = kick[user.sName] + 1
			Reason = FindWhat(data) 
			SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got ban. Reason: "..Reason.." FILE: "..path) 
			user:SendPM(BotName,"You have been banned. "..Reason)
			if (main == "Active" ) then
				SendToAll(BotName, "The user "..user.sName.." is been banned for "..Reason)
			end
			if (main == "Deactive") then
				return 1
			end
			user:Ban() 
		elseif (warn[user.sName] == 3 or kick[user.sName] == 1 or kick[user.sName] == 2) then
			ClearNill(user)
			warn[user.sName] = warn[user.sName] + 1
			kick[user.sName] = kick[user.sName] + 1
			Reason = FindWhat(data) 
			SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..kick[user.sName].." kicks. Reason: "..Reason.." FILE: "..path) 
			user:SendPM(BotName,"You have been kicked "..kick[user.sName].." time(s) at 3 you will be ban. "..Reason.." FILE: "..path)
			appendto(kicklog) 
			write("\r\n"..user.sName.."|"..Reason.."|"..path.."|"..kick[user.sName].."|"..GetTime()) 
			writeto()
			if (main == "Active" ) then
				SendToAll(BotName, "The user "..user.sName.." is been kicked for "..Reason)
			end
			if (main == "Deactive") then
				return 1
			end
			user:TempBan() 
		elseif (warn[user.sName] == 0 or warn[user.sName] == 1 or warn[user.sName] == 2) then
			ClearNill(user)
			warn[user.sName] = warn[user.sName] + 1
			Reason = FindWhat(data) 
			SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..warn[user.sName].." warns. Reason: "..Reason.." FILE: "..path) 
			user:SendPM(BotName, "You have been warned "..warn[user.sName].." time(s) at 3 you will be kicked. "..Reason.." FILE: "..path)
			user:SendPM(BotName, "You can come back when you have corrected the problem")
			user:SendPM(BotName, "Disconnected...") 
			user:Disconnect() 
		end
	elseif not(user.bOperator and GetProfileName(user.iProfile) == "VIP" and user.sName == usersimune[i]) then --this will solve the double log i think
		if (kick[user.sName] == 3) then
			ClearNill(user)
			kick[user.sName] = kick[user.sName] + 1
			Reason = FindWhat(data) 
			SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got ban. Reason: "..Reason.." FILE: "..path) 
			user:SendPM(BotName,"You have been banned. "..Reason)
			if (main == "Active" ) then
				SendToAll(BotName, "The user "..user.sName.." is been banned for "..Reason)
			end
			if (main == "Deactive") then
				return 1
			end
			user:Ban() 
		elseif (kick[user.sName] == 0 or kick[user.sName] == 1 or kick[user.sName] == 2) then
			ClearNill(user)
			kick[user.sName] = kick[user.sName] + 1
			user:SendData(Bot, kick[user.sName])
			Reason = FindWhat(data) 
			SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..kick[user.sName].." kicks. Reason: "..Reason.." FILE: "..path) 
			user:SendPM(BotName,"You have been kicked "..kick[user.sName].." time(s) at 3 you will be ban. "..Reason.." FILE: "..path)
			appendto(kicklog) 
			write("\r\n"..user.sName.."|"..Reason.."|"..path.."|"..kick[user.sName].."|"..GetTime()) 
			writeto()
			if (main == "Active" ) then
				SendToAll(BotName, "The user "..user.sName.." is been kicked for "..Reason)
			end
			if (main == "Deactive") then
				return 1
			end
			user:TempBan() 
		end
	end
end 
end
end 

function FindWhat(data) 
for i,v in Files do 
if( strfind(strlower(data), i) ) then 
return v 
end 
end 
return "Other files" 
end  

function GetTime()
	s = date("%S")
	h = date("%H")
	m = date("%M")
	d = date("%d")
	mm = date("%m")
	y = date("%y")
	Date = "Day: "..d.."/"..mm.."/20"..y.." Hour: "..h..":"..m..":"..s
	return Date

end

function ClearNill(user)
	if (warn[user.sName] == nill) then 
		warn[user.sName] = 0
	end
	if (kick[user.sName] == nill) then
		kick[user.sName] = 0
	end
end

Best regards, nErBoS
--## nErBoS Spot ##--

MetalPriest

Yeaaaa THanks

No error so far... And this is 10 minutes...


You are good nErBoS

Meny thanks

MetalPriest
?Sweden
dchub://metalsweden.servemp3.com
   ?? ?.(*?.?( ?.??.??)?.?*).?? ?
    ???*?.?*???RoboCop???*.??.?*? ?
      ???*?.?Checks you here !!!.??.?*? ?
          (?.?* MetalSweden *?.?) ?.?)
 (?.?* metalsweden.servemp3.com *?.?)
             \'?.(*?.?( ?.? ?.??)?.?*).??

jsjen

Search spam detected from Illegalist

what does this mean? everone gets it on eentry

I feel a bit stupid

[NL]trucker

jsjen

as illegalist is a search script it connects to evryone who is coming into hub ;and searches through their filelist and as a result of that you get that message so nothing to worry about.
Owner of FunnyHub
 
Funyhub.no-ip.info
       Forum Master of


MetalPriest

Same error come up

Syntax Error: attempt to perform arithmetic on a nil value

Wonder why and where.....


 
MetalPriest
   ?? ?.(*?.?( ?.??.??)?.?*).?? ?
    ???*?.?*???RoboCop???*.??.?*? ?
      ???*?.?Checks you here !!!.??.?*? ?
          (?.?* MetalSweden *?.?) ?.?)
 (?.?* metalsweden.servemp3.com *?.?)
             \'?.(*?.?( ?.? ?.??)?.?*).??

nErBoS

#42
Hi,

There was a bug in the last script instead of nil i have put nill i used to use null :P

Corrected...

-- Simple Illegalist v0.1 
-- Created by Ptaczek, Jan-3, 2003 
-- Searches for specified patterns. Useful for illegal share checking 
-- some changes by Skippy and RabidWombat and OpiumVolage and trucker 
-- add tables warn and kick by nErBoS

BotName = "Illegalist" 

function Main()
frmHub:RegBot(BotName) 
frmHub:EnableSearchData(1) 
end 

Files = { 
["childsex"]="NO sick Porn inhere!", 
["childporn"]="NO sick kid Porn inhere!", 
["underage"]="NO sick kid Porn inhere!", 
["animalsex"]="NO Animalsex files here!", 
["svastika"]="NO Nazi/white power music HERE!!!", 
[".temp.mp3"]="NO sharing of incomplete downloads", 
["_INCOMPLETE_"]="NO sharing of incomplete downloads", 
["download123456789.dat"]="NO sharing of incomplete downloads", 
["part.met"]="NO sharing of incomplete downloads", 
[".getright"]="NO sharing of incomplete downloads", 
[".vob"]="NO sharing of incomplete downloads", 
["share faker"]="NO tools for fake sharing allowed", 
["share hacker"]="No tools for fake sharing allowed"} 

warn = {}
kick = {}
usersimune = {"nErBoS", "[NL]trucker","(uk-kingdom)John","(UKD)John","[NL]{VIP}Geroni", 
"[NL]Coco","[NL]Dark_bad_girl","[NL]DiGARiX","[NL]GePe","[NL]M@non","[NL]movieman","[NL]SuusTweety", 
"[NL]voodoo","[NL]ZeroX","Chupi?","DoJiN","hhps","[UKD]jiorgee","Quaraf","Sweet_Bitch", 
"TheWickedRabbit","Serima","[NL]partyfever","[NL]AiR"} -- Usres you want to not be checked 

kicklog = "kicks.txt" -- In script folder
main = "Active" --- write Deactive and will not send the kicks and bans to the main


function NewUserConnected(user)
if (warn[user.sName] == nill or warn[user.sName] == 4) then 
warn[user.sName] = 0
end
if (kick[user.sName] == nill or kick[user.sName] == 4) then
kick[user.sName] = 0
end

for i,v in Files do 
user:SendData("$Search Hub:"..BotName.." F?F?0?1?"..i) 
end 
end 

function DataArrival(user, data)
 
if( strsub(data, 1, 3) == "$SR" ) then 
_,_,nick = strfind( data, "\05(%S*)|$" ) 
local s = 5 + strlen(user.sName)
local e = strfind(data, "%d+%s%d+/%d+") - 2
local path = strsub(data, s, e)
if( nick == BotName) then
	for i=1,getn(usersimune) do 
	if (user.bOperator or user.sName == usersimune[i]) then
	return 1
	end
	end
	if (GetProfileName(user.iProfile) == "VIP") then
		if (kick[user.sName] == 3) then
			ClearNill(user)
			kick[user.sName] = kick[user.sName] + 1
			Reason = FindWhat(data) 
			SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got ban. Reason: "..Reason.." FILE: "..path) 
			user:SendPM(BotName,"You have been banned. "..Reason)
			if (main == "Active" ) then
				SendToAll(BotName, "The user "..user.sName.." is been banned for "..Reason)
			end
			if (main == "Deactive") then
				return 1
			end
			user:Ban() 
		elseif (warn[user.sName] == 3 or kick[user.sName] == 1 or kick[user.sName] == 2) then
			ClearNill(user)
			warn[user.sName] = warn[user.sName] + 1
			kick[user.sName] = kick[user.sName] + 1
			Reason = FindWhat(data) 
			SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..kick[user.sName].." kicks. Reason: "..Reason.." FILE: "..path) 
			user:SendPM(BotName,"You have been kicked "..kick[user.sName].." time(s) at 3 you will be ban. "..Reason.." FILE: "..path)
			appendto(kicklog) 
			write("\r\n"..user.sName.."|"..Reason.."|"..path.."|"..kick[user.sName].."|"..GetTime()) 
			writeto()
			if (main == "Active" ) then
				SendToAll(BotName, "The user "..user.sName.." is been kicked for "..Reason)
			end
			if (main == "Deactive") then
				return 1
			end
			user:TempBan() 
		elseif (warn[user.sName] == 0 or warn[user.sName] == 1 or warn[user.sName] == 2) then
			ClearNill(user)
			warn[user.sName] = warn[user.sName] + 1
			Reason = FindWhat(data) 
			SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..warn[user.sName].." warns. Reason: "..Reason.." FILE: "..path) 
			user:SendPM(BotName, "You have been warned "..warn[user.sName].." time(s) at 3 you will be kicked. "..Reason.." FILE: "..path)
			user:SendPM(BotName, "You can come back when you have corrected the problem")
			user:SendPM(BotName, "Disconnected...") 
			user:Disconnect() 
		end
	elseif not(user.bOperator and GetProfileName(user.iProfile) == "VIP" and user.sName == usersimune[i]) then --this will solve the double log i think
		if (kick[user.sName] == 3) then
			ClearNill(user)
			kick[user.sName] = kick[user.sName] + 1
			Reason = FindWhat(data) 
			SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got ban. Reason: "..Reason.." FILE: "..path) 
			user:SendPM(BotName,"You have been banned. "..Reason)
			if (main == "Active" ) then
				SendToAll(BotName, "The user "..user.sName.." is been banned for "..Reason)
			end
			if (main == "Deactive") then
				return 1
			end
			user:Ban() 
		elseif (kick[user.sName] == 0 or kick[user.sName] == 1 or kick[user.sName] == 2) then
			ClearNill(user)
			kick[user.sName] = kick[user.sName] + 1
			user:SendData(Bot, kick[user.sName])
			Reason = FindWhat(data) 
			SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..kick[user.sName].." kicks. Reason: "..Reason.." FILE: "..path) 
			user:SendPM(BotName,"You have been kicked "..kick[user.sName].." time(s) at 3 you will be ban. "..Reason.." FILE: "..path)
			appendto(kicklog) 
			write("\r\n"..user.sName.."|"..Reason.."|"..path.."|"..kick[user.sName].."|"..GetTime()) 
			writeto()
			if (main == "Active" ) then
				SendToAll(BotName, "The user "..user.sName.." is been kicked for "..Reason)
			end
			if (main == "Deactive") then
				return 1
			end
			user:TempBan() 
		end
	end
end 
end
end 

function FindWhat(data) 
for i,v in Files do 
if( strfind(strlower(data), i) ) then 
return v 
end 
end 
return "Other files" 
end  

function GetTime()
	s = date("%S")
	h = date("%H")
	m = date("%M")
	d = date("%d")
	mm = date("%m")
	y = date("%y")
	Date = "Day: "..d.."/"..mm.."/20"..y.." Hour: "..h..":"..m..":"..s
	return Date

end

function ClearNill(user)
	if (warn[user.sName] == nil) then 
		warn[user.sName] = 0
	end
	if (kick[user.sName] == nil) then
		kick[user.sName] = 0
	end
end

Best regards, nErBoS
--## nErBoS Spot ##--

MetalPriest

Thanks nErBoS

I need this script..so here we go again..

MetalPriest
   ?? ?.(*?.?( ?.??.??)?.?*).?? ?
    ???*?.?*???RoboCop???*.??.?*? ?
      ???*?.?Checks you here !!!.??.?*? ?
          (?.?* MetalSweden *?.?) ?.?)
 (?.?* metalsweden.servemp3.com *?.?)
             \'?.(*?.?( ?.? ?.??)?.?*).??

MetalPriest

Sorry but this error come up again...

MetalPriest
   ?? ?.(*?.?( ?.??.??)?.?*).?? ?
    ???*?.?*???RoboCop???*.??.?*? ?
      ???*?.?Checks you here !!!.??.?*? ?
          (?.?* MetalSweden *?.?) ?.?)
 (?.?* metalsweden.servemp3.com *?.?)
             \'?.(*?.?( ?.? ?.??)?.?*).??

[NL]trucker

yep

MetalPriest is right the same eror is coming up again (:-
Owner of FunnyHub
 
Funyhub.no-ip.info
       Forum Master of


nErBoS

Hi,

Are any of you is using ptokax 0.3.3.0. If yes show me the syntax error, probably has the line would be easier to me to find the error.

Best regards, nErBoS
--## nErBoS Spot ##--

[NL]trucker

#47
Nerbos

i,m using 15,25 and if i,m right this is the error

Syntax Error: attempt to perform arithmetic on a nil value

i had the full line but it was gone after a restart (:-

when it comes back i,ll show it.


oke here it is :
--------------------------------
Syntax error: attempt to perform arithmetic on a nil value
stack traceback:
   1:  function `DataArrival' at line 59 [file `...OTAX==\trucker\scripts\illegalist_by_nerbos.lua']
Owner of FunnyHub
 
Funyhub.no-ip.info
       Forum Master of


nErBoS

#48
Hi,

[NL]trucker can you send me in PM the script as exactly as you are using in your Hub or post here if you don't mind.

Best regards, nErBoS
--## nErBoS Spot ##--

[NL]trucker

#49
Nerbos;

oke here we go


with the error:

Syntax error: attempt to perform arithmetic on a nil value
stack traceback:
   1:  function `DataArrival' at line 59 [file `...OTAX==\trucker\scripts\illegalist_by_nerbos.lua']
+++++++++++++++++++++++++++++++++++++

-- Simple Illegalist v0.1
-- Created by Ptaczek, Jan-3, 2003
-- Searches for specified patterns. Useful for illegal share checking
-- some changes by Skippy and RabidWombat and OpiumVolage and trucker
-- add tables warn and kick by nErBoS

BotName = "Illegalist"

function Main()
--frmHub:RegBot(BotName)
frmHub:EnableSearchData(1)
end

Files = {
["childsex"]="NO sick Porn inhere!",
["childporn"]="NO sick kid Porn inhere!",
["underage"]="NO sick kid Porn inhere!",
["animalsex"]="NO Animalsex files here!",
["svastika"]="NO Nazi/white power music HERE!!!",
[".temp.mp3"]="NO sharing of incomplete downloads",
["_INCOMPLETE_"]="NO sharing of incomplete downloads",
["download123456789.dat"]="NO sharing of incomplete downloads",
["part.met"]="NO sharing of incomplete downloads",
[".getright"]="NO sharing of incomplete downloads",
[".vob"]="NO sharing of incomplete downloads",
["share faker"]="NO tools for fake sharing allowed",
["share hacker"]="No tools for fake sharing allowed"}

warn = {}
kick = {}
usersimune = {"nErBoS", "[NL]trucker","(uk-kingdom)John","(UKD)John","[NL]{VIP}Geroni",
"[NL]Coco","[NL]Dark_bad_girl","[NL]DiGARiX","[NL]GePe","[NL]M@non","[NL]movieman","[NL]SuusTweety",
"[NL]voodoo","[NL]ZeroX","Chupi?","DoJiN","hhps","[UKD]jiorgee","Quaraf","Sweet_Bitch",
"TheWickedRabbit","Serima","[NL]partyfever","[NL]AiR","TiMeTrAVelleR","[TGA]plop","[NL]ZeroX",
"[NL]WizzCat","[NL]SuusTweety","[NL]king","[NL]HsH","[NL]Hasjmann","[NL]GePe"} -- Usres you want to not be checked

kicklog = "kicks.txt" -- In script folder
main = "Active" --- write Deactive and will not send the kicks and bans to the main


function NewUserConnected(user)
if (warn[user.sName] == nill or warn[user.sName] == 4) then
warn[user.sName] = 0
end
if (kick[user.sName] == nill or kick[user.sName] == 4) then
kick[user.sName] = 0
end

for i,v in Files do
user:SendData("$Search Hub:"..BotName.." F?F?0?1?"..i)
end
end

function DataArrival(user, data)
 
if( strsub(data, 1, 3) == "$SR" ) then
_,_,nick = strfind( data, "\05(%S*)|$" )
local s = 5 + strlen(user.sName)
local e = strfind(data,"%d+%s%d+/%d+") - 2
local path = strsub(data, s, e)
if( nick == BotName) then
   for i=1,getn(usersimune) do
   if (user.bOperator or user.sName == usersimune) then
   return 1
   end
   end
   if (GetProfileName(user.iProfile) == "VIP") then
      if (kick[user.sName] == 3) then
         ClearNill(user)
         kick[user.sName] = kick[user.sName] + 1
         Reason = FindWhat(data)
         SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got ban. Reason: "..Reason.." FILE: "..path)
         user:SendPM(BotName,"You have been banned. "..Reason)
         if (main == "Active" ) then
            SendToAll(BotName, "The user "..user.sName.." is been banned for "..Reason)
         end
         if (main == "Deactive") then
            return 1
         end
         user:Ban()
      elseif (warn[user.sName] == 3 or kick[user.sName] == 1 or kick[user.sName] == 2) then
         ClearNill(user)
         warn[user.sName] = warn[user.sName] + 1
         kick[user.sName] = kick[user.sName] + 1
         Reason = FindWhat(data)
         SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..kick[user.sName].." kicks. Reason: "..Reason.." FILE: "..path)
         user:SendPM(BotName,"You have been kicked "..kick[user.sName].." time(s) at 3 you will be ban. "..Reason.." FILE: "..path)
         appendto(kicklog)
         write("\r\n"..user.sName.."|"..Reason.."|"..path.."|"..kick[user.sName].."|"..GetTime())
         writeto()
         if (main == "Active" ) then
            SendToAll(BotName, "The user "..user.sName.." is been kicked for "..Reason)
         end
         if (main == "Deactive") then
            return 1
         end
         user:TempBan()
      elseif (warn[user.sName] == 0 or warn[user.sName] == 1 or warn[user.sName] == 2) then
         ClearNill(user)
         warn[user.sName] = warn[user.sName] + 1
         Reason = FindWhat(data)
         SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..warn[user.sName].." warns. Reason: "..Reason.." FILE: "..path)
         user:SendPM(BotName, "You have been warned "..warn[user.sName].." time(s) at 3 you will be kicked. "..Reason.." FILE: "..path)
         user:SendPM(BotName, "You can come back when you have corrected the problem")
         user:SendPM(BotName, "Disconnected...")
         user:Disconnect()
      end
   elseif not(user.bOperator and GetProfileName(user.iProfile) == "VIP" and user.sName == usersimune) then --this will solve the double log i think
      if (kick[user.sName] == 3) then
         ClearNill(user)
         kick[user.sName] = kick[user.sName] + 1
         Reason = FindWhat(data)
         SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got ban. Reason: "..Reason.." FILE: "..path)
         user:SendPM(BotName,"You have been banned. "..Reason)
         if (main == "Active" ) then
            SendToAll(BotName, "The user "..user.sName.." is been banned for "..Reason)
         end
         if (main == "Deactive") then
            return 1
         end
         user:Ban()
      elseif (kick[user.sName] == 0 or kick[user.sName] == 1 or kick[user.sName] == 2) then
         ClearNill(user)
         kick[user.sName] = kick[user.sName] + 1
         user:SendData(Bot, kick[user.sName])
         Reason = FindWhat(data)
         SendPmToNick("[NL]trucker", BotName, "*** User "..user.sName.." got "..kick[user.sName].." kicks. Reason: "..Reason.." FILE: "..path)
         user:SendPM(BotName,"You have been kicked "..kick[user.sName].." time(s) at 3 you will be ban. "..Reason.." FILE: "..path)
         appendto(kicklog)
         write("\r\n"..user.sName.."|"..Reason.."|"..path.."|"..kick[user.sName].."|"..GetTime())
         writeto()
         if (main == "Active" ) then
            SendToAll(BotName, "The user "..user.sName.." is been kicked for "..Reason)
         end
         if (main == "Deactive") then
            return 1
         end
         user:TempBan()
      end
   end
end
end
end

function FindWhat(data)
for i,v in Files do
if( strfind(strlower(data), i) ) then
return v
end
end
return "Other files"
end  

function GetTime()
   s = date("%S")
   h = date("%H")
   m = date("%M")
   d = date("%d")
   mm = date("%m")
   y = date("%y")
   Date = "Day: "..d.."/"..mm.."/20"..y.." Hour: "..h..":"..m..":"..s
   return Date

end

function ClearNill(user)
   if (warn[user.sName] == nil) then
      warn[user.sName] = 0
   end
   if (kick[user.sName] == nil) then
      kick[user.sName] = 0
   end
end

++++++++++++++++++++++++++++++++++++++++
Owner of FunnyHub
 
Funyhub.no-ip.info
       Forum Master of


SMF spam blocked by CleanTalk