Vunili Posted May 28, 2016 Posted May 28, 2016 السلام عليكم بغيت مود سبام لما الاعب يكتب شي ثم يرجع يكتب مايقدر الا بعد 5 ثواني دورت قوقل نفضته نفض ما لقيت المود -Retired-
YourMind Posted May 28, 2016 Posted May 28, 2016 غير مجرب v={} addEventHandler ("onPlayerCommand",root, function () if v[source] >= 5 then cancelEvent() outputChatBox ("SPAM",source,255,5,5) v[source] = 0 end v[source] = v[source] + 1 setTimer(function(source) v[source] = 0 end,1500,1,source) end)
Vunili Posted May 28, 2016 Author Posted May 28, 2016 غير مجرب v={} addEventHandler ("onPlayerCommand",root, function () if v[source] >= 5 then cancelEvent() outputChatBox ("SPAM",source,255,5,5) v[source] = 0 end v[source] = v[source] + 1 setTimer(function(source) v[source] = 0 end,1500,1,source) end) في خطأ بأول سطر -Retired-
Mhmd.z Posted May 28, 2016 Posted May 28, 2016 addCommandHandler("theCommand", function() if isTimer(theTimer) then outputChatBox("wait 5 sec") else outputChatBox("Command") theTimer = setTimer(function(source) end,5000,1) end end )
nxFairlywell Posted May 28, 2016 Posted May 28, 2016 (edited) local count={} addEventHandler("onPlayerChat", root, function( msg, tp ) if count[source] == nil then count[source]=1 setTimer( function() count[source]=nil end, 5000, 1 ) else cancelEvent( ) outputChatBox("Don't spam", source) end end ) Edited May 28, 2016 by Guest Discord ID : nxFairlywell#6895
#Soking Posted May 28, 2016 Posted May 28, 2016 (edited) TableSpam = { } addEventHandler("onPlayerChat", root, function ( ) if isTimer( TableSpam[source] ) then cancelEvent() outputChatBox('Please wait 5 sec',source,255,255,255,true) else TableSpam[source] = setTimer(function(source) TableSpam[source] = nil end, 5000, 1, source) end end ) Edited May 28, 2016 by Guest
Adham Posted May 28, 2016 Posted May 28, 2016 (edited) غير مجرب ^ antiSpam = {} function antiChatSpam() if isTimer(antiSpam[source]) then cancelEvent() outputChatBox("SPAM", getRootElement(), 255, 255, 0,true) setPlayerMuted(source, true) setTimer ( antiSpam, 60000, 1, source) else antiSpam[source] = setTimer(function(source) antiSpam[source] = nil end, 1000, 1, source) end end addEventHandler("onPlayerChat", root, antiChatSpam) Edited May 28, 2016 by Guest قد تكونآمنيآتنآ حزينه !وآحلآمُنآ ملت طآبور آلإنتِظآر لكنهآ ،تتشبث بآلأمل فنفوسُنآ خُلقت لتقول غداً آجمل
#Soking Posted May 28, 2016 Posted May 28, 2016 لعبه بدي اسالك وين الفنكشن يلي انت مسويله تيمر دا ؟ autoUnmute هههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههههه
Adham Posted May 28, 2016 Posted May 28, 2016 اعتذر . تم التعديل# قد تكونآمنيآتنآ حزينه !وآحلآمُنآ ملت طآبور آلإنتِظآر لكنهآ ،تتشبث بآلأمل فنفوسُنآ خُلقت لتقول غداً آجمل
Vunili Posted May 28, 2016 Author Posted May 28, 2016 ي اخوان شكلكم ما فهمتو قصدي ابي لما واحد يتكلم او يكتب شي ما يقدر يكتب الا بعد 5 ثواني -Retired-
nxFairlywell Posted May 28, 2016 Posted May 28, 2016 ي اخوان شكلكم ما فهمتو قصدي ابي لما واحد يتكلم او يكتب شي ما يقدر يكتب الا بعد 5 ثواني خذ الكود اللي حطيته عدلته لك Discord ID : nxFairlywell#6895
Vunili Posted May 28, 2016 Author Posted May 28, 2016 ي اخوان شكلكم ما فهمتو قصدي ابي لما واحد يتكلم او يكتب شي ما يقدر يكتب الا بعد 5 ثواني خذ الكود اللي حطيته عدلته لك اقدر اكرر لما واحد يكرر يجيه Please wait 5 scd -Retired-
Vunili Posted May 28, 2016 Author Posted May 28, 2016 كودك مب شغال جنرالجرب كودي , انا متاكد منه نفس الشي اقدر اكرر -Retired-
nxFairlywell Posted May 28, 2016 Posted May 28, 2016 كودك مب شغال جنرالجرب كودي , انا متاكد منه .____. حتى كودك مو شغال + اما ماجربت كودي و سويته بالجوال @صاحب الموضوع تقدر تسوي تايمر و تزود على اي متغير تحطه كل ثانيه لين 5 ثواني و تقفل التايمر وكل مايكتب بالشات تحط للمتغير تو سترنق وتحطه بالشات اذا ما اشتغل الكود شف اي كود من اكواد الشباب فوق و سو نفس الطريقه Discord ID : nxFairlywell#6895
#Soking Posted May 28, 2016 Posted May 28, 2016 اطفي التاج + الفري روم يا نوووووووووووووووووووووووووووب هههههههههههههههههههههههههههه انا مجربه وششششششغال
Vunili Posted May 28, 2016 Author Posted May 28, 2016 اطفي التاج + الفري روم يا نوووووووووووووووووووووووووووبهههههههههههههههههههههههههههه انا مجربه وششششششغال اوه نسيت والله طيب لو ابيه مع التاج ؟ -Retired-
Vunili Posted May 28, 2016 Author Posted May 28, 2016 لازملك تعديل يا خبيبي اطرح الاكواد اطرح خلاص يعطيكم العافية انا سويته بنفسي طيب ابي السبام ما يجي للكونسل .؟ -Retired-
#Soking Posted May 28, 2016 Posted May 28, 2016 TableSpam = { } Serials = { ["Your Serial"] = true, } addEventHandler("onPlayerChat", root, function ( ) for _,Valc in ipairs(getElementsByType("player")) do if ( not Serials[getPlayerSerial(Valc)] ) then if isTimer( TableSpam[source] ) then cancelEvent() outputChatBox('No Spam',source,255,255,255,true) else TableSpam[source] = setTimer(function(source) TableSpam[source] = nil end, 1500, 1, source) end end end end )
SycroX Posted May 28, 2016 Posted May 28, 2016 local SpamTicket = { } local Spams = { } local Messages = { } local MessagesNum = { } local Settings = { } TimeBetweenMessages = 5*1000 -- حط الوقت الي تباه بين كل رسالة و رسالة MessagesNumbers = 4 addEventHandler( "onPlayerChat", getRootElement( ), function( message ) if isObjectInACLGroup ("user."..getAccountName(getPlayerAccount(source)),aclGetGroup("Console")) then return end if not Spams[ source ] then Spams[ source ] = true SpamTicket[ source ] = getTickCount( ) Messages[ source ] = message else if getTickCount( ) - SpamTicket[ source ] > Settings.delay then MessagesNum[ source ] = 0 Messages[ source ] = nil; SpamTicket[ source ] = getTickCount( ) return else if MessagesNum[ source ] >= Settings.msgNum then SpamTicket[ source ] = getTickCount( ) cancelEvent( ) elseif message == Messages[ source ] then cancelEvent( ) end MessagesNum[ source ] = MessagesNum[ source ] + 1 end end Messages[ source ] = message end ) addEventHandler( "onPlayerJoin", getRootElement( ), function( ) MessagesNum[ source ] = 0 end ) addEventHandler( "onResourceStart", getResourceRootElement( getThisResource() ), function( ) Settings.delay = TimeBetweenMessages Settings.msgNum = MessagesNumbers for _, plr in pairs( getElementsByType( "player" ) ) do MessagesNum[ plr ] = 0 end end ) Chillin' with some demons, satans and vamps
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now