Jump to content

Search the Community

Showing results for tags 'gtasa'.

  • 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

Found 18 results

  1. 《 Polski Serwer Służb Mundurowych 》 Cześć Graczu! Szukasz fajnego serwera MTA na którym chciałbyś pograć wspólnie ze znajomymi, i mile spędzić czas? Bardzo dobrze trafiłeś ! Przedstawiamy wam serwer "PSSM" jest to serwer RPG/RP! ——————————————— ????????? » Pomocną i doświadczoną administrację » Ciekawe Prace » Małe Zarobki » Eventy jakich jeszcze nie widziałeś » Bardzo dobrze rozbudowaną gospodarkę » Darmowe Premium » Podmianki » Zaawansowane systemy ——————————————— ?????????? » To jeszcze nie wszystko znajdziesz u nas na serwerze ! » Pozdrawia cała ekipa serwera Zaproszenie: https://discord.gg/uT4fQwkbsh
  2. Hello! Today GTA:SA turns 18 years old! The game was originally released on 26th Oct. 2004, so HBD! I believe I have discovered something completely new, at least I couldn't find any videos or discussions about this. No mods or cheats are required to reproduce this. What's this video about? (SPOILERS):
  3. 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 <--
  4. 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
  5. 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
  6. español Hola, inicie un seridor con un amigo y tenemos un problema con los markets, cuando un jugador entra a uno se le aparece el cartel a todos los demas jugadores (Por ejemplo: Un jugador entra al market del job de pizzero a todos los demas jugadores les salta el cartel para tomar el trabajo esten donde esten). Seria genial si alguien nos ayudase ya que si no lo solucionamos nos vamos a ver obligados a cerrar el servidor y no queremos eso, desde ya muchas gracias aqui dejo mi discord: Fede#7027 português Olá, comece um seridor com um amigo e temos um problema com os mercados. Quando um jogador entra em um, o pôster aparece para todos os outros jogadores (por exemplo: Um jogador entra no mercado de pizza para todos os outros jogadores. pule o pôster para aceitar o trabalho onde quer que esteja). Seria ótimo se alguém nos ajudasse, porque se não resolvermos, seremos forçados a fechar o servidor e não queremos isso, muito obrigado aqui deixo minha discórdia: Fede # 7027 english Hello, start a serer with a friend and we have a problem with the markets, when a player enters one, the poster appears to all the other players (For example: A player enters the pizza job market to all the other players skip the poster to take the job wherever they are). It would be great if someone helped us because if we do not solve it we will be forced to close the server and we do not want that, thank you very much here I leave my discord: Fede # 7027
  7. Kanala abone olup beğenirseniz çok mutlu olurum I'll be happy if you like it and subscribe
  8. Serwer Country jest serwerem RPG z elementami RP. Cały skrypt jest autorski i zoptymalizowany. Nie bazujemy na żadnym gamemodzie. Ekipa składa się z trzech osób - dwóch developerów i administratora. Rozgrywka toczy się w Fort Carson oraz w okolicznych wioskach, gdzie jest dobrze rozwinięta infrastruktura. Dzięki rozwijającemu się miastu Los Santos możemy stać się stróżem prawa, biznesmenem czy członkiem gangu. Wkrótce zostanie wdrążony system biznesów. Los Santos to także miasto służb mundurowych, do których zalicza się: - Los Santos Police Departament, - Los Santos Fire Dept, - Los Santos Medical Center. Przedstawiamy kilka zdjęć prezentujących nasz serwer: - panel logowania: - interakcja pojazdów: - prawo jazdy: - scoreboard: - system 911: - system dokumentów LSPD: - praca dorywcza kierowca betoniarki: Jeszcze kilka rzeczy mamy do zrobienia, ale start serwera planujemy na 31 stycznia 2020r (piątek) godzinę otwarcia podamy bliżej startu. W takim razie zapraszamy na nasze tymczasowe forum, aby być na bieżąco z serwerem. Przewidujemy beta testy przed startem serwera, dlatego chętnych zachęcamy do złożenia podania gdy otworzymy rekrutację. IP serwera: 178.33.54.14:20476 Przewidywany start: 31 styczeń 2020r. Tymczasowe forum: http://www.country-rpg.4ra.pl/forums.php Nasz fanpage: https://www.facebook.com/Country-MTA-545461992488059/
  9. Estou com um problema, é o seguinte: Estou usando o setElementData, ele funciona perfeitamente para estocar o valor determinado. Porém quando o "source", o player sai do server como por exemplo dá "reconnect" esse valor estocado não fica salvo. Alguém tem ideia de como consigo fazer para salvar ? Desde já agradeço!
  10. local vehicleElements = {} allVeh = {510} local pickupTable = { {1086.1798095703,-1801.6898193359,13.601690292358}, } function createPickupOnServerStart () for i, cor in ipairs (pickupTable) do local pickup = createPickup(cor[1], cor[2], cor[3], 3, 1274, 0) setElementData(pickup, "pickupArenda", true) end end addEventHandler("onResourceStart", getResourceRootElement( getThisResource() ), createPickupOnServerStart) function onResourceStop (veh) if isTimer(vehicleElements[veh]) then killTimer(vehicleElements[veh]) end --vehicleElements[veh] = destroyElement(veh) end addEventHandler("onResourceStop", getResourceRootElement( getThisResource() ), onResourceStop) function onPickupHit (hit) if not getElementData(source, "pickupArenda") or getElementType(hit) ~= "player" and not isPedInVehicle(hit) then return end triggerClientEvent(hit, "changeArendaMenuState", hit) end addEventHandler("onPickupHit", getRootElement(), onPickupHit) function onPlayerUseCustomPickup() if getPlayerMoney(source) >= 500 then local x, y, z = getElementPosition(source) local veh = createVehicle(allVeh[math.random(1,#allVeh)], x, y, z) setElementData(veh, "starter_pack", true) setElementData(veh, "owner", source) warpPedIntoVehicle(source, veh) takePlayerMoney(source, 500) outputChatBox("Bicicleta alugada, bom uso!.", source, 0, 255, 0) else outputChatBox("Para alugar uma bicicleta você precisa de >> 500 $$ <<.", source, 255, 0, 0) end end addEvent("onPlayerUseCustomPickup", true) addEventHandler("onPlayerUseCustomPickup", getRootElement(), onPlayerUseCustomPickup) function onPlayerVehicleEnter (veh, seat) if getElementData(veh, "starter_pack") == true and seat == 0 then if isTimer(vehicleElements[veh]) then killTimer(vehicleElements[veh]) end end end addEventHandler("onPlayerVehicleEnter", getRootElement(), onPlayerVehicleEnter) function onPlayerVehicleExit (veh, seat) if getElementData(veh, "starter_pack") == true and seat == 0 then if isTimer(vehicleElements[veh]) then killTimer(vehicleElements[veh]) end vehicleElements[veh] = setTimer(destroyElement, 300000, 1, veh) end end addEventHandler("onPlayerVehicleExit", getRootElement(), onPlayerVehicleExit) function onVehicleStartEnter (player, seat) if getElementData(source, "starter_pack") == true and seat == 0 then local owner = getElementData(source, "owner") if owner ~= player then cancelEvent() outputChatBox("Você não é dono desta bicicleta, alugue sua bike para poder usá-la.", player, 255, 0, 0) end end end addEventHandler("onVehicleStartEnter", getRootElement(), onVehicleStartEnter) This is the script to rent bike to a player. The bike is destroyed after 5 minutes, it's ok. But i need to do something that when player is arrasted, die, logout, exit of game the bike be destroyed too. function DestroyVeiculo (veh, seat) if getElementData(veh, "starter_pack") == true and seat == 0 then if isTimer(vehicleElements[veh]) then killTimer(vehicleElements[veh]) end --vehicleElements[veh] = setTimer(destroyElement, 300000, 1, veh) vehicleElements[veh] = destroyElement(veh) end end addEventHandler ("onPlayerLogout", getRootElement(), DestroyVeiculo) addEventHandler ("onPlayerQuit", getRootElement(), DestroyVeiculo) addEventHandler ("onPlayerWasted", getRootElement(), DestroyVeiculo) addEventHandler ("onPlayerBan", getRootElement(), DestroyVeiculo) addEventHandler ("onPlayerDie", getRootElement(), DestroyVeiculo) I tried to do it the way above, but not sucess. Someone can help me ? Thanks!
  11. Sorry by my english. I need to get a value with the whole number of weapons the player has. (Whole Number from player's weapon). I'm trying to do this, but with no sucess: function getPedWeapons(ped) local playerWeapons = {} if ped and isElement(ped) and getElementType(ped) == "ped" or getElementType(ped) == "player" then for i=2,9 do local wep = getPedWeapon(ped,i) if wep and wep ~= 0 then table.insert(playerWeapons,wep) end end else return false end return playerWeapons end function SaberArmas (player) outputChatBox("Armas (Caso tenha armas elas serão listadas abaixo!)",player,255,0,0) for i,wep in ipairs(getPedWeapons(player)) do outputChatBox("Você tem: " .. getWeaponNameFromID(wep),player,0,255,0) end end addEventHandler("onMarkerHit", MarkerInfo, SaberArmas) The script is making a list not a Whole Number. Someone can help me ?
  12. Estou com uma dúvida um tanto quanto pertinente. Quando faço um teleporte por maker por exemplo para um interior, quando o player é teleportado a câmera ao invés de ficar nas costas dele fica ao lado. Como faço para resolver ? PS: Já tentei o "setCameraTarget". Segue print abaixo para maiores detalhes: https://i.imgur.com/ClGFMrq.png
  13. Have you ever experienced some lag while gaming ? We have some common issues between us ... like someone else is using your internet ?, or you might be downloading some files ( like games ?️ or movies ? ), or you might be streaming some music ? or videos ? while playing or using another device like PS4 ? or your mobile phone ?. Well .. those issues can be resolved since that person can leave your network , or you can stop your downloading progress , or stop using your browser to get the best ping and loss in your gaming ??. However, your permanent ping and loss cannot change easily because it depends on how far your location is from the server ?, and the speed of your internet connection ?, yet ... i discovered a software which can MINIMIZE and not entirely stop this lagging and i think its kinda effective ?. Its called WTFast , and i think it can somehow help in lowering your ping or at least disabling the effect of loss. You have to pay in order to have a subscription?to this software, but there is a trial to see if this software is useful for you or not and its important to know how to use it because its different in every game ( according to the location of the server ), and for MTASA you MUST follow this tutorial in order to know how to use it in the game. so if you're interested .. go on and download the trial of this software https://www.wtfast.com/ How to use it in MTASA ? For other games, you can search Google or YouTube ?for tutorials on how to use it on those games. For MTASA ( idk if it works for SAMP ) you just have to follow this tutorial and i hope it will help ? 1. You have to download it from https://www.wtfast.com/ 2. install the software and then launch it 3. login to your trial account ( might be already logged in ) 4. In the picture below, when this screen appears for you ( my version is 4.12, you have to search for a way in order to reach custom games if you have a TOTALLY different version ) the box in red that i drew shows the listed games, this is direct as the popular games can be directly accessed from this box, but MTASA is not a listed game now, for this step you have to press Manage Settings in the green box i drew and go to step 5. 5. Now that you reached the settings, press the checkbox Enable custom games and then press save 6. Now you should be back to the main panel, press Custom games 7. Press ADD 8. Now for the most important step i will just insert a photo to explain everything for it to be easier Only for those who don't know how to copy MTASA server address 9. After you clicked OKAY, follow this picture to know everything next 10. If you want to know the location of your MTA:SA server, just type the name of the server in https://www.game-state.com/ and you will find the location of the server, then choose the nearest location of the server to your MTASA server " and this if the auto detection does not work " At the end I wish this tutorial helped you guys and feel free to ask any question in the replies ? Good Luck ?
  14. Всем привет! Поглядываю я на MTA и вспоминается мне игра All Point Bulleting! вот подумываю сделать полную копию этой игрушки на MTA! что скажите ? никто не хочет объединиться и заняться со мной данным проектом ? к примеру интерфейс, HUD, автомобили, города, вытянуть с Unreal Engine и перенеси в GTASA не проблема а вот на счёт сценария игры не знаю, кто сталкивался ? возможно ли скриптами написать свой сценарий игры ? взаимодействовать его в онлайне ? на сколько это тяжело ?
  15. Witam, mam problem z Gtasa i mtasa. Moje problemy są, nie mogę ruszać myszka w mta jeśli coś zmieniam to mi crashuje, a gtasa udało mi się naprawić w połowie, ale mam czarny ekran. Grę mam z wydania Premium games od cenegi. Prosze o pomoc. #Edit1 Mam Laptop msi. Gtx 940mx z procesorem i7 6700Hq 2,60 ghz i 8 gb ram.
  16. Hello, I'm a user of MTA from 2011, that year had a great PC and played without any problem, the passage of time to 2012 to reach a server, whose name is proyecto:SX which to MTA is updated server goes getting also updates to improve the playability of the players, but this year I play that I had to buy a slightly old pc with a core i3 of second generation to which the MTA is going a bit wrong, I have no problem in own GTA mode history, I wonder if could have a chance to get some customer of MTA that does not consume so many resources and all can enjoy, since I sometimes play to 30 fps or less.
  17. This is maybe a stupid question but maybe some one have a traffic objects map? or where it can be parsed? I have checkout an IDE, IPL files from original GTA:SA game, but i didn't found where it can be defined (dynamic traffic object with positon and rotation, i guess it maybe stored in gta3.img, right?). local aObjectIDs = { 3855; -- GAY_TRAFFIC_LIGHT 1262; -- MTraffic4 mitraffic 1263; -- MTraffic3 mitraffic 1283; -- MTraffic1 mitraffic 1284; -- MTraffic2 mitraffic 1315; -- trafficlight1 1350; -- CJ_TRAFFIC_LIGHT4 CJ_traffic 1351; -- CJ_TRAFFIC_LIGHT5 CJ_traffic 1352; -- CJ_TRAFFIC_LIGHT3 CJ_traffic }; I want to make a workaround to fix this issue: https://bugs.mtasa.com/view.php?id=9387 I Need check if vehicle near the traffic object and get object rotation.
×
×
  • Create New...