Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 26/08/19 in all areas

  1. السلام عليك سكريبت بسيط تركبه من لوحة الادمنيه يشغل سي بق -----------------------ملاحظة تستطيع وضع السكريبت في ملف سيرفر ويصير شغال --------------------------- سي بق مو مشفر ولاي سيرفر setGlitchEnabled ( "quickreload", true ) setGlitchEnabled ( "fastmove", true ) setGlitchEnabled ( "fastfire", true ) setGlitchEnabled ( "crouchbug", true ) ----لاغلاق السي بق setGlitchEnabled ( "quickreload", false ) setGlitchEnabled ( "fastmove", false ) setGlitchEnabled ( "fastfire", false ) setGlitchEnabled ( "crouchbug", false )
    2 points
  2. السلام عليكم ، انا لي سنوات باللعبه بديت بأسم Naif35 بعد ما اتقنت اللعبه وفهمت لها زين تغير النك نيم ل ALCKASER بعد فتره بالنك نيم هذا انحظرت بالموقع هذا وسويت حساب اخر بأسم اخر وتعلمت اشياء كثيره واتقنتها ثم حطيت نكي هذا من ٦ سنوات اللي هو EH10 وبالنهايه اقول لكم انا EH10 هو نفسه ALCKASER للي يتذكرني طبعا من قبل ست سنوات. وطبعا انا تارك اللعبه من اكثر من ثلاث سنوات.
    1 point
  3. local rectAlpha = 0; local state = "up"; function test() if state == "up" then rectAlpha=rectAlpha+1 end if state == "down" then rectAlpha=rectAlpha-1 end if rectAlpha == 255 then state = "down" elseif rectAlpha == 0 then state = "up" end dxDrawRectangle(416, 174, 498, 373, tocolor(0, 0, 0, rectAlpha), false) end addEventHandler("onClientRender", root, test)
    1 point
  4. dxDrawImage3D useful function (based upon dxDrawMaterialLine3D) is what you're looking for.
    1 point
  5. In this case, you need to check to see if any of the two windows are visible, for example: showCursor(guiGetVisible(window1) or guiGetVisible(window2), true) -- or you can make it shorter with oop showCursor(window1.visible or window2.visible, true)
    1 point
  6. For both resources. A https://wiki.multitheftauto.com/wiki/TriggerEvent Set the base element to resourceRoot. B https://wiki.multitheftauto.com/wiki/AddEventHandler Set the attachedTo element to resourceRoot as well. And they will not interfere with each other, even when the event name is the same.
    1 point
  7. Are we talking about 1 resource or multiple ones? Because resource A can't disable the cursor for resource B. GUI's do not have any influence on the cursor function.
    1 point
  8. It's totally expected, when you hide the gui at the first time, isCursorShowing will return false after, so when you execute the function again it will show the cursor, as simple as that: not true = false not false = true So, it you only want to hide it, why checking for its visibility showCursor(false, true)
    1 point
  9. Na verdade não vai funcionar com objects: Então nesse caso você precisa criar o object no lado cliente. Fiz poucas mudanças no código, como uma verificação com isElementVisibleTo no onMarkerHit e limpar a tabela quando o player sair. local Marker_Start = createMarker (-111.1279296875, -4.025390625, 3.1171875 -1, "cylinder", 1.5, 20, 70, 230, 80) local Blip_Start = createBlipAttachedTo(Marker_Start, 42) local Plantas = { [1] = {-129.10345458984,44.776748657227,3.1171875}, [2] = {-140.21569824219,35.499088287354,3.1171875}, [3] = {-138.20004272461,22.663047790527,3.1171875}, [4] = {-148.60707092285,14.514667510986,3.1171875}, [5] = {-145.90365600586,3.4965758323669,3.1171875}, [6] = {-156.54542541504,-6.012909412384,3.1171875}, [7] = {-154.13597106934,-17.593681335449,3.1171875}, [8] = {-164.40188598633,-27.394626617432,3.1171875}, [9] = {-162.29643249512,-39.118156433105,3.1171875}, [10] = {-171.7504119873,-45.86404800415,3.1171875}, } local Veh_Trator = {} local Coronas_Plantas = {} local Obj_Plantas = {} local Letra = "K" function jobStart(theJogador) if getElementType(theJogador) == "player" then if not getPedOccupiedVehicle(theJogador) and not Coronas_Plantas[theJogador] then exports.Scripts_OnMarkerMsgs_:delete(theJogador) jobStop() local x, y, z = unpack (Plantas[1]) Coronas_Plantas[theJogador] = createMarker (x, y, z -1, "corona", 2, 0, 255, 0, 80, theJogador) setElementData (Coronas_Plantas[theJogador], "DnO_Coronas", theJogador) setElementData (Coronas_Plantas[theJogador], "Plantas", 1) Obj_Plantas[theJogador] = createObject(804, x, y, z) setElementData(Obj_Plantas[theJogador], "DnO_Obj", theJogador) setObjectScale(Obj_Plantas[theJogador], 1.0) setElementCollisionsEnabled (Obj_Plantas[theJogador], false) setElementModel(theJogador, 158) -- use esta função já que setPedSkin é obsoleta Veh_Trator[theJogador] = createVehicle(531, -123.7235625, 64.36328125, 3.3815598964391, 0, 0, 156) setElementData(Veh_Trator[theJogador], "DnO_Trator", theJogador) warpPedIntoVehicle( theJogador, Veh_Trator[theJogador]) exports.Scripts_Dxmessages:outputDx (theJogador,"Colher todas as Plantas!!", "info") addEventHandler ("onMarkerHit", Coronas_Plantas[theJogador], Hit_Coronas) end end end function emarker(marker,md) if (md) then if isPedInVehicle ( source ) then return end if marker == Marker_Start then if getElementData ( source, "Emprego" ) == "Fazendeiro" then exports.Scripts_OnMarkerMsgs_:create(source,"Aperte 'K' Para se Demitir do Emprego de Fazendeiro") bindKey ( source, Letra, "down", jobStop ) else exports.Scripts_OnMarkerMsgs_:create(source,"Aperte 'K' Para Aceitar o Emprego de Fazendeiro") bindKey ( source, Letra, "down", jobStart ) end end end end addEventHandler("onPlayerMarkerHit",getRootElement(),emarker) function emarker2(marker,md) if (md) then if isPedInVehicle ( source ) then return end if marker == Marker_Start then exports.Scripts_OnMarkerMsgs_:delete(source) unbindKey ( source, Letra, "down", jobStart ) unbindKey ( source, Letra, "down", jobStop ) end end end addEventHandler("onPlayerMarkerLeave",getRootElement(),emarker2) function Hit_Coronas(thePlayer) if (thePlayer == getElementData (source, "DnO_Coronas")) and isElementVisibleTo(source, thePlayer) then if isPedInVehicle ( thePlayer ) then if (getElementData (source, "Plantas") < #Plantas) then exports.Scripts_Dxmessages:outputDx(thePlayer, "Você colheu a Planta. Siga para a próxima.("..getElementData(source, "Plantas").."/"..#Plantas..")", "success") setElementData (source, "Plantas", getElementData (source, "Plantas") + 1) local x, y, z = unpack(Plantas[getElementData(source, "Plantas")]) setElementPosition(source, x, y, z -1) setElementPosition(Obj_Plantas[thePlayer], x, y, z) else removeEventHandler ("onMarkerHit", Coronas_Plantas[thePlayer], Hit_Coronas) jobStop( source ) exports.Scripts_Dxmessages:outputDx (thePlayer,"Você terminou de Colher Todas as Plantas bom Trabalho!!", "success") end end end end -- limpar as tabelas quando o jogador sair addEventHandler("onPlayerQuit", root, function() jobStop( source ) end) function jobStop(source) if Obj_Plantas[source] then if isElement(Obj_Plantas[source]) then destroyElement(Obj_Plantas[source]) end Obj_Plantas[source] = nil end if Veh_Trator[source] then if isElement(Veh_Trator[source]) then destroyElement(Veh_Trator[source]) end Veh_Trator[source] = nil end if Coronas_Plantas[source] then if isElement(Coronas_Plantas[source]) then destroyElement(Coronas_Plantas[source]) end Coronas_Plantas[source] = nil end end function resourceStartNotify ( resourcename ) outputDebugString ( "Script " .. getResourceName(resourcename) .. " carregado." ) end addEventHandler( "onResourceStart", resourceRoot, resourceStartNotify ) -- use resourceRoot para o evento acionar só pra este resource
    1 point
  10. Read this about CD16 error: https://forum.multitheftauto.com/topic/105515-help-cd16/?do=findComment&comment=908569 https://forum.multitheftauto.com/topic/90317-disconnecting-for-no-reason/?do=findComment&comment=819646 https://forum.multitheftauto.com/topic/95511-error-cd16/?do=findComment&comment=855986 I will have to lock this topic because the problem is most often different for those getting these errors and the troubleshooting process therefore is individual. I'm planning to write a general-purpose guide on the most commonly effective fixes for the problem soon. Anyone reading this and is encountering the same problem should create a new topic to post in and get help there
    1 point
  11. Please download and run MTADiag and follow the instructions. Post any Pastebin URL MTADiag gives you in this topic. Press 'y' for when asked "Do you want MTADiag to auto-fix your installation?"
    1 point
  12. Every time i try to connect to server, I get an CD16/CD09 a few seconds later. I reset my router, disabled firewall and antivirus, ran netfix.bat, reinstalled MTA SA and GTA SA cleanly, and nothing worked!
    0 points
×
×
  • Create New...