NoviceWithManyProblems

Members
  • Content Count

    62
  • Joined

  • Last visited

Community Reputation

4 Neutral

About NoviceWithManyProblems

  • Rank
    Snitch

Recent Profile Visitors

326 profile views
  1. yes exatcly @Patrick so then there's other way to do this?
  2. why i can trigger this? no db3 errors server: test = { {0, 0, 5}, {1234, 1234, 1234} } triggerClientEvent(resourceRoot, "trigger", resourceRoot, test) client: addEvent("trigger", true) addEventHandler("trigger", resourceRoot, function(tabletest) outputChatBox(inspect(tabletest)) end) and nothing happens
  3. Sorry, I have already abandoned this idea and I didn't look into this topic.
  4. why this doesn't work? local marker = createMarker(--[[...]]) createBlipAttachedTo(marker --[[...]]) addEventHandler("onClientMarkerHit", marker, function(he, md) destroyElement(source) end) I want to destroy marker with blip
  5. Hi! How can I make dxDraw input text like https://wiki.multitheftauto.com/wiki/GuiCreateEdit?
  6. How can I wrap text like this?
  7. use /debugscript 3 and watch errors after starting script and look at Required Arguments here: https://wiki.multitheftauto.com/wiki/CreatePickup or just use: https://wiki.multitheftauto.com/wiki/SetElementAlpha untested, but I think that will works local pickups = { {3334.8000488281, -7807.5, 673.79998779297, 2, 9, 1, 200}, {3332.8000488281, -7805.5, 673.79998779297, 2, 24, 1, 200}, {3330.8000488281, -7803.5, 673.79998779297, 2, 27, 1, 200}, {3328.8000488281, -7801.5, 673.79998779297, 2, 29, 1, 200}, {3326.8000488281, -7799.5, 673.79998779297, 2, 31, 1, 200}, {3324.8000488281, -7797.5, 673.79998779297, 2, 34, 1, 200}, {3322.8000488281, -7895.5, 673.79998779297, 2, 16, 1, 200} } for k,v in ipairs(pickups) do createPickup(v[1], v[2], v[3], v[4], v[5], v[5], v[6], v[7]) setElementAlpha(v, 255) end
  8. Ok. client side: addEventHandler("onClientPlayerWasted", localPlayer, function() setTimer(function(source) triggerServerEvent("spawnWastedPlayer", resourceRoot, source) end, 60000, 1, source) end) server side addEvent("spawnWastedPlayer", true) addEventHandler("spawnWastedPlayer", resourceRoot, function(source) spawnPlayer(source, 0, 0, 0) end) why practically never waiting for a spawn takes 1 minute, but it's "randomly", but never longer than that 1 minute?
  9. Ok. client side: addEventHandler("onClientPlayerWasted", localPlayer, function() setTimer(function(source) triggerServerEvent("spawnWastedPlayer", resourceRoot, source) end, 60000, 1, source) end) server side addEvent("spawnWastedPlayer", true) addEventHandler("spawnWastedPlayer", resourceRoot, function(source) spawnPlayer(source, 0, 0, 0) end) why practically never waiting for a spawn takes 1 minute, but it's "randomly", but never longer than that 1 minute?
  10. ok. thx, but look at this: local peds = { {...}, {...} } for k,v in ipairs(peds) do createPed(...) setElementData(v, "created", true) setElementData(v, "name", v[5]) -- eg. "bobby" end for k,v in ipairs(getElementsByType("ped") do if getElementData(v, "created") then pedsToTrigger = {} table.insert(pedsToTrigger, v) triggerClientEvent(thePlayer, "someEvent", resourceRoot, pedsToTrigger) end end -- client side addEvent("someEvent", true) addEventHandler("someEvent", resourceRoot, function(pedsToTrigger) -- some gui functions pedGridList = guiCreateGridList(0, 0, 50, 50, false) if pedsToTrigger then for _,v in ipairs(pedsToTrigger) do guiGridListAddRow(pedGridList, getElementData(v, "name")) end end end) why this creates me two separate gridlist instead of introducing them to one? it looks like this:
  11. Hi, how can I insert "userdata" to table? This doesn't work. someTable = {} table.insert(v) "v" are elements from the "for" loop outputChatBox(type(v)) outputChatBox(inspect(v)) output: userdata elem:object[1220]0x1332b or how can I trigger table with this objects?
  12. how can i make only once time Timer? myTimer = setTimer(function() outputChatBox("only one time") killTimer(myTimer) end, 1000, 0) i have error: bad argument @ 'killTimer' expected Lua-timer at argument 1, got nil (killTimer(myTimer)