Jump to content

Search the Community

Showing results for tags 'mta'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • 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
    • General
    • Multi Theft Auto 0.5r2
    • Third party GTA mods
  • Archive
    • Archived Items
    • Trash

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Member Title


Gang


Location


Occupation


Interests

  1. Argentina Estilo Roleplay un servidor de Rol, somos una comunidad formada por usuarios de cualquier parte del mundo con ganas de divertirse, rolear, y hacer nuevas amistades. Nuestro servidor está basado en Argentina. ╔●▬▬Argentina Estilo Roleplay ▬▬▬▬●╗ ║ Trabajos Temporales-Granjero-Basurero-Correos-Repartidor ║ Mapeos Unicos ║ Vehiculos Reales ║ Rol Serio %100 ║ Facciones con postulaciones abiertas ║ Mafias y bandas ║ Sistema FPS Optimizados. ║ Servidor En Ford cartson ║ Rol 100% Argentino ║ Sistema De Mercado Negro ║ Sistema De Radar ║ facciones ilegales ║ Sistema Anti-Lag ║ Facciones Legales ║ Economía estable ║ Sistema De /curarse ║ Discord: https://discord.gg/MGMVFHRssf
  2. Olá estou com um problema com este resource de Painel de Sirene, o problema é o seguinte eu tenho markers no servidor para criar os veiculos que tenhem esse painel e tambem tem markers para os destruir, porem quando alguem destroi o veiculo com a sirene ou buzina ligada ela fica em loop sem parar ou seja o veiculo é deletado mas ela fica ali tocando Já tentei de todas as formas não consigo arrumar isso alguém pode ajudar? Client-side --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- local sx,sy = guiGetScreenSize() local screenW,screenH = guiGetScreenSize() local resW, resH = 1280, 720 local x, y = (screenW/resW), (screenH/resH) function dxsirenepainelsprp () local theVehicle = getPedOccupiedVehicle ( localPlayer ) if ( theVehicle ) then if getPedOccupiedVehicleSeat(localPlayer) == 1 or getPedOccupiedVehicleSeat(localPlayer) == 0 then if ( getElementModel ( theVehicle ) == 436 ) or ( getElementModel ( theVehicle ) == 490 ) or ( getElementModel ( theVehicle ) == 404 ) then dxDrawRectangle(screenW * 0.5477, screenH * 0.8151, screenW * 0.2350, screenH * 0.1471, tocolor(0, 0, 0, 255), false) dxDrawText("Painel Sirene", screenW * 0.3377, screenH * 0.8151, screenW * 0.9927, screenH * 0.8411, tocolor(255, 140, 0, 255), 1.00, "sans", "center", "center", false, false, false, false, false) if getElementData ( theVehicle, "vtrgiroflex" ) == false then dxDrawRectangle(screenW * 0.5550, screenH * 0.8867, screenW * 0.0637, screenH * 0.0417, tocolor(9, 9, 9, 180), false) else dxDrawRectangle(screenW * 0.5550, screenH * 0.8867, screenW * 0.0637, screenH * 0.0417, tocolor(255, 140, 0, 255), false) end if getElementData ( theVehicle, "vtrsirene" ) == false then dxDrawRectangle(screenW * 0.6319, screenH * 0.8867, screenW * 0.0637, screenH * 0.0417, tocolor(9, 9, 9, 180), false) else dxDrawRectangle(screenW * 0.6319, screenH * 0.8867, screenW * 0.0637, screenH * 0.0417, tocolor(255, 140, 0, 255), false) end if getElementData ( theVehicle, "vtrbuzina" ) == false then dxDrawRectangle(screenW * 0.7117, screenH * 0.8867, screenW * 0.0637, screenH * 0.0417, tocolor(9, 9, 9, 180), false) else dxDrawRectangle(screenW * 0.7117, screenH * 0.8867, screenW * 0.0637, screenH * 0.0417, tocolor(255, 140, 0, 255), false) end dxDrawText("1", screenW * 0.3468, screenH * 0.8672, screenW * 0.8287, screenH * 0.8867, tocolor(255, 140, 0, 255), 1.00, "sans", "center", "center", false, false, false, false, false) dxDrawText("2", screenW * 0.4212, screenH * 0.8672, screenW * 0.9056, screenH * 0.8867, tocolor(255, 140, 0, 255), 1.00, "sans", "center", "center", false, false, false, false, false) dxDrawText("3", screenW * 0.5023, screenH * 0.8672, screenW * 0.9854, screenH * 0.8867, tocolor(255, 140, 0, 255), 1.00, "sans", "center", "center", false, false, false, false, false) dxDrawText("Giroflex", screenW * 0.3500, screenH * 0.8932, screenW * 0.8214, screenH * 0.9206, tocolor(255, 255, 255, 255), 1.00, "sans", "center", "center", false, false, false, false, false) dxDrawText("Sirene", screenW * 0.4322, screenH * 0.8932, screenW * 0.8953, screenH * 0.9206, tocolor(255, 255, 255, 255), 1.00, "sans", "center", "center", false, false, false, false, false) dxDrawText("Buzina", screenW * 0.5103, screenH * 0.8932, screenW * 0.9780, screenH * 0.9206, tocolor(255, 255, 255, 255), 1.00, "sans", "center", "center", false, false, false, false, false) end end end end addEventHandler ( "onClientRender", getRootElement (), dxsirenepainelsprp ) --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- local vehiclesSirenes = {} addEvent("startSireneSound",true) addEventHandler("startSireneSound",root, function() local theVehicle = getPedOccupiedVehicle ( localPlayer ) if ( theVehicle ) then if(vehiclesSirenes[source])then destroyElement(vehiclesSirenes[source]) vehiclesSirenes[source] = nil setElementData(theVehicle, "vtrsirene", false) else setElementData(theVehicle, "vtrsirene", true) vehiclesSirenes[source] = playSound3D( "sirene.mp3", 0,0,0, true ) setSoundMaxDistance(vehiclesSirenes[source], 150 ) setSoundVolume (vehiclesSirenes[source], 0.1) attachElements (vehiclesSirenes[source], source, 0, 0, 0 ) end end end) --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- local vehiclesSirene3 = {} addEvent("startSireneSound3",true) addEventHandler("startSireneSound3",root, function() local theVehicle = getPedOccupiedVehicle ( localPlayer ) if ( theVehicle ) then if(vehiclesSirene3[source])then destroyElement(vehiclesSirene3[source]) vehiclesSirene3[source] = nil setElementData(theVehicle, "vtrbuzina", false) else setElementData(theVehicle, "vtrbuzina", true) vehiclesSirene3[source] = playSound3D( "horn.mp3", 0,0,0, true ) setSoundMaxDistance(vehiclesSirene3[source], 100 ) setSoundVolume (vehiclesSirene3[source], 1.0) attachElements (vehiclesSirene3[source], source, 0, 0, 0 ) end end end) --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- -- Emergency Lights resource by vovo4ka -- please, do not remove copyright -- Edited by #FurkanOzulus [OzulusTR] -- Special Thanks, vovo4ka for the this script :) local strobo_interval = 5 -- strobo light freq. 10 = 0.5 sec local is_strobo_enabled = enable -- enable/disable stroboscopic lights mode -- lamps local flash_interval = 2 -- flash freq -- led blink mode local blink_interval = 20 -- blink interval local blink_duration = 2 -- 1..blink_interval local car_lights_table = { -- Enforcer [427] = {["mode"]="lamp", [1]={["pos"]={0.45, 1.1, 1.42}, ["color"]={255,0,0}, ["size"]=0.2, ["phase"]=10.0}, [2]={["pos"]={-0.45, 1.1, 1.42}, ["color"]={255,0,0}, ["size"]=0.2, ["phase"]=10.0}, [3]={["pos"]={0.22, 1.1, 1.42}, ["color"]={255,0,0}, ["size"]=0.2, ["phase"]=0.0}, [4]={["pos"]={-0.22, 1.1, 1.42}, ["color"]={255,0,0}, ["size"]=0.2, ["phase"]=0.0}, [5]={["pos"]={-1.18, 0.1, 0.94}, ["color"]={255,0,0}, ["size"]=0.1, ["phase"]=0.0}, [6]={["pos"]={-1.18, -1.63, 0.94}, ["color"]={255,0,0}, ["size"]=0.1, ["phase"]=5.0}, [7]={["pos"]={-1.18, -3.37, 0.94}, ["color"]={255,0,0}, ["size"]=0.1, ["phase"]=10.0}, [8]={["pos"]={1.18, 0.1, 0.94}, ["color"]={255,0,0}, ["size"]=0.1, ["phase"]=0.0}, [9]={["pos"]={1.18, -1.63, 0.94}, ["color"]={255,0,0}, ["size"]=0.1, ["phase"]=5.0}, [10]={["pos"]={1.18, -3.37, 0.94}, ["color"]={255,0,0}, ["size"]=0.1, ["phase"]=10.0} }, -- Elegant PassatVtr -- Police Speed [436] = {["mode"]="led", [1]={["pos"]={-0.5,-0.1, 0.8}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, [2]={["pos"]={0.5, -0.1, 0.8}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, [3]={["pos"]={-0.1, 0.1, 0.8}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, [4]={["pos"]={0.1, 0.1, 0.8}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, [5]={["pos"]={-0.6, -0.25, 0.8}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, [6]={["pos"]={0.6, -0.25, 0.8}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, [7]={["pos"]={-0.2,0, 0.8}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, [8]={["pos"]={0.2, 0, 0.8}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, -- [17]={["pos"]={-0.5,-0.1, 0.8}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, [18]={["pos"]={0.5, -0.1, 0.8}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, [19]={["pos"]={-0.1, 0.1, 0.8}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, [199]={["pos"]={0.1, 0.1, 0.8}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, [188]={["pos"]={-0.6, -0.25, 0.8}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, [166]={["pos"]={0.6, -0.25, 0.8}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, [177]={["pos"]={-0.2,0, 0.8}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, [155]={["pos"]={0.2, 0, 0.8}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, --=-=-=-- [40]={["pos"]={-0.77, 2.10, 0.10}, ["color"]={255,0,0}, ["size"]=0.1, ["phase"]=1.0}, [41]={["pos"]={0.77, 2.10, 0.10}, ["color"]={255,0,0}, ["size"]=0.1, ["phase"]=1.0}, [42]={["pos"]={-0.6, 2.26, 0.10}, ["color"]={0,0,255}, ["size"]=0.1, ["phase"]=0.0}, [43]={["pos"]={0.6, 2.26, 0.10}, ["color"]={0,0,255}, ["size"]=0.1, ["phase"]=0.0}, ----frente^ }, -- radio patrulha [404] = {["mode"]="led", [1]={["pos"]={-0.5,-0.1, 1.0}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, [2]={["pos"]={0.5, -0.1, 1.0}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, [3]={["pos"]={-0.1, 0.1, 1.0}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, [4]={["pos"]={0.1, 0.1, 1.0}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, [5]={["pos"]={-0.6, -0.25, 1.0}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, [6]={["pos"]={0.6, -0.25, 1.0}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, [7]={["pos"]={-0.2,0, 1.0}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, [8]={["pos"]={0.2, 0, 1.0}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, -- [17]={["pos"]={-0.5,-0.1, 1.0}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, [18]={["pos"]={0.5, -0.1, 1.0}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, [19]={["pos"]={-0.1, 0.1, 1.0}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, [199]={["pos"]={0.1, 0.1, 1.0}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, [188]={["pos"]={-0.6, -0.25, 1.0}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, [166]={["pos"]={0.6, -0.25, 1.0}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, [177]={["pos"]={-0.2,0, 1.0}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, [155]={["pos"]={0.2, 0, 1.0}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}, --=-=-=-- [40]={["pos"]={-0.77, 2.16, -0.36}, ["color"]={255,0,0}, ["size"]=0.1, ["phase"]=1.0}, [41]={["pos"]={0.77, 2.16, -0.36}, ["color"]={255,0,0}, ["size"]=0.1, ["phase"]=1.0}, [42]={["pos"]={-0.6, 2.36, -0.36}, ["color"]={0,0,255}, ["size"]=0.1, ["phase"]=0.0}, [43]={["pos"]={0.6, 2.36, -0.36}, ["color"]={0,0,255}, ["size"]=0.1, ["phase"]=0.0}, ----frente^ }, --------=========--------- -- FBI Rancher [490] = {["mode"]="lamp", [1]={["pos"]={0, 0.2, 0.9}, ["color"]={255,0,0}, ["size"]=0.4, ["phase"]=5.0}, [2]={["pos"]={0.4, 0, 0.9}, ["color"]={255,0,0}, ["size"]=0.4, ["phase"]=0.0}, [3]={["pos"]={-0.4, 0, 0.9}, ["color"]={255,0,0}, ["size"]=0.4, ["phase"]=15.0}, [4]={["pos"]={0.55, -0.2, 0.9}, ["color"]={255,0,0}, ["size"]=0.4, ["phase"]=7.0}, [5]={["pos"]={-0.55, -0.2, 0.9}, ["color"]={255,0,0}, ["size"]=0.4, ["phase"]=20.0} }, -- since 0.8 there are no default lights position, because only emergency and pre-defined vehicles can use lights --["default"] = {["mode"]="lamp", [1]={["pos"]={0.5, 0, 0.8}, ["color"]={255,0,0}, ["size"]=0.25, ["phase"]=0.0}, [2]={["pos"]={-0.5, 0, 0.8}, ["color"]={0,0,255}, ["size"]=0.25, ["phase"]=10.0}} } -- do not modify -------------------------------------------- local vehicles = {} local timers = {} local base_freq = 50 -- freq of timer for light change ------------------------------------------------------------- function release_vehicle(vehicle) if (isElement(vehicle)) then if (is_strobo_enabled) then setVehicleOverrideLights ( vehicle, 0) setVehicleLightState ( vehicle, 0, 1 ) setVehicleLightState ( vehicle, 1, 1 ) setVehicleLightState ( vehicle, 2, 1 ) setVehicleLightState ( vehicle, 3, 1 ) end end if (vehicles[vehicle]~=nil) then -- release the markers for key, value in pairs(vehicles[vehicle]["flist"]) do destroyElement (value["m"]) end setElementData(vehicle, "vtrgiroflex", false) vehicles[vehicle] = nil end if (timers[vehicle]~=nil) then -- kill the strobo timer killTimer(timers[vehicle]) timers[vehicle] = nil if (isElement(vehicle)) then if (getElementData( vehicle, "emerlights_source")==getPlayerName(getLocalPlayer())) then triggerEvent ( "onPlayerEmergencyLightStateChange", getRootElement(), 0 ) end end end end function checkForAbility(vehicle) local veh_model = getElementModel ( vehicle ) if (car_lights_table[veh_model]==nil)or(getElementData( vehicle, "emerlights_enabled" )=="false") then return false end return true end function strobo_state_update (vehicle) -- check for valid vehicle if (isElement(vehicle)) then if (vehicles[vehicle]==nil) then -- check for disallowing to use lights -- its enabled by default if (checkForAbility(vehicle)==false) then release_vehicle(vehicle) return end local veh_model = getElementModel ( vehicle ) --if (car_lights_table[veh_model]==nil) then --veh_model = "default" --end setElementData( vehicle, "emerlights_source", src, false) if (src==getPlayerName(getLocalPlayer())) then triggerEvent ( "onPlayerEmergencyLightStateChange", getRootElement(), 1 ) end -- init state variable vehicles[vehicle] = {} vehicles[vehicle]["lstate"] = 0 -- strobo lights state vehicles[vehicle]["fstate"] = 0 -- flash light state vehicles[vehicle]["flist"] = {} -- flash lights list (marker ids) -- create flash lights local mode = car_lights_table[veh_model]["mode"] if (mode==nil) then mode = "lamp" end local coeff = 0 if (mode=="lamp") then coeff = 3.141592654/10.0 else coeff = blink_interval/20.0 end vehicles[vehicle]["fmode"] = mode for light_id, light_desc in pairs(car_lights_table[veh_model]) do if (light_id~="mode") then vehicles[vehicle]["flist"][light_id] = {} vehicles[vehicle]["flist"][light_id]["m"] = createMarker( 0.0001, 0.0001, 0.0001, "corona", light_desc["size"], light_desc["color"][1], light_desc["color"][2], light_desc["color"][3], 100) vehicles[vehicle]["flist"][light_id]["p"] = light_desc["phase"]*coeff attachElements ( vehicles[vehicle]["flist"][light_id]["m"], vehicle, light_desc["pos"][1], light_desc["pos"][2], light_desc["pos"][3] ) end end end -- strobo light if (is_strobo_enabled) then setVehicleOverrideLights ( vehicle, 2) if (vehicles[vehicle]["lstate"]<strobo_interval) then setVehicleLightState ( vehicle, 0, 1 ) setVehicleLightState ( vehicle, 1, 0 ) setVehicleLightState ( vehicle, 2, 0 ) setVehicleLightState ( vehicle, 3, 1 ) else setVehicleLightState ( vehicle, 0, 0 ) setVehicleLightState ( vehicle, 1, 1 ) setVehicleLightState ( vehicle, 2, 1 ) setVehicleLightState ( vehicle, 3, 0 ) end if (vehicles[vehicle]["lstate"]>=strobo_interval*2) then vehicles[vehicle]["lstate"] = 0 else vehicles[vehicle]["lstate"] = vehicles[vehicle]["lstate"] + 1 end end -- flash light if (vehicles[vehicle]["fmode"]=="lamp") then -- lamp mode local tmp_fstate = vehicles[vehicle]["fstate"] for key, value in pairs(vehicles[vehicle]["flist"]) do local R, G, B, A = getMarkerColor( value["m"] ) setMarkerColor(value["m"], R, G, B, (math.sin(tmp_fstate+value["p"])+1.0)*128.0) end vehicles[vehicle]["fstate"] = vehicles[vehicle]["fstate"] + flash_interval else -- led mode local tmp_fstate = vehicles[vehicle]["fstate"] for key, value in pairs(vehicles[vehicle]["flist"]) do local R, G, B, A = getMarkerColor(value["m"]) -- blinking mode local tmp_val = tmp_fstate+value["p"] if (tmp_val>blink_interval) then tmp_val = tmp_val - blink_interval end if ((tmp_val>=0)and(tmp_val<blink_duration))or((tmp_val>=blink_duration+1)and(tmp_val<blink_duration*2+1)) then setMarkerColor(value["m"], R, G, B, 255) else setMarkerColor(value["m"], R, G, B, 0) end end vehicles[vehicle]["fstate"] = vehicles[vehicle]["fstate"] + 1 if (vehicles[vehicle]["fstate"]>blink_interval) then vehicles[vehicle]["fstate"] = vehicles[vehicle]["fstate"] - blink_interval end end else -- if vehicle is no more exists release_vehicle(vehicle) end end function isStroboLightsOn (vehicle_id) if (timers[vehicle_id]) then return 1 else return 0 end end function setStroboLightsOn(vehicle_id, value) if ( vehicle_id ) then if (value==nil) then if (isStroboLightsOn(vehicle_id)==1) then value = 0 else value = 1 end; end; if (value==0) then if (timers[vehicle_id]) then release_vehicle(vehicle_id) end end if (value==1) then if (timers[vehicle_id]) then release_vehicle(vehicle_id) end -- create strobo timer timers[vehicle_id] = setTimer ( strobo_state_update, base_freq, 0, vehicle_id ) end end end -- only local effect function enableStroboLightsMode(source, value) if (value=="0")or(value=="false") then is_strobo_enabled = false --outputConsole("Stroboscopic mode disabled") else if (value=="1")or(value=="true") then is_strobo_enabled = true --outputChatBox("Stroboscopic mode enabled") else --outputChatBox("Usage: strobo 0 or strobo 1 for disable/enable stroboscopic lights mode") end end end addCommandHandler("strobo", enableStroboLightsMode) -- triggered by server function setEmerlightsState(value, state) local player = getPlayerFromName ( value ) local vehicle = getPedOccupiedVehicle(player) if (vehicle) then setStroboLightsOn(vehicle, state) end end addEvent("setEmerlights", true) addEventHandler("setEmerlights", getRootElement(), setEmerlightsState) function requestEmerlights() -- check for driver playerVehicle = getPedOccupiedVehicle (getLocalPlayer()) -- get the player's vehicle if (playerVehicle) then -- if player is not a driver if getPedOccupiedVehicleSeat(localPlayer) == 1 or getPedOccupiedVehicleSeat(localPlayer) == 0 then -- sync setElementData(playerVehicle, "vtrgiroflex", true) triggerServerEvent("requestEmerlightChangeState", getLocalPlayer(), 1-isStroboLightsOn(getPedOccupiedVehicle(getLocalPlayer()))) else -- not able to use lights for this vehicle --outputChatBox("unknown car!") end end end addCommandHandler("Strobo Light On", requestEmerlights)--stroboLightOn) bindKey("1", "down", "Strobo Light On") addEvent("onPlayerEmergencyLightStateChange") Server-Side --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- local viaturas = { [436]=true,[490]=true,[404]=true } function Sirene1(player,thePlayer,seat) local vehicle = getPedOccupiedVehicle(player) if(vehicle and viaturas[getElementModel(vehicle)])then if getPedOccupiedVehicleSeat(player) == 1 or getPedOccupiedVehicleSeat(player) == 0 then triggerClientEvent("startSireneSound",vehicle) setElementData(vehicle, "SireneTocando1", true) end end end function onResStart1() for index, player in ipairs(getElementsByType("player")) do bindKey(player, "2", "down", Sirene1) end end addEventHandler("onResourceStart", getResourceRootElement(getThisResource()), onResStart1) function onPlayerJoin1() bindKey(source, "2", "down", Sirene1) end addEventHandler("onPlayerJoin", getRootElement(), onPlayerJoin1) function cleanAll1(player) for index, player in ipairs(getElementsByType("player")) do unbindKey(player, "2", "down", Sirene1) end end addEventHandler("onResourceStop", getResourceRootElement(getThisResource()), cleanAll1) --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- local viaturas3 = { [436]=true,[490]=true,[404]=true } function Sireneamb2(player,seat) local vehicle = getPedOccupiedVehicle(player) if(vehicle and viaturas3[getElementModel(vehicle)])then if getPedOccupiedVehicleSeat(player) == 1 or getPedOccupiedVehicleSeat(player) == 0 then triggerClientEvent("startSireneSound3",vehicle) setElementData(vehicle, "SireneTocando2", true) end end end function onResStart3() for index, player in ipairs(getElementsByType("player")) do bindKey(player, "3", "both", Sireneamb2) end end addEventHandler("onResourceStart", getResourceRootElement(getThisResource()), onResStart3) function onPlayerJoin3() bindKey(source, "3", "both", Sireneamb2) end addEventHandler("onPlayerJoin", getRootElement(), onPlayerJoin3) function cleanAll3(player) for index, player in ipairs(getElementsByType("player")) do unbindKey(player, "3", "both", Sireneamb2) end end addEventHandler("onResourceStop", getResourceRootElement(getThisResource()), cleanAll3) addEventHandler("onElementDestroy", getResourceRootElement(getThisResource()), function () local viaturas3 = { [436]=true,[490]=true,[404]=true } local vehicle = getPedOccupiedVehicle(player) if(vehicle and viaturas3[getElementModel(vehicle)])then for index, player in ipairs(getElementsByType("player")) do unbindKey(player, "3", "both", Sireneamb2) unbindKey(player, "2", "down", Sirene1) if (getElementData(vehicle, "SireneTocando1") == true) then setElementData(vehicle, "SireneTocando1", false) triggerClientEvent("startSireneSound",vehicle) end if (getElementData(vehicle, "SireneTocando2") == true) then setElementData(vehicle, "SireneTocando2", false) triggerClientEvent("startSireneSound3",vehicle) end end end end) --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- function onPlayerRequestEmerlight(value) triggerClientEvent(getRootElement(), "setEmerlights", getRootElement(), getPlayerName(source), value) end addEvent("requestEmerlightChangeState", true) addEventHandler("requestEmerlightChangeState", getRootElement(), onPlayerRequestEmerlight) --> Furkan Özulus <--
  3. Queria saber como faz para bloquear uma bind em um setTimer
  4. What is GizmoPack? it is a modular package of objects that extends the mapping capabilities of the MTA. Update List: List of films from updates and presentations: Download link: GizmoPack Latest version Authors: THEGizmo (Modeler, the main originator) i XeN (help with the project, editor of the texture editor)
  5. Danispace

    SD #4 RKE8

    So recently i reinstalled my PC, I had windows 11 before and still, except for now MTA is not working. I have no idea what could be modifying the process of mta, since i have nothing different other than what i had before, i have razer synapse etc... I tried reinstalling MTA on both my SSDs, reinstalled GTA:SA but nothing seems to work. I join local host and get kicked SD #4 RKE8, and on different servers too. FADD74F89263F9BEE73931EDAFB178A1 Multi Theft Auto v1.5.9-release-21334
  6. Queria remover isso do chat quando entra no servidor, para o chat ficar clean
  7. I found this video today from my mediafire account, I remember I joined this server between 2010 and 2012 (may not be exact), then the server closed down and I switched to DDC and finally stop at FFS Does anyone know the people named in this video, how are they now and are they still playing MTA From a player SEA with 350 ping :))
  8. Lately some injectable hacks for mta are appearing, coming from some Russians this is really possible apparently, if so is there any way to protect servers against this, or the mta itself may have a possible way to solve this?
  9. BoOoStEd

    Low FPS

    Hi! I'm having problems playing on RP servers. My laptop should handle MTA just fine, but I only get ~30 (Sometimes dropping to 10-20 while driving) and in interior ~40 FPS. What could be the problem? Laptop specs: I7-10870H on 4.5Ghz turbo GTX 1660 TI 24GB DDR4 ram MTA on NVMe SSD 1 Gbps network (I don't know if it matters, maybe in loading textures) Tried reinstalling the game, reinstalling MTA, installing older DirectX, changing settings, etc..
  10. В общем суть проблемы в следующем: Машины в гараже не перекрашиваются,стикеры не клеятся. Пробовал разные модели, нечего не помогает в консоли ошибок не каких нету. Вернее все красится покупается в том числе и стикеры но они не отображаются по неизвестной причине! гитхаб https://github.com/StrixG/driftparadise-legacy/tree/races-and-houses Может кто знает помогите!
  11. Hello friends, today I will share with you a very simple and under development hud. To get rid of FPS and screen pollution, it is enough to install and run the hud I made on your server. Download > Link
  12. Hi, I set up an mta server on a virtual server, but all players ping over 100. I pinged my virtual server using the speed test site and the result was 11. And I also tested my own ping and got ping 8 What should I do, the firewall and antivirus server are also turned on. Virtual server information 16 GB RAM 4 CORE
  13. SELLING - Rust gamemode +mysql Hello, i'm selling Rust Gamemode. We started to work at this project 2 years ago, we had 50+ online players without any problems. Gamemode is one of the best from MTA, we have a lot of systems and the code is write with a lot of care, without any bugs or problems. The gamemode is perfect for open a server, if have good promotion can make 100+ online players very easy. WHAT SYSTEMS DOES IT HAS? Building system (Same like in Original Rust) Crafting system (Same like in Original Rust) Custom Map (Have radiation zones and more) Inventory system (Same like in Original Rust) Full MySQL database Bed system (Same like in Original Rust) Grup system Furnace system Chest system Recycle system Animals(Deers, Boar) Vehicles Airdrop (people can call it with Supply Drop item) Oil Rig (can use Red Card item to open door and take good loot) Cargo Ship (Every 1 hour cargo will spawn on the sea, you can take loot from this) Vip System Admin System Custom Account System (Including 2 databases and auto-login, auto-register) Custom Weapons (Same like in Original Rust) Custom crosshairs Custom weapon properties, including recoil and more Base upgrade (Tier 1 - Wood, Tier 2 - Stone, Tier 3 - Iron) Raiding System (Flame Thrower just for wooden bases, C4, Rocket) If you want to buy contact me here via messages .......................... If you have questions xMaKaKa#6581 Buy Here removed by staff SCREENSHOTS AND VIDEOS https://youtu.be/Am5z3_8iekc https://youtu.be/WE2jHu0tMQA https://youtu.be/vGhsbwRDsOI
  14. Estou tentando por o addcommandhandler mas não consigo de forma nenhuma, se alguém tiver a solução para algum dos 3 scripts a baixo me avisa fznd o favor estou tentando abrir painel DX por comando ao em vez de por bindkey porem não consigo, já tentei de vários jeitos e formas porem nn vai, já pesquisei aqui no fórum, no YouTube porem nn vai function Pdx ( ) dxDrawRectangle(504, 197, 314, 397, tocolor(255, 0, 0, 100), false) dxDrawRectangle(554, 238, 218, 72, tocolor(255, 255, 255, 255), false) dxDrawRectangle(554, 347, 218, 72, tocolor(255, 255, 255, 255), false) dxDrawRectangle(554, 455, 218, 72, tocolor(255, 255, 255, 255), false) end function abrir (_,state) if painel == false then showCursor(true) addEventHandler("onClientRender", root, Pdx) painel = true else showCursor(false) removeEventHandler("onClientRender", root, Pdx) painel = false end end addCommandHandler("disappear", abrir) addCommandHandler("v", abrir) tabem tentei fazer uma versão para uma bussola: --2017 ~ Mark Gyori https://markgyori.eu/ --Contact: [email protected] local sx, sy = guiGetScreenSize() local top = 30 local font1 = dxCreateFont("font.otf", 11) local font2 = dxCreateFont("font.otf", 10) local exibir_bulssola = false local cords = { {0, "N"}, {15, 15}, {30, 30}, {45, "NE"}, {60, 60}, {75, 75}, {90, "E"}, {105, 105}, {120, 120}, {135, "SE"}, {150, 150}, {165, 165}, {170, "S"}, {195, 195}, {210, 210}, {225, "SW"}, {240, 240}, {255, 255}, {270, "W"}, {285, 285}, {300, 300}, {315, "NW"}, {330, 330}, {345, 345} } function draw ( ) local show = 15 local center = math.ceil(show / 2) - 1 local _, _, r = getElementRotation(getCamera()) local pos = math.floor(r / 15) local slotwidth = 40 local smooth = ((r - (pos * 15)) / 15) * slotwidth local left = sx / 2 - ((show + 2) * slotwidth)/2 for i=1, show do local id = i + pos - center if(id > #cords)then id = id - #cords end if(id <= 0)then id = #cords - math.abs(id) end if(cords[id])then local alpha = (tonumber(cords[id][2]) or 0 > 0) and 175 or 255 if(i < center)then alpha = alpha * (i/center) end if(i > center)then alpha = alpha * ((show-i)/center) end dxDrawRectangle(left + slotwidth * i - smooth + (slotwidth / 2 - 1) + 1, top + 10 + 1, 2, 10, tocolor(0, 0, 0, alpha * 0.5)) dxDrawRectangle(left + slotwidth * i - smooth + (slotwidth / 2 - 1), top + 10, 2, 10, tocolor(255, 255, 255, alpha)) dxDrawText(cords[id][2], left + slotwidth * i - smooth + 1, top + 20, left + slotwidth * (i+1) - smooth + 2, top + 40, tocolor(0, 0, 0, alpha * 0.5), 1, font2, "center", "center") dxDrawText(cords[id][2], left + slotwidth * i - smooth, top + 20, left + slotwidth * (i+1) - smooth, top + 40, tocolor(255, 255, 255, alpha), 1, font2, "center", "center") end end dxDrawText("➤", left + 4, top + 26 + 2, left + ((show + 3) * slotwidth) + 30, 0, tocolor(0, 0, 0, 160), 1, font1, "center", "top", false, false, false, false, false, 90) dxDrawText("➤", left, top + 26, left + ((show + 3) * slotwidth) + 30, 0, tocolor(255, 255, 255, 255), 1, font1, "center", "top", false, false, false, false, false, 90) end addCommandHandler("m1", function() if exibir_bulssola = false then addEventHandler("onClientRender", getRootElement(), draw) exibir_bulssola = true else removeEventHandler("onClientRender", getRootElement(), draw) exibir_bulssola = false end end) --->--->--->---> (inclusive tentei mudar a direção a qual ele gira não consegui se alguém souber como avisa)<---<---<---<--- e também tentei para ativar e desativar primeira pessoa na arma através de comando: function zoomarma (thePlayer) setWeaponProperty ( 30 , "poor" , "flag_aim_1st_person" , true ) setWeaponProperty ( 30 , "std" , "flag_aim_1st_person" , true ) setWeaponProperty ( 30 , "pro" , "flag_aim_1st_person" , true ) end addCommandHandeler ("m1", zoomarma ) esse addCommandHandeler não funciona de jeito nenhum
  15. İP: mtasa://213.238.166.21:22003 GoodFellas Roleplay Kaliteli MTA:SA Roleplay Sunucusu Türk/Medium/Global/Sesli Discord Adresi:https://discord.gg/G3shD4ksMC
  16. ┏━━━━━━━•°•☆•°•━━━━━━━┓ ????T?? ???????? ┗━━━━━━━•°•☆•°•━━━━━━━┛ ➤ 「 Sistema de Tunagem 」 ➤ 「 Customizar Personagem 」 ➤ 「 Mobiliar Propriedade 」 ➤ 「 Vagas para Staff 」 ➤ 「 Sistema de Drogas 」 ➤ 「 Desmanche de Veículos 」 ➤ 「 Eventos 」 ➤ 「 Caixa Eletrônico pela cidade 」 ➤ 「 Favela para Conquistar 」 ➤ 「 3 Vips 」 ➤ 「 E muito mais 」 ???????: https://discord.gg/Qda69QA4up T??????: https://youtu.be/itGpznafmGM ⫸ MTASA://192.99.138.63:22009 ⫷
  17. Alguem sabe como eu tiro esse erro de CC23, quando tento entra em um servidor da esse erro ja tentei instalar tudo novamente mais continua o mesmo erro alguem pode ajudar ? LINK DO ERRO [CC23]: https://prnt.sc/ixtb2u
  18. meu mta esta com um erro (cd20) na hora de baixar os mods de algum servidor
  19. Hello my friends I want the player near the car to use the CMD when the car breaks down(exploded) and the car to be repaired( respawnVehicle() ) Please help me in this matter?
  20. Galera to fazendo um sistema de painel q vc digita no painel tipo 255, 0, 0 dentro de um carro e seta a cor vermelha no carro q e do rgb 255, 0, 0 e etc. mas da forma que achei que era possivel ao abrir o painel e digitar a cor em rgb eu fiz uma função que na teoria era pra pegar oq foi digitado na editbox e setar oq foi digitado na editbox como cor do carro usando setVehicleColor so q n aparece nada e n seta cor no carro mais se o carro ta vermelho e coloca tipo 255, 0, 0 na editbox e da ok a cor sempre muda pra preto espero q de para entender function SetarCor (playerSource, getMsg) --local mensagem = tonumber(getMsg) local uVehicle = getPedOccupiedVehicle( playerSource ) if isPedInVehicle( playerSource ) then if uVehicle then -- if mensagem == "Vermelho" then setVehicleColor( uVehicle, tonumber(getMsg)) end end --end end addEvent("SetarCor", true) addEventHandler("SetarCor", getRootElement(), SetarCor) PARTE DO CLIENT function rgbtrigger (button, state) if painel == true then if button == "left" and state == "down" then if isCursorOnElement(screenW * 0.6384, screenH * 0.5885, screenW * 0.7379, screenH * 0.6185) then local getMsg = tostring(getElementData(msgstaff, "CMT_Txt")) removeEventHandler("onClientRender", root, dx) triggerServerEvent("SetarCor", getLocalPlayer(), localPlayer, getMsg) painel = false showCursor(false) end end end end addEventHandler("onClientClick", root, rgbtrigger)
  21. Olá pessoal estou com outro problema diferente agora, basicamente tou com um mod de trancar veiculos aqui porem ele veio com o som de trancar veiculo muito feio, consegui trocar o som quando o player tranca o veiculo sem estar nele porem tou tendo dificuldades para conseguir colocar um som diferente se o player estiver dentro do veiculo server side function doToggleLights ( source, beep ) local theVehicle if ( getElementType(source) == "vehicle" ) then theVehicle = source end if ( getElementType(source) == "player" ) then theVehicle = getElementData ( source, "cl_ownedvehicle" ) end if ( theVehicle ) then if (getElementType(source) == "player") then if not (getPedOccupiedVehicle(source)) then if ( getVehicleOverrideLights ( theVehicle ) ~= 2 ) then -- if the current state isn't 'force on' setVehicleOverrideLights ( theVehicle, 2 ) -- force the lights on -- play sound close to element if ( beep == true ) then local theElement = theVehicle triggerClientEvent ( getRootElement(), "playSoundLockOut", getRootElement(), theElement, 5) end else setVehicleOverrideLights ( theVehicle, 1 ) -- otherwise, force the lights off end else if ( beep == true ) then local theElement = theVehicle triggerClientEvent ( getRootElement(), "playSoundLockIn", getRootElement(), theElement, 5) end end end else end end Obrigado a quem puder ajudar Principalmente ao @Lord Henryque tem me ajudado bastante aqui!
  22. Olá Tenho um sistema de seta mas ta encriptado porem preciso do element data dele para adicionar no velocimetro o desenvolvedor foi o tommy scripter acho se alguem souber os element data das setas agradecia ou outro mod de dar seta
  23. Olá preciso de ajuda com esse codigo basicamente quero que se o player estiver dentro do carro nao abra as portas esse é um codigo de portao por acl que é feito atraves de um marker porem ja tentei muita coisa para nao funcionar se o player estiver dentro de um veiculo tentei ispedinvehicle nao foi , nao sei se alguem poder ajudar agradecia so tem server side Gate10 = createObject ( 1569, 954.40002441406, -1721.9000244141, 12.60000038147, 0, 0, 270 ) Gate11 = createObject ( 1569, 954.40002441406, -1724.9000244141, 12.60000038147, 0, 0, 90 ) local markerlojacarros = createMarker(954.40002441406, -1723.6000244141, 12.60000038147, "cylinder", 3, 0, 0, 0, 0) function PortaoDoor1Loja(thePlayer) moveObject (Gate10, 200, 954.40002441406, -1720.6999511719, 12.60000038147 ) moveObject (Gate11, 200, 954.40002441406, -1726.0999755859, 12.60000038147 ) end addCommandHandler("open",PortaoDoor1Loja) addEventHandler("onMarkerHit", markerlojacarros, PortaoDoor1Loja) function PortaoDoor2Loja() moveObject (Gate10, 200, 954.40002441406, -1721.9000244141, 12.60000038147 ) moveObject (Gate11, 200, 954.40002441406, -1724.9000244141, 12.60000038147 ) end addCommandHandler("close",PortaoDoor2Loja) addEventHandler("onMarkerLeave", markerlojacarros, PortaoDoor2Loja)
  24. Friday the 13th: MTA Edition is a brand new horror server on MTA inspired by Friday The 13th: The Game and Dead by Daylight. The main objective is survive until dawn or escape from the camp crystal lake by car/boat/calling the cops. Unlock new characters with unique abilities, perks and much more! Watch the first teaser of the server:
  25. Hey Fellas! I'm looking for this guy, but in other clothes, if someone have it, i would be thankful: https://imgur.com/a/FleR5f2
×
×
  • Create New...