Search the Community

Showing results for tags 'help'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • 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
  • Archive
  • Private Bugtracker

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start



About Me





Found 609 results

  1. Hello, I am Scripting a zombie rpg server and as I disabled headshot kills on zombies, I would like to make a damage multiplier system depending on the body part hit when you shoot a zombie. I have been trying to use this script (not mine): local weaponTable = { -- populate this list by adding weapons: -- [weap_id] = { torso, ass, left_arm, right_arm, left_leg, right_leg, head } [24] = { 75, 50, 30, 30, 25, 25, 150 }, } addEventHandler("onPlayerDamage", getRootElement(), function (attacker, weapon, bodypart, loss) if getElementType(attacker) == "player" and getPlayerWeapon(attacker) and weaponTable[ getPlayerWeapon(attacker) ] then setElementHealth(source, getElementHealth(source) - weaponTable[ getPlayerWeapon(attacker) ] [ bodyPart - 2] + loss) end end ) but it didn't work on both players and zombie peds. If someone has a solution for this to work the way I want it would be great (ideally both player and zombie ped multiplier but ped multiplier is more important)
  2. Somehow i can make this possible? When a player connect, then he have to wait the end of download, then he can use the fr gui. I want make fr gui usable when player download the mods. Sorry for my bad english..
  3. Hi guys,im stuck here... I want when i press on GUIEditor.button[1] it sends that i typed in GUIEditor.edit[1] to selected player.. --client GUIEditor = { edit = {}, button = {}, window = {}, label = {}, gridlist = {} } addEventHandler("onClientResourceStart", resourceRoot, function() local screenW, screenH = guiGetScreenSize() GUIEditor.window[1] = guiCreateWindow((screenW - 528) / 2, (screenH - 183) / 2, 528, 183, "dm panel - gat", false) guiWindowSetSizable(GUIEditor.window[1], false) GUIEditor.gridlist[1] = guiCreateGridList(29, 32, 186, 142, false, GUIEditor.window[1]) local column = guiGridListAddColumn(GUIEditor.gridlist[1], "players", 0.9) GUIEditor.button[1] = guiCreateButton(247, 107, 271, 60, "DM", false, GUIEditor.window[1]) guiSetProperty(GUIEditor.button[1], "NormalTextColour", "FFAAAAAA") GUIEditor.edit[1] = guiCreateEdit(247, 32, 269, 65, "", false, GUIEditor.window[1]) GUIEditor.label[1] = guiCreateLabel(216, 63, 31, 15, "close", false, GUIEditor.window[1]) for id, player in pairs(getElementsByType("player")) do local row = guiGridListAddRow ( GUIEditor.gridlist[1]) guiGridListSetItemText ( GUIEditor.gridlist[1], row, column, getPlayerName ( player ), false, false ) guiSetVisible(GUIEditor.window[1], false ) end end ) function show () if guiGetVisible(GUIEditor.window[1] ) then guiSetVisible(GUIEditor.window[1], false ) showCursor (false) else guiSetVisible(GUIEditor.window[1], true ) showCursor (true) end end addCommandHandler("dm", show) function clickin () if source == GUIEditor.label[1] then guiSetVisible(GUIEditor.window[1], false ) showCursor (false) elseif source == GUIEditor.button[1] then if guiGetText(GUIEditor.edit[1] ) == "" then return end --im stoped here, showCursor (false) guiSetVisible(GUIEditor.window[1], false ) end end addEventHandler("onClientGUIClick", root, clickin)
  4. How can players make money by shooting 5 targets?
  5. Revin

    MTA Crashing

    I was trying to play MTA like 3 days ago and im getting the same error in many servers (MTA is crashing) Version = 1.5.5-release-11999.0.000 Time = Wed Jun 6 19:37:34 2018 Module = C:\Program Files\Rockstar Games\GTA San Andreas\gta_sa.exe Code = 0xC0000005 Offset = 0x003C91CC EAX=0ED172C8 EBX=0ED172B8 ECX=0177FAA0 EDX=000A9518 ESI=00000000 EDI=00000001 EBP=0177FC50 ESP=0177FA80 EIP=007C91CC FLG=00010202 CS=001B DS=0023 SS=0023 ES=0023 FS=003B GS=0000 Anyone can help me?
  6. Hello, I need help to complete a slow idle script for the vehicle, but I just could not get a good result, if you can help me, thank you! RX7_sound = { {"001.wav",494}, } function replacesound(player) for i,OBJ in ipairs(RX7_sound) do vehicle = getPedOccupiedVehicle (OBJ[2]) if vehicle then sound = playSound (OBJ[1],looped = true) setSoundVolume(sound, 0.5) setSoundMaxDistance(sound,25) end end end addEventHandler("onClientResourceStart",root,replacesound)
  7. I need help to create this script that replaces objects across a table, thus getting more practical and quick to convert objects Garage_OBJ_DFF = { {"garage_1.dff",1455}, {"garage_2.dff",1455}, } Garage_OBJ_TXD = { {"garage_1.txd",1455}, {"garage_1.txd",1484}, } Garage_OBJ_COL = { {"garage_1.col",1484}, {"garage_2.col",1484}, } function replacemodels(player) for i,object1,object2 in ipairs(Garage_OBJ_DFF) do table.insert(object1[1],object2[2]) object1 = engineLoadDFF object2 = engineReplaceModel end for i,object1,object2 in ipairs(Garage_OBJ_TXD) do table.insert(object1[1],object2[2]) object1 = engineLoadTXD object2 = engineImportTXD end for i,object1,object2 in ipairs(Garage_OBJ_COL) do table.insert(object1[1],object2[2]) object1 = engineLoadCOL object2 = engineReplaceCOL end end addEventHandler("onClientRender",root,replacemodels)
  8. I attached a song to my car, but when i'll go far away from car, the music starts from the beginning... s: how to fix this?
  9. client: function rtwjhrt() if isElement(ss) then stopSound(ss) return end local car = getPedOccupiedVehicle ( localPlayer ) local gettext = guiGetText ( GUIEditor.edit[1] ) local x, y, z = getElementPosition( car ) local ss = playSound3D( 'asd.mp3', x, y, z ) setSoundMaxDistance( ss, 85 ) attachElements(ss,car) end addEvent("asd123asd456",true) addEventHandler("asd123asd456",root,rtwjhrt) server: function trig() triggerClientEvent(root,"asd123asd456",root) end addEvent( "asjdlaj", true ) addEventHandler( "asjdlaj", root, trig ) Why not hear the sound another players?
  10. Estou com o problema não consigo bloquer os trabalhos da agencia estou tentado a bloquear por eu fiz o codigo mais esta dando erro de debug pfvr alguem me ajude local Nível = getElementData (origem "Nível" ou 0) se Nível <5 depois outputChatBox ("teste") return end oq sera esta errado como corrigo Trab_Ambulancia_Veiculo = {} Trab_Ambulancia_Blip = {} Trab_Ambulancia_Marcador = {} Trab_Ambulancia_LastLocal = {} Trab_Ambulancia_LastEntrega = {} Entrega local = { {= 1564,06799, y = 1833,44080, z = 10,75031}, {x = -2723,76416, y = 557,64191, z = 14,55469}, {x = 1988,68262, y = -1432,54785, z = 14,77065}, {x = -315,68024, y = 1063,52026, z = 19,59375}, {x = -1525,02063, y = 2528,02954, z = 55,72723}, {x = -2201,01514, y = -2291.76367, z = 30,62500}, local } = local de trabalho "Motorista de Ambulancia " local TrabalhoFunc =" MotoristadeAmbulancia " local MaxLocal = 6 SalarioMin local, SalarioMax = 1500,4000 function TrabalhoPegar() local Level = getElementData(source "Level" or 0) if Level < 5 then outputChatBox("teste") return end setElementData(source,"Trabalhando",true) outputChatBox("#FFFFFF* #FF0000[Trabalho]#00FF00 "..Trabalho.."", source, 255, 255, 255,true) outputChatBox("#FFFFFF* #FF0000[Trabalho]#00FF00 Transporte o veiculo ate #FF0000BLIP Vermelho Gigante #00FF00 no seu F11", source, 255, 255, 255,true) outputChatBox("#FFFFFF* #FF0000[Trabalho]#FFFFFF para desistir use /abandonar ou saia do veiculo",source,255,255,255,true) if Trab_Ambulancia_LastEntrega[source] == "sucesso" then Trab_Ambulancia_LastLocal[source] = Trab_Ambulancia_LastLocal[source] + 1 else if not Trab_Ambulancia_LastLocal[source] then Trab_Ambulancia_LastLocal[source] = 1 else Trab_Ambulancia_LastLocal[source] = Trab_Ambulancia_LastLocal[source] end end if Trab_Ambulancia_LastLocal[source] > MaxLocal then Trab_Ambulancia_LastLocal[source] = 1 end Trab_Ambulancia_Veiculo[source] = createVehicle(416,-53.86434, -217.51563 ,5.63623) setVehicleRotation (Trab_Ambulancia_Veiculo[source], 0,0,173.8740234375) warpPedIntoVehicle (source,Trab_Ambulancia_Veiculo[source]) setVehicleLocked (Trab_Ambulancia_Veiculo[source], true) local posid = Trab_Ambulancia_LastLocal[source] local x,y,z = Entrega[posid].x, Entrega[posid].y,Entrega[posid].z Trab_Ambulancia_Blip[source] = createBlip (x,y,z, 0, 5, 255, 0, 0,255, 0, 25000,source) Trab_Ambulancia_Marcador[source] = createMarker (x,y,z-1,"cylinder", 10, 0, 200, 55, 255, source) triggerClientEvent (source,"contadortrab",source,x,y,z) addEventHandler ("onMarkerHit",Trab_Ambulancia_Marcador[source], TrabalhoFinalizou) end addEvent("Trab:"..TrabalhoFunc.."", true) addEventHandler("Trab:"..TrabalhoFunc.."", getRootElement(), TrabalhoPegar) function TrabRemoveFunctions(toDestroi) Trab_Ambulancia_LastEntrega[toDestroi] = "cancelado" setElementData(toDestroi,"Trabalhando",false) removeEventHandler ("onMarkerHit",Trab_Ambulancia_Marcador[toDestroi],TrabalhoFinalizou) if Trab_Ambulancia_Veiculo[toDestroi] and isElement ( Trab_Ambulancia_Veiculo[toDestroi] ) then destroyElement( Trab_Ambulancia_Veiculo[toDestroi] ) end if Trab_Ambulancia_Blip[toDestroi] and isElement ( Trab_Ambulancia_Blip[toDestroi] ) then destroyElement( Trab_Ambulancia_Blip[toDestroi] ) end if Trab_Ambulancia_Marcador[toDestroi] and isElement ( Trab_Ambulancia_Marcador[toDestroi] ) then destroyElement( Trab_Ambulancia_Marcador[toDestroi] ) end end function TrabalhoAbandonar (player) if getElementType(player) == "player" then if getElementData(player, "Trabalhando") == true then outputChatBox("#FF0000[Trabalho]#FFFFFF você desistiu do Trabalho de "..Trabalho.."",player,255,255,255,true) TrabRemoveFunctions(player) end end end addCommandHandler("abandonar", TrabalhoAbandonar) function TrabalhoSaiuVeiculo (leaver) if source == Trab_Ambulancia_Veiculo[leaver] and getElementData(leaver, "Trabalhando") == true then TrabRemoveFunctions(leaver) outputChatBox("#FFFFFF* #FF0000[Trabalho]#FFFFFF Você saiu do Veiculo e Desistiu do Trabalho de "..Trabalho.."",leaver,255,255,255,true) else return false end end function TrabalhoSaiuServer () TrabRemoveFunctions(source) if Trab_Ambulancia_Veiculo[source] and isElement ( Trab_Ambulancia_Veiculo[source] ) then destroyElement( Trab_Ambulancia_Veiculo[source] ) end end addEventHandler ("onVehicleExit",getRootElement(), TrabalhoSaiuVeiculo) addEventHandler ( "onPlayerQuit",getRootElement(), TrabalhoSaiuServer) function FunçãoFinalizou (jogador) se getElementType (jogador) == "jogador" então se getElementData (jogador, "Trabalhando") == verdadeiro então TrabRemoveFunctions (jogador) Trab_Ambulancia_LastEntrega [jogador] = "sucesso" dinheiro local = math.random (SalarioMin, SalarioMax) givePlayerMoney (player, tonumber (dinheiro)) setElementData (jogador, "Trabalhando", false) outputChatBox ("# FFFFFF * # FF0000 [Trabalho] #FFFFFF Você completou o Trabalho e Ganhou # FF0000" .. cash .. "$ ", jogador, 255,255,255, verdadeiro) triggerClientEvent (" fimdotrab ", raiz, jogador) end end end outputDebugString ("Trabalho" ..Trabalho .. "Iniciado")
  11. Hi, I need help creating a DX bar that when moved by the mouse it changes the acceleration of the vehicle function bar move () move = dxDrawImage(x*35, y*60, x*230, y*58, "bar.png", 0, 0, 0, tocolor(255, 255, 255, 255), false) setVehicleHandling(v, "engineAcceleration", move ) end
  12. Help, what's wrong with the code? After the death of the player should be 1 hp.
  13. ^iiEcoo'x_)

    Shader !

    Hello Can I use the first picture instead of the second picture in the Shader? Picture : 1 Picture : 2
  14. I want create a dxdraw rectangle and text on the map. But how to make this possible?
  15. Hellow..!! After creating a DX image [ image created using "dxDrawImage" function ], can a GUI Window set font of that DX image ?? And how ?? [ i think "guiSetFont" function is not useful in this occasion. Because I tested it :3 ]
  16. vas1 = createObject ( 3529, -2112.55103, -249.87376, 35.32031, 0, 0, 0 ) function repairClickedVehicle( button, state, player ) if button == "left" and state == "down" then if getElementType( source ) == "object" then destroyElement(vas1) end end end addEventHandler( "onElementClicked", getRootElement( ), repairClickedVehicle ) This working fine... but when i reconnect, the object appear again.. how to fix this?
  17. Why I'm getting kicked for using compiled ahk? I'm playing on RP server. I need to pack it, because i don't want other people steal my code. But each time I login, AC kicking me with it. (VF #4 9KCC) I played with compressed exe before and started to give it away. cause it worked. But after update I'm getting kicked for it. Or what's wrong with script? I could share it, it's just text sender for RP. Any ideas? Waiting for answer...
  18. Hi guys..!! Now I am finding a way, how to create an arrow [ "Down arrow" pickup :- 1318 ] that every-time targeting one position. Like... there is an arrow on player's head and it leads the player to reach a position. So that arrow always target one position. What should i do to set the arrow's target to one position ?? Can you help me ??
  19. Hello there scripters, Im in a secret project of starting officially new and most popular idea In mta me and my friends started this project I dont want to say the name of it but it needs such a proffesional scriptors and 2 staff's which is need to be trusted and not paid at all, but the scriptors will be [aid and we need to discuss how much depends on the scriptors and on the script itself and on us, so imma tell some of what it indicates : - Systems ( alot of kinds ) - Custom gui - And much more Note: the idea will be explained to the scripter and tell him what to script, and this thread will be on until 5/26/2018. After this time done ill contact who posted in this thread, so when you tell me to contact you I WONT until this time done. bye and thanks we need atleast 5 scriptors tho c:
  20. Kostel

    Help me

    Salut! Am si eu o problema , am un server de M.T.A , este unu rp , doresc sa ii creez interioare , am putut face vreo 4-5 interioare , la pretul de 250.000 lei , am bagat in guvern vreo 50.000.000 lei , si acum cand incerc sa creez alt interior la pretul de 250.000 lei , imi zici ca guvernul nu-si permite aceasta propietate . Ma puteti ajuta cu un sfat ceva ? Multumesc frumos.
  21. Hi all, I'm putting together a section of My Account on my server, I want it to be a little window with a tabpanel that has the following tabs: Start (where it shows the basic statistics, name, type of account, level, etc) Configuration (where it will show buttons to change the password, delete the account, etc) Clan/Gang (where it would show data exported from the gangystem) For now I can not think of any other flap, if any one sees a utility to a flap I could also recommend it The problem is this, I am creating this through the freeroam resource GUI (since the My Account button is in the freeroam too, then I wanted to do everything together). The code is the following: wndCuenta = { 'wnd', text = 'LPMV2 - Mi Cuenta', x = 380, y = 190, width = 500, height = 800, controls = { {'tbp', id='tbp1', text='pruebaTabPanel', width=200 , height=200}, }, } The result: It's strange, but I say ... maybe the tab is missing for it to work, so I add it and the code looks like this: wndCuenta = { 'wnd', text = 'LPMV2 - Mi Cuenta', x = 380, y = 190, width = 500, height = 800, controls = { {'tbp', id='tbp1', text='pruebaTabPanel', width=200 , height=200}, {'tab', id='tab1', text='pruebaTab', width=200 , height=200}, }, } But the result is that when I want to open this section (My Account) it shows the last 2 errors in the debugscript (ignore 'callesgroove' resource) Somebody could help me? From already thank you very much!
  22. Resto

    Help please

    Helo all, can anyone tell me what functions i need for /blockpm <name> i used this PM system. local mycrpmpartner = {} function thePM(thePlayer,commandName,sendToName,...) local pmWords = { ... } local pmMessage = table.concat( pmWords, " " ) if sendToName then if getPlayerFromNamePart2(sendToName) then local toPlayer = getPlayerFromNamePart2(sendToName) if not (toPlayer == thePlayer) then --that () needed if not (pmMessage == "") then outputChatBox("#757575[PM] Message to #ff00ff" .. getPlayerName(toPlayer) .. ":#ffffff " .. pmMessage, thePlayer, 255, 255, 255, true) outputChatBox("#FF0000[PM] Message from #ffFFff" .. getPlayerName(thePlayer) .. ":#ffff00 " .. pmMessage, toPlayer, 255, 255, 255, true) mycrpmpartner[thePlayer]=toPlayer mycrpmpartner[toPlayer]=thePlayer else outputChatBox("#FF0000[PM]Use:#ff9900 /pm [part of name] [message]", thePlayer, 255, 255, 255, true) end else outputChatBox("#FF000[PM] You cannot PM yourself #ff9900!", thePlayer, 255, 255, 255, true) end else outputChatBox("#FF0000[PM] Player not found! #FFFF00[#ff9900"..sendToName.."#FFFF00]", thePlayer, 255, 255, 255, true) end else outputChatBox("#FF0000[PM]Use:#ff9900 /pm [part of name] [message]", thePlayer, 255, 255, 255, true) end end addCommandHandler("pm", thePM) function getPlayerFromNamePart2 ( name ) if ( name ) then for _, player in ipairs ( getElementsByType ( "player" ) ) do local name_ = getPlayerName ( player ):gsub ( "#%x%x%x%x%x%x", "" ):lower ( ) if name_:find ( tostring ( name ):lower ( ), 1, true ) then return player end end end end
  23. Hello, I'm wondering change car spawn color to white in freeroam but i'm not have idea of how make this, please anyone helpme. Thx --------------------------- -- Create vehicle window --------------------------- function createSelectedVehicle(leaf) if not leaf then leaf = getSelectedGridListLeaf(wndCreateVehicle, 'vehicles') if not leaf then return end end server.giveMeVehicles( end wndCreateVehicle = { 'wnd', text = 'Create vehicle', width = 300, controls = { { 'lst', id='vehicles', width=280, height=340, columns={ {text='Vehicle', attr='name'} }, rows={xml='vehicles.xml', attrs={'id', 'name'}}, onitemdoubleclick=createSelectedVehicle, DoubleClickSpamProtected=true, }, {'btn', id='create', onclick=createSelectedVehicle, ClickSpamProtected=true}, {'btn', id='close', closeswindow=true} } } function createVehicleCommand(cmd, ...) local args = {...} vehID = getVehicleModelFromName(table.concat(args," ")) or tonumber(args[1]) and math.floor(tonumber(args[1])) or false if vehID and vehID >= 400 and vehID <= 611 then server.giveMeVehicles(vehID) else errMsg("Invalid vehicle model") end end addCommandHandler('createvehicle', createVehicleCommand) addCommandHandler('cv', createVehicleCommand)
  24. Guys,may be who has the code of rotate the camera on one axis, around the car? Very necessary!Please Sorry for my english.
  25. this is my code: function onQuit(thePlayer) for i,v in pairs(getElementsByType("vehicle",resourceRoot)) do if getElementData(v,"oveie") == getPlayerName(thePlayer) then destroyElement(v) end end end addEventHandler ( "onPlayerQuit", root, onQuit ) but this does not working.. why? how to fix it?