i found this lua for fake share but it doesn't work on dcdm
anyone help me?
--Requested by blackwings
--Removed from Brain-Master
sBot = "Fake Share"
badShare = { "10000000000","5368709120","10737418240","13630010000","16106127360",
"21474836480","26843545600","27000000000","32212254720","7970010000",
"37580963840","37970010000","6599201000000","65992010000000","36772010000000",
"3677201000000","42949672960","48318382080","214266156265","53687091200",
"59055800320","1747201000000","16772010000000","147720100000000","10240000000000",
"64424509440","65719010000","69793218560","75161927680","80530636800","85899345920",
"91268055040","96636764160","102005473280","102400000000","107374182400","118648471552",
"128849018880","140301549174","161061273600","174720100000","183287729356","214748364800",
"268435456000","322122547200","375809638400","107524506255.36","429496729600","536870912000",
"657190100000","1024000000000","183287729357","102392020337","13625783747","174719269601",
"87671019929.6","88884348190.72","90001039687.68","92449171046.4","95627446845.44","91053306675.2",
"96926674452.48","96851512524.8","97817880166.4","98784247808","99997576069.12","105226698752",
"110004849868.8","119367878574.08","120001386250.24","111110803947.52","123319248486.4","103841571799.04",
"124231929036.8","125455994716.16","97817880166.4","125831804354.56","199715979264","199995152138.24",
"181236882472.96","99943888977.92","221652524728.32","276263033896.96","112989852139.52","158537980313.6",
"65712999629","26993869455","140295106724" }
function Main()
frmHub:RegBot(sBot)
end
function NewUserConnected(user)
if (user.sMyInfoString ~= nil and checkFake(user)) then
user:SendPM(sBot, "You are using Fake Share.")
SendToAll(sBot, "The user "..user.sName.." has been banned for Fake Share.")
user:Ban()
end
end
function checkFake(user)
local s,e,shared = strfind(user.sMyInfoString, "$MyINFO $ALL %S+ .-$ $.+.$.-$(%d+)")
if (shared ~= nil) then
return foreachi(badShare, function(id, value) if value == %shared then return id end end)
end
end
thx anyway
sorry neither to Ptokax works (0.3.3.0 built17.09)
i have this error from both \scripts\FakeShare.lua:38: unexpected symbol near `%'
this script youve posted is in lua 4 so needs converting to lua 5 try this not sure if it works
sBot = "Fake Share"
badShare = { "10000000000","5368709120","10737418240","13630010000","16106127360",
"21474836480","26843545600","27000000000","32212254720","7970010000",
"37580963840","37970010000","6599201000000","65992010000000","36772010000000",
"3677201000000","42949672960","48318382080","214266156265","53687091200",
"59055800320","1747201000000","16772010000000","147720100000000","10240000000000",
"64424509440","65719010000","69793218560","75161927680","80530636800","85899345920",
"91268055040","96636764160","102005473280","102400000000","107374182400","118648471552",
"128849018880","140301549174","161061273600","174720100000","183287729356","214748364800",
"268435456000","322122547200","375809638400","107524506255.36","429496729600","536870912000",
"657190100000","1024000000000","183287729357","102392020337","13625783747","174719269601",
"87671019929.6","88884348190.72","90001039687.68","92449171046.4","95627446845.44","91053306675.2",
"96926674452.48","96851512524.8","97817880166.4","98784247808","99997576069.12","105226698752",
"110004849868.8","119367878574.08","120001386250.24","111110803947.52","123319248486.4","103841571799.04",
"124231929036.8","125455994716.16","97817880166.4","125831804354.56","199715979264","199995152138.24",
"181236882472.96","99943888977.92","221652524728.32","276263033896.96","112989852139.52","158537980313.6",
"65712999629","26993869455","140295106724" }
function Main()
frmHub:RegBot(sBot)
end
function NewUserConnected(user)
if (user.sMyInfoString ~= nil and checkFake(user)) then
user:SendPM(sBot, "You are using Fake Share.")
SendToAll(sBot, "The user "..user.sName.." has been banned for Fake Share.")
user:Ban()
end
end
function checkFake(user)
local s,e,shared = string.find(user.sMyInfoString, "$MyINFO $ALL (%S+)%s+(.*)<([^$]+)$ $([^$]*)$([^$]*)$([^$]+)")
if (shared ~= nil) then
return foreachi(badShare, function(id, value) if value == shared then return id end end)
end
end
Couple of minor things....
Missed a table. (in bold)
Unless im wrong, doesn't using string.find to find the share size give the same value as user.iShareSize?
so the function cud end up:
function checkFake(user)
if (user.iShareSize ~= nil) then
return table.foreachi (badShare, function(id, value) if value == user.iShareSize then return id end end)
end
end
*edit*
Just noticed wrong section, for script help really needs to be in the lua5 scripts section, not links :oP
thx both! it's really working! no error
and i hope this share are really fake :)
your wellcome
we are here to learn of one and other and help others out