Search the Community

Showing results for tags 'safezone'.



More search options

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

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


About Me


Gang


Location


Occupation


Interests

Found 2 results

  1. Já testei várias áreas verdes! E com todas elas consigo atirar do veículo usando o realdriveby ou com qualquer outro script de atirar do veículo! Alguém conhece alguma área verde que bloquear o realdriveby, ou sabe como programar uma para isso ? Também já coloquei o vehicle_fire em todas elas e não consegui.
  2. first of all its my firs topic in forums. I'm having problem with my safezone script which i wrote all of it (nearly, took hints from wiki) the problem is, when i enter the zone, it says 'you entered safezone' , but after a few seconds, 'you left the safezone' text appears. I couldnt solve the problem with my knowledge so im looking for help. only problem is; it says i left safezone after a few seconds, other functions working fine. clientside: safezones = { {1578.2421875, 1801.248046875, 10.8203125, 58, 61, 100}, {1996.958984375, -1450.9560546875, 13.5546875, 100, 55, 100}, {-2740.775390625, 577.9326171875, 14.5546875, 150, 100, 100}, } function createthings () for i, v in ipairs (safezones) do x, y, z, w, d, h = unpack(v) safezone = createColCuboid(x, y, z - 30, w, d, h) radar = createRadarArea(x, y, w, d, 0, 200, 0, 50) addEventHandler("onClientColShapeHit", safezone, hit) addEventHandler("onClientColShapeLeave", safezone, Leave) end end addEventHandler("onClientResourceStart", resourceRoot, createthings) function no() cancelEvent () end function disableproof() removeEventHandler ("onPlayerDamage",localPlayer,no) end function hit(element) if source == safezone then setPedWeaponSlot (element,0) if (getElementType (element) == "vehicle") then exports.GTWvehicleshop:saveAndRemoveVehicle(element,true) exports.GTWtopbar:dm("You can't drive vehicle inside safezone",200,50,50) toggleControl ("next_weapon",false) toggleControl ("previous_weapon",false) toggleControl ("fire",false) addEventHandler ("onPlayerDamage",localPlayer,no) addEventHandler("onPedWasted", localPlayer, disableproof) elseif (getElementType (element) == "player") then exports.GTWtopbar:dm("You entered the safezone, all weapons are forbidden.",200,50,50) toggleControl ("next_weapon",false) toggleControl ("previous_weapon",false) toggleControl ("fire",false) addEventHandler ("onPlayerDamage",localPlayer,no) addEventHandler("onPedWasted", localPlayer, disableproof) end end end function Leave(element) if source == safezone then exports.GTWtopbar:dm("You left the safezone.",200,50,50) toggleControl ("next_weapon",true) toggleControl ("previous_weapon",true) toggleControl ("fire",true) removeEventHandler ("onPlayerDamage",localPlayer,no) end end