Something added to the script from Dessamator
--By Dessamator
--Top Leecher
-- Added by Mozzilla™ - 16 November 2006
-- Choice as to which profile gets checked
min = 30 -- time to wait b4 reporting top leecher
bot = "TopLeecher" -- bots name
-- Set check on or off for a given profile [0 = don't check 1 = check]
cChecks = {
[-1] = 1, --Unregistered User
[0] = 0, --Master
[1] = 0, --Operator
[2] = 1, --VIP
[3] = 1, --Registered User
[4] = 0, --Moderator
[5] = 0, --NetFounder
[6] = 0, --Owner
}
function Main()
SetTimer(60*1000*min)
StartTimer()
end
function OnTimer()
local hubs = 0
for pos, user in pairs(frmHub:GetOnlineUsers()) do
if cChecks[user.iProfile] == 1 then
local prof = GetProfileName(user.iProfile) or "Unregistered User"
if user.iHubs > hubs then
temp="\r\n\r\nCongratulations "..prof.." "..user.sName..", you are the top leecher in "..frmHub:GetHubName()..".\r\n\tAt this very moment you are in "..user.iHubs.." hubs with "..user.iSlots.." slots open!"
hubs = user.iHubs
end
end
end
SendToAll(bot,temp)
temp, hubs= nil, nil
end
Interesting, I forgot i had even done that, but anyways you can also remove this :
temp, hubs= nil, nil
and change this : local hubs=0
to this: local hubs,temp=0
Thanks Dessamator