Jump to content

.:HyPeX:.

Members
  • Posts

    1,255
  • Joined

  • Last visited

Everything posted by .:HyPeX:.

  1. .:HyPeX:.

    AntiSpam

    Wow, thanks. I was actually thinking this was caused becouse the functions just triggered altogether (timers just were supposed to be a barrier as same time as timers itself.. but they were triggering themselves in once). But this should work. Also, you showed me there that i could make a table inside another one, wich helps alot. Thanks 3NAD
  2. Race when you die you spectate someone, but if you're spectating, you can still calculate the distance 2 players (Spectating different cars/players)? it would work as same? Thanks HyPeX
  3. You could try saving data to a XML, i dont think there's a "Cloud space" for the Serial data where to save that.. Anyways try doing separate funcions for join and quit, that could make it work easier.
  4. finish i fixed it. problem fail just i don't remember ban myself for test Lol, if it would have worked alone, then you would have got to worry
  5. .:HyPeX:.

    PC Specs

    I've threw all the stuff to the thrash and downloaded a clean GTA, this totally fixed any issue.
  6. .:HyPeX:.

    AntiSpam

    Can someone tell my why its not working properly? its outputting the 3 messages(like it activated the 3 functions) when just saying 1 thing. ----Anti-Spam-Script-by-HyPeX-- ----Locals---- local resRoot = getResourceRootElement(getThisResource()) ------------------------------- ----Messages of Startup---- outputChatBox ("#00aaff[AntiSpam]: Script v1.2 by HyPeX Started.",root, 255, 255, 255, true) outputChatBox ("#00aaff[AntiSpam]: Aviable commands: sleft",root , 255, 255, 255, true) ------------------------------- ----Functions--- function credits(onPlayerJoin) outputChatBox ( "Anti-Spam Script By HyPeX Loaded", source, 55, 125, 255 ) end addEventHandler("onPlayerJoin", root, credits) antiSpam = {} antiSpamFlood = {} antiSpamTime = {} function AntiSpam (message, messageType) if messageType == 0 and isTimer(antiSpam[source]) then killTimer(antiSpam[source]) antiSpamFlood[source] = setTimer(function(source) antiSpamFlood[source] = nil end, 10000, 1, source) outputChatBox("[AntiSpam]: You have been Warned.", source, 0, 170, 255) outputChatBox("[AntiSpam]: If you Spam again withing 10 secs, you will be muted.", source, 0, 170, 255) else antiSpam[source] = setTimer(function(source) antiSpam[source] = nil end, 1000, 1, source) end end addEventHandler("onPlayerChat", getRootElement(), AntiSpam) function AntiSpamMute (message, messageType) if isTimer(antiSpamFlood[source]) then outputChatBox("[AntiSpam]: You have been muted for flooding for 5 Mins.", source, 0, 170, 255) outputChatBox("[AntiSpam]: Type /sleft to get your time left muted.", source, 0, 170, 255) antiSpamTime[source] = setTimer(function(source) antiSpamTime[source] = nil end, 300000, 1, source) AntiSpam1 = True end end addEventHandler("onPlayerChat", getRootElement(), AntiSpamMute) function PreventFromMute (message, messageType) if messageType == 0 and isTimer(antiSpamTime[source]) then cancelEvent() outputChatBox("[AntiSpam]: Your message was cancelled becouse you are muted.", source, 0, 170, 255) outputChatBox("[AntiSpam]: Type /sleft to get your time left muted.", source, 0, 170, 255) end end addEventHandler("onPlayerChat", getRootElement(), PreventFromMute) function timerDetails(source) if isTimer(antiSpamTime[source]) then remaining, executesRemaining, totalExecutes = getTimerDetails( antiSpamTime[source] ) outputChatBox("[AntiSpam]: Time left muted: "..remaining/1000, source, 0, 170, 255) else outputChatBox("[AntiSpam]: You are not muted.", source, 0, 170, 255) end end addCommandHandler("sleft", timerDetails) function stopping () timers = getTimers ( 310000 ) for timerKey, timerValue in ipairs(timers) do killTimer ( timerValue ) end end addEventHandler( "onClientResourceStop", resRoot, stopping) Thanks in advance HyPeX
  7. .:HyPeX:.

    PC Specs

    Okay, tried again and this time i got the PasteBIN Link: http://pastebin.mtasa.com/561298071
  8. .:HyPeX:.

    PC Specs

    This should help a bit while i get MTADiag Answer. Crash Report: Version = 1.3.4-release-5810.0.000 Time = Wed Sep 18 18:29:33 2013 Module = C:\WINDOWS\system32\kernel32.dll Code = 0xE06D7363 Offset = 0x00012FD3 EAX=0022E120 EBX=04B93F64 ECX=00000000 EDX=0022E1C4 ESI=0022E1A8 EDI=04B93F60 EBP=0022E170 ESP=0022E11C EIP=7C812FD3 FLG=00200206 CS=001B DS=0023 SS=0023 ES=0023 FS=003B GS=0000 EDIT//: MTA Diag Says i'm missing one or more file of GTA and that i should reinstall it whilst i'm running it perfectly alone (not touching MTA) is that possible? EDIT2//: I'm downloading GTA from another link and going to reinstall it again to check. EDIT3//: Checked that MTADiag Says i'm missing the file "/text/american.gxt". I've got instead a spanish version wich is "/text/spanish.gxt", what should i do? EDIT4//: There were alot of other non-common GTA files into audio folder (i suppose its the translation) and while checking it MTADiag failed to give me an answer, it copied this into my clipboard "http://pastebin.mtasa.com/error[No code2 specified]"
  9. .:HyPeX:.

    PC Specs

    Seems like GTA:SA alone runs perfectly, only while starting MTA:SA it has problems.
  10. .:HyPeX:.

    PC Specs

    Hi guys, i'm going to run GTA:SA on my Grandfather's PC for now, and i'm not sure if the GPU and RAM will run it correctly. I'm on a 1GB DDRR3 RAM, and a AMD Athlon 64 3200+ CPU. how much juice i can make with that? since i'm just installing now.. Thanks HyPeX EDIT: It closes alone just when starts, any help on this? running checks on my side.
  11. .:HyPeX:.

    OnCommand?

    Guys is there a function to detect or trigger when player does a command? i'm searching to avoid comand flooding. and also, can i detect if a player uses the say with "/command" ? (like if i can make mta or a script recognize read if on player chat it outputs the "/command" or it wont read nothing.
  12. thanks for the list, bookmarked!
  13. by the way, where i can find those variables of the find? there you used "%u", where i can find all the values lua has? i couldnt find them on the lua reference manual (wich is linked from here).
  14. i'm not sure how to translate that part with the bound, but i was thinking of 2 separate functions, and like return to the function before if that doesnt works and it then should run correctly... (lets say it would trigger the 1st one as the 2nd one wasnt runing). But then it comes to the part, how i call it? as you said return doesnt do it. hows a caller, as you said?
  15. Thanks!, i was also thinking of detecting letter by letter (since mta is uppercase-sensitive), but this will make it easier.
  16. but there's no caller at all almost, it is onplayerchat, what should i do?
  17. you could use a math value.. it will be hard, since you already know the 2 positions.. EDIT//: the math value should be enought for facing the "distance", sorry, i'll be looking into rotation.
  18. I will send some pics / screenshots soon. And you may trust me if you want... I never scam anybody, never done that before. I am honest but it is your decision to trust me or not. Trust me however you want... I wont do anything bad like scamming you or something. You just joined, the fact you never scammed anybody isnt reliable.
  19. wich function can detect capitals in player's chat, or how can i detect them?
  20. so it will return to where? the second if in this case?
  21. So then, is there a way to make what i want with my script? since return will not do it..
  22. i got some short questions: 1#: why it is number 5? 2#: i can make it just return to the if, or when returning to the function it will ignore the return and follow? lets say on my script, i want to return just like ignoring the last if (lets say it should return to "if messageType == 0..") function AntiSpam (message, messageType) if messageType == 0 and isTimer(antiSpam[source]) then if isTimer(antiSpamTimer[source]) then killTimer(antiSpamTimer[source]) cancelEvent () antiSpam[source] = setTimer(function(source) antiSpam[source] = nil end, 300000, 1, source) else return
  23. Wich parent will it return to? the function, or the if before? and if if i have to use the argument, can you explain me better or show me an example? i didnt understand much how to use it.
  24. make the script go back and continue like that line doesnt exist (the if in this case)
×
×
  • Create New...