Jump to content

TAPL

Retired Staff
  • Posts

    7,337
  • Joined

  • Days Won

    11

Everything posted by TAPL

  1. TAPL

    Doesn't work

    i don't understand why you are using event onPlayerLogin when an player join to server it's almost will not be in team also what do you think? the element data will set only when the player join, you're joining your server and restart the script and you will say (not work) lol you should set the element data when you using setPlayerTeam.
  2. TAPL

    Resource

    what is firefly? also do you think that anyone here will script this for you? If you can't make that then learn and make it by yourself or pay some one to make it for you.
  3. TAPL

    Need Help

    what is not work? does the vehicle exist?
  4. TAPL

    Need Help

    https://wiki.multitheftauto.com/wiki/AddEventHandler https://wiki.multitheftauto.com/wiki/Event_system https://wiki.multitheftauto.com/wiki/Client so for example if we attach the trigger to root there will be no source and to know who was the client trigger we use client variable addCommandHandler("name", function() triggerServerEvent("onGreeting",root) end) addEvent("onGreeting", true) addEventHandler("onGreeting", root function() outputChatBox("The client name is: "..getPlayerName(client)) end) also if we use localPlayer Instead of root the source will be the localPlayer and client will be the same as localPlayer and here source is the same client (source == client) so we can use source and we can use client no difference addEventHandler("onClientGUIClick",GridlOwnerCar,function(button) if(button=="left")then local rowindex, columnindex = guiGridListGetSelectedItem ( GridlOwnerCar ) local carname = guiGridListGetItemText ( GridlOwnerCar, rowindex, columnindex) triggerServerEvent("PCar", localPlayer, carname) end end,false) addEvent("PCar",true) addEventHandler("PCar",root,function(carname) if(carname ~= "")then for i,cars in ipairs(getElementsByType("vehicle")) do if(getVehicleName(cars)==carname)then createBlipAttachedTo(cars,0,3,0,0,0,0,0,65535,client) end end end end)
  5. TAPL

    Need Help

    What is the difference between client and source?
  6. TAPL

    Need Help

    lol if(carname=="")then should be if(carname ~= "")then
  7. TAPL

    Need Help

    Yes that what i want I want attached a blip to vehicle name that are saved into grid list
  8. TAPL

    Need Help

    getVehicleModelFromName Returns an integer and createBlipAttachedTo first Argument Required element ----------------------------------- hey topic owner are you F*** idiot or what? you want attached a blip to vehicle name that are saved into grid list? epic fail
  9. جرب تطفي بالمودات واحد واحد و بتكشف المود المسبب للكراش
  10. TAPL

    Need Help

    function PinCar(thePlayer) local vehicule = getPedOccupiedVehicle(thePlayer) if (vehicule) then local blip = createBlipAttachedTo(vehicule, 19, 4, 255, 0, 0, 255, 0, 99999.0, thePlayer) else outputChatBox("vehicule not found",thePlayer,255,0,0) end end addEvent("PinCar", true) addEventHandler("PinCar", getRootElement(), PinCar) if you show the trigger this would be better
  11. TAPL

    Question + Bug

    ./mta-server -d
  12. no sure, he edit it before you post with more than 1 hour
  13. you can't read or what?
  14. نفس الكود ما غيرت شي حبيبي من قال أن الكود الي حطيته أنا يصك ميوت من أف1؟ و من قال لك يبي يعطل الأف 1 عن طريق الأدمنية؟ قال يبي كود و عطيناه وخلاص بلا زياده مشاركات -_-"
  15. --Client Side-- triggerServerEvent("updateInfo",localPlayer) statsmain = guiCreateWindow(200,200,500,500,"userpanel",false) maintab = guiCreateTabPanel(0,0.06,1,1,true,statsmain) tabserver= guiCreateTab("stats ",maintab) ModeLable = guiCreateLabel(0.50,0.33,0.96,0.22,"",true,tabserver) function info(message) guiSetText(ModeLable,"Game Mode: "..message) end addEvent("gtype",true) addEventHandler("gtype",root,info) --Server Side-- function sendmaininfo() triggerClientEvent(source,"gtype",source,getGameType()) end addEvent("updateInfo",true) addEventHandler("updateInfo",root, sendmaininfo)
  16. you means this? https://wiki.multitheftauto.com/wiki/GetAllElementData
  17. لازم تعدل على الفريروم function toggleFRWindow() if getElementData(loaclPlayer,"muteF1") then return end if isWindowOpen(wndMain) then showCursor(false) hideAllWindows() colorPicker.closeSelect() else showCursor(true) showAllWindows() end end تبي تصك ميوت أف1 ؟ خخ بسيطة setElementData(player,"muteF1",true) تبي تفك؟ setElementData(player,"muteF1",false)
  18. https://wiki.multitheftauto.com/wiki/GetGameType https://wiki.multitheftauto.com/wiki/GetMapName https://wiki.multitheftauto.com/wiki/GetPlayerAccount https://wiki.multitheftauto.com/wiki/GetAccountName local Country = call(getResourceFromName("admin"), "getPlayerCountry", source) طبعاً كلهم سيرفر وعشان تقدر تستخدمها بالكلينت لازم تسوي تريقر أو تستخدم الدتا https://wiki.multitheftauto.com/wiki/TriggerClientEvent https://wiki.multitheftauto.com/wiki/SetElementData https://wiki.multitheftauto.com/wiki/GetElementData
  19. somethings like this maybe local drugtimerrest function timerAnzeigen() -- when I click the OK btn guiSetVisible(Drugs_Window,false) guiSetVisible(Create_Window,true) restminuten = 20 guiSetText(Create_LBL_Timer, tonumber(restminuten).." Minuten") if isTimer(drugtimerrest) then killTimer(drugtimerrest) end drugtimerrest = setTimer(updateTimerZeit,1000,0) end function updateTimerZeit() restminuten = restminuten - 1 if restminuten <= 0 then if isTimer(drugtimerrest) then killTimer(drugtimerrest) end guiSetVisible(Create_Window,false) else guiSetText(Create_LBL_Timer, tonumber(restminuten).." Minuten") end end if you tell us what you trying to make we will be able to help you better
×
×
  • Create New...