Jump to content

Search the Community

Showing results for tags 'settimer'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Multi Theft Auto: San Andreas 1.x
    • Support for MTA:SA 1.x
    • User Guides
    • Open Source Contributors
    • Suggestions
    • Ban appeals
  • General MTA
    • News
    • Media
    • Site/Forum/Discord/Mantis/Wiki related
    • MTA Chat
    • Other languages
  • MTA Community
    • Scripting
    • Maps
    • Resources
    • Other Creations & GTA modding
    • Competitive gameplay
    • Servers
  • Other
    • General
    • Multi Theft Auto 0.5r2
    • Third party GTA mods
  • Archive
    • Archived Items
    • Trash

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


About Me


Gang


Location


Occupation


Interests

Found 14 results

  1. addEventHandler ("onResourceStart", getRootElement(), function() setTimer ( moneyZoneTimerFunction, 2500, 0) local allGreenzones = getElementsByType ("radararea") for i,v in ipairs (allGreenzones) do local r,g,b,a = getRadarAreaColor (v) if (r == 0) and (g == 255) and (b == 0) and (a == 127) then local x,y = getElementPosition (v) local sx,sy = getRadarAreaSize (v) local col = createColCuboid (x,y, -50, sx,sy, 7500) setElementID (col, "greenzoneColshape") end end end) addEventHandler ("onColShapeHit", getRootElement(), function(hitElement, matchin
  2. function enableAccount ( accountJ ) if not isGuestAccount ( accountJ ) then if accountJ then local source = getAccountPlayer ( accountJ ) local XP = getAccountData ( accountJ, "XP" ) or 0 setElementData ( source, "XP", XP ) local Level = getAccountData ( accountJ, "Level" ) or 0 setElementData ( source, "Level", Level ) end
  3. Iae rapaziada, bom estou com um certo problema em um painel q estou criado basicamente o Painel funciona da seguinte forma: O Player ao passar por uma determinada Marker, abre-se o painel onde ele terá uma quantidade de opções dentre elas "Armamentos, Uniformes e a parte de iniciar/finalizar seu expediente (painel voltado mais para corporações!). O problema esta na parte do Expediente o mesmo funciona da seguinte forma: Tem dois Ícones (print abaixo), o Painel Menor contém dois ícones, sendo o Primeiro ( soldado prestando Continência) o Inicio do Expediente e o Segundo o termin
  4. Hola a todos , soy nuevo tengo un resource que necesito reiniciar siempre al entrar al servidor , no se porqué , lo que quiero es que se reinicie despues de 2 minutos , pero que se reinicie esa unica vez lo de hacer que se reinicie ya me quedó con settimer pero no se como hacer para que lo haga una sola vez sería con killtimer? ya lo intenté y nada setTimer( function() --restarting this resource 2 min restartResource(getThisResource()) end, 120000, 0)
  5. Con el CommandHandler "Sube" funciona, pero con el Pe, ¿Que hace? Crea el objeto, pero no lo redirecciona con el SetElementPosition y attach, es como si lo ignorara... ¿Alguna solución? function SubenPasajeros () if CantidadDeAsientos >= 0 then if Asiento1 == 0 then Asiento1 = 1 local vehicle = getPedOccupiedVehicle( client ) x1, y1, z1 = getElementPosition ( client ) Asiento1 = createObject (2035, 1421.958984375, 2624.4677734375, 11.392612457275) setElementPosition ( Asiento1, x1, y1, z1) attachElements( Asiento1, vehicle, 0.95, 0.6, 0, 0,
  6. السلام عليكم شباب ابي مساعدة في عمل حركة للاعب لمدة بضع ثواني وبعد انتهاء الثواني يقوم بالغاء الحركة واسترجاع الحركة العادية الي هيا المشي
  7. السلام عليكم ورحمة الله وبركاته .... مب لاقي شي اسويه ولا اي افكار فقلت خلني اشرح بعض الاشياء .... شرحي رح يكون عن setTimer .... والـ هو مؤقت يسوي شي كل وقت او يسوي شي بعد فترة محددة .... طيب خلنا نبدأ على بكرة الله .... المثال الاول رح اشرح فيه طريقة انشاء شي معين كل فترة معينة -- server function theFunctionName ( ) exports["guimessages"]:outputServer(root,"message from server file.",0,255,0,root) -- YourCode end setTimer ( theFunctionName, 5000, 0 ) -- لاحظ الرقم 0 -- client function theFunctionName ( ) exports["guimessages"]:outputClient("message from client f
  8. Hello. I want create a dx timer which when the player disconnect, and connect again to the server then not reset the timer. Sorry for my bad english :c
  9. ZuKi|R

    Help SetTimer

    Hello, they help me with this problem no as him aria but help need a hand, which is that I want to do is that each true time example each 1 minute repeat this funcion, but I do this and does not do it only repeats once. Already it try of some ways but only repeats once, some suggestion or an error that have ? ------------------- ---Off Element Data setTimer ( function() setElementData(bossDeady[ID][12],"boss",false)end,5000,1) setTimer ( function()removeElementData(bossDeady[ID][12],"boss.name") end,5000,1) setTimer ( function()remove
  10. Ayuda por favor, al matar al "hades" salga por un cierto tiempo el segundo "crazy" sin que respawnee de nuevo al boss "hades" hasta matar al boss "crazy", no logro hacerlo sin que me salga bien solo cuando mato al primero sale los 2 al mismo tiempo que le puse (60 segundos). Server side: function boss0 ( ) hades = exports [ "slothBot" ]:spawnBot ( 1184.654, -2038.601, 69.008, 90, math.random ( 300, 303 ), 0, 0, Nemesis, 38, "hunting", true ) exports.extra_health:setElementExtraHealth(hades, 1000) setElementModel ( hades, 38 ) setElementData (hades,
  11. English: Hello friends, I have a problem with this script posted below, I am a beginner in the moon language, and I would like to know how I can use the setTimer function to give a 2 second delay in the outputChatBox. Portuguese: Olá amigos,Estou com um problema nesse script postado a baixo,sou iniciante na linguagem lua,e gostaria de saber como posso usufruir da função setTimer,para dar um delay de 2 segundos no outputChatBox. function HandlerWasted() valor = math.random( 170, 500 ) outputChatBox("#FFFFFFForam cobrados #FBFF00 $"..tostring ( valor )..",00 #FFFFFFpelos seu
  12. Hello! I don't understand the setTimer wiki, can you please teach me how it works? I would do this if it would work: function hello() local timer = setTimer (60000) -- sets timer to a minute if timer == 0 then -- checks if timer is 0 outputChatBox ("0") -- outputs, that timer is null else return nil end end addEventHandler ("onClientResourceStart", getRootElement(), hello) This is a not working script, can you help me to make it work? Thank you!
  13. I was making a new script with classes for mta, and i need to set a timer inside a method like this. function WorldGrid:updatePlayerZone(player) -- DOING NON RELEVANT SHI T HERE outputChatBox("worldGrid: " .. tostring(worldGrid) .. " player: " .. tostring(player)) setTimer(self:updatePlayerZone, 4000, 1, player) end end This couldnt even compile, because self:updatePlayerZone is not recognized as a function. So.. i checked setTimer mta wiki page. it says: theFunction: The function you wish the timer to call. (Notice: Do not use a 'local' function,
  14. I need some help on: dxDrawText Code: local screenWidth, screenHeight = guiGetScreenSize () local playerRadioChannel = getRadioChannelName(getRadioChannel()) function stationDraw(station) dxDrawText ( playerRadioChannel, screenWidth, screenHeight - 155, screenWidth - 66, screenHeight, tocolor ( 135, 96, 45, 255 ), 1.5, "bankgothic", "right" ) end addEventHandler("onClientPlayerRadioSwitch", getLocalPlayer(), stationDraw) I want the text having border, and staying uppercase, how? I do not know. How can I make it stay on screen for a few seconds and then disappear? I thin
×
×
  • Create New...