PtokaX forum

Archive => Archived 4.0 boards => Request for Lua 4 scripts => Topic started by: dvxjunkie on 16 May, 2004, 05:18:42

Title: bad user from past gets flooded after login
Post by: dvxjunkie on 16 May, 2004, 05:18:42
can any one finish this so it floods the user?


botname = "SweetRevenge"
badusers = {"asswipe1","asswipe2","asswipe3"}
floodmessege = "YOU ARE NOT WELCOME HERE DO NOT ATTEMPT LOGGING IN HERE AGAIN"
times = "2000"
function Main()
frmHub:RegBot(botname)

end

function NewUserConnected(curuser)
for key,checkWord in badusers do
if strfind(curUser.sMyInfoString, checkWord, 1, 1) then

-- need help at this point

Title:
Post by: [NL]ZeroX on 16 May, 2004, 10:07:44
try this:

for i = 0, times, 1 do
   curUser:SendData(botname, floodmessege)
end

Greets ZeroX

lol i tried out your script, it works whit that code and my client taked like 5~10 seconds to handle all the 2000 messages :)
Title: improovement ideas before i put this in finished scripts?
Post by: dvxjunkie on 16 May, 2004, 17:33:55
-- NickFlooder by ?V?J??K?? and [NL]Zerox and well a little of everyone. Floods known troublemakers by thier nick on entry. be carefull because a user named robert and a user named roberto whould both get flooded using the trigger robert so avoid nicks with this charecteristic. ANYONE have any ideas to improove ths one?

botname = "SweetRevenge"

function Main()
frmHub:RegBot(botname)
end

badusers = {"asswipe1","asswipe2","asswipe3"}
floodmessege = "YOU ARE NOT WELCOME HERE DO NOT ATTEMPT LOGGING IN HERE AGAIN"
times = "2000"

function NewUserConnected(curuser)
for key,checkWord in badusers do
if strfind(curuser.sMyInfoString, checkWord, 1, 1) then

for i = 0, times, 1 do
curuser:SendData(botname, floodmessege)
end
end
end
end
Title:
Post by: [NL]ZeroX on 16 May, 2004, 19:02:28
be carefull because a user named robert and a user named roberto

what about changing:
if strfind(curuser.sMyInfoString, checkWord, 1, 1)then to
if (curuser.sName == checkWord) then
Greetz ZeroX
Title:
Post by: dvxjunkie on 16 May, 2004, 22:54:46
cool I knew there had to be a way to do that thanks  :)
Title:
Post by: pHaTTy on 17 May, 2004, 00:09:37
ok heres a few updated for ya while i was bored


botname = "SweetRevenge"

function Main()
frmHub:RegBot(botname)
end

badusers = {
["asswipe1"] = 2000,
["asswipe2"] = 200,
["asswipe3"] = 20,
}

floodmessege = "I AM NOT WELCOME HERE I SHOULD NOT ATTEMPT LOGGING IN HERE AGAIN"

function NewUserConnected(curuser)
for key,checkWord in badusers do
if strfind(curuser.sMyInfoString, checkWord) then
for i = 0, badusers[curuser.sName], 1 do
curuser:SendData( "$Hello "..user.sName..i )
curuser:SendData( "$To: "..user.sName.." From: "..user.sName..i.." $<"..user.sName..i.."> "..floodmessage.."|")
end
curuser:Disconnect() -- // bye bye prick
end
end
end

Title:
Post by: dvxjunkie on 19 May, 2004, 21:48:56
cool you have good ideas when bored! so with this, they get flooded with $hello at handshake time as well as the main chat plus different flood amounts for different users? awsome :)