Jump to content

Erlkonig

Members
  • Content Count

    65
  • Joined

  • Last visited

Community Reputation

6 Neutral

About Erlkonig

  • Rank
    Snitch

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Thank you very much! Also thanks for the topic with tutorial. It works already. I have to learn it!
  2. Is the the syntax which I used is correctly? Just a moment, I'll send the picture. The same HTTP request with firefox:
  3. Hi! Thanks for reply! I tried but the table is empty while the string returns the information. The code below: function newResult(getupdates) if getupdates then outputConsole("Start of iteration") local jsonUpdates = fromJSON(getupdates) for i, v in ipairs(jsonUpdates) do outputConsole(i..": "..v) end outputConsole("End of iteration") outputConsole(getupdates) else outputDebugString("ERROR!", 3) end end fetchRemote(link, newResult)
  4. Hello everyone! Im trying to solve this problem already 3rd day but no results. I am calling HTTP request and it returns JSON. For example it works in browser (Firefox doing it better). When Im trying to call that request with a callRemote, I got returned the table but when I list that with a iteration it's clear as I understand. When I am doing that with fetchRemote, it returns the correct string but I need that the table ofc . I am sure that I am doing something wrong but I do not know what exactly I am doing wrong. Thanks for everyone who will reply.
  5. What did you write for this time?
  6. I tested this script, it works. Can you try to test it the default MTA server?
  7. Erlkonig

    help me

    As I understand you correctly? You want to fix the vehicle when the vehicle cloose to broke. You can use that in client-side and vehicles will never break. addEventHandler("onClientVehicleDamage", getRootElement(), function() cancelEvent() end)
  8. Erlkonig

    help me

    timer = {} function incHp(veh) timer[veh] = setTimer(setElementHealth(veh), 10, 10, veh, getElementHealth(veh)+5) end addEventHandler("onVehicleEnter", root, incHp) function stopincHP(veh) if(isTimer(timer[veh] ))then killTimer(timer[veh]) end end addEventHandler("onPlayerVehicleExit", root, stopincHP) I just put it in the "code". 1) You're using "onVehicleEnter" which returned as 1st "thePed", not vehicle. You need "onPlayerVehicleEnter". 2) About setTimer. You have to reference a function or create a function inside. What exactly do you want to do?
  9. Are you sure that this is the client-side?
  10. Can you show your code please? Did you try the group ID 3?
  11. Erlkonig

    help me

    https://wiki.multitheftauto.com/wiki/AttachElements
  12. The problem was resolved. Timer was inside the eventHandler The topic can be closed.
  13. Erlkonig

    help me

    Do you want just to attach the weapon object?
  14. Erlkonig

    help me

    -- client addEventHandler( "onClientKey", root, function(button,press) if button == "1" and press then triggerServerEvent("changeVehicleMode", localPlayer, "sportmod") elseif button == "2" and press then triggerServerEvent("changeVehicleMode", localPlayer, "business") end end ) -- server function setVehicleVelocity(mode) local veh = getPedOccupiedVehicle(client) if (not veh) or getPedOccupiedVehicleSeat((client) ~= 0 ) then return end if (mode == "sportmod") then setVehicleHandling(veh, "maxVelocity", 320) setVehicleHandling(veh, "engineAcceleration", 20) se
×
×
  • Create New...