-- Dit script is Gerepareed door AmsterdamBulldogs
-- Tijdban optie toegevoegd door AmsterdamBulldogs
-- Vertaald door Rebel
-- Veranderd door BugsBunny
rusian = {
["sBotName"] ="",
["prefix"] = "!",
["cmd"] = "fire",
["maxmessages"] = 8,
["discortimeban"] = "2", -- zet 1 voor disconect en zet op 2 voor tijdban
["timebantime"] = "5", -- Tijd ban tijd staat in minuten
["permissions"] = {[-1] = 1, [0] = 1, [1] = 1, [2] = 1, [3] = 1, [4] = 1, [5] = 1, }, -- 1 = allowed and 0 = not allowed
}
function Main()
frmHub:RegBot(rusian["sBotName"])
end
function ChatArrival(user, data)
data = string.sub(data,1,string.len(data)-1)
s,e,cmd = string.find(data, "%b<>%s+(%S+)")
if cmd == ""..rusian["prefix"]..""..rusian["cmd"].."" then
if rusian["permissions"][user.iProfile] == 1 then
fire(user, data)
else
user:SendData(rusian["sBotName"], "You are not allowed to use this command!")
end
return 1
end
end
function fire(curUser, sData)
messages = {
[1] = "hmmz " ..curUser.sName.. ", Almost hit the bunny...!",
[2] = "\r\n ___________________________] \\ l /\r\n \\__////_(____)_______________0 ------BANG ------>\r\n ) @ ___9mm___________\\_/ / l \\\r\n / //\r\n / (?X?) //\r\n / //\r\n / _____//\r\n\r\n\t" ..curUser.sName.." You hit a Bunny\r\n\The bunny got mad, and he kicked u out.\r\n", -- message on shoot
[3] = ""..curUser.sName..", you hit the bunny in his tail! lol...",
[4] = "HaHaHa " ..curUser.sName.. "You like to fire?! on Bunny's?!",
[5] = "BAM!!! *you mist the bunny" .. curUser.sName..".",
[6] = "oeff fire again" ..curUser.sName.." !",
[7] = "Hmmz " ..curUser.sName.. "You almost hit a bunny, try again!",
[8] = " has started, type !fire to play!"
}
local Fire = math.random(1, rusian["maxmessages"])
if Fire == 2 then
SendToAll(rusian["sBotName"], messages[Fire])
SendPmToNick(curUser.sName, rusian["sBotName"], "Sorry the bunny hit you, and shot in your head! Try again" ..messages[Fire])
if rusian["discortimeban"] == "1" then
curUser:Disconnect()
elseif rusian["discortimeban"] == "2" then
if curUser.bOperator == 1 then
curUser:Disconnect()
else
SendPmToNick(curUser.sName, rusian["sBotName"], "Je heb een tijdban gekregen van/You received a Time ban of "..rusian["timebantime"].." minutes, Try Again")
curUser:TimeBan(rusian["timebantime"])
end
end
else
SendToAll(rusian["sBotName"], messages[Fire])
end
end
Changed: by Optimus now pasted in code style
Try posting using the [ CODE] [ /CODE] thingy (without the space between the "[" and "C" and the "/".
Cheers