Jump to content

Search the Community

Showing results for tags 'getelementvelocity'.

  • 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 1 result

  1. local veh = getPedOccupiedVehicle(localPlayer) speedx, speedy, speedz = getElementVelocity ( veh ) actualspeed = (speedx^2 + speedy^2 + speedz^2)^(0.5) kmh = actualspeed * 180 function Inicio (element) if element == localPlayer then if (kmh) <= 20 then --Si es menor o igual a 20Km/h if veh then setElementFrozen ( veh, true ) --freez if timer then killTimer(timer) timer = nil end timer = setTimer(SiguienteMarker, 3000, 1) --Que freeze, espere 3 segundos y siga el otro marker end end end El problema es que no funciona el "If (kmh) <= 20 then, al poner eso directamente me deja de funcionar todo, alguien sabe porqué? Lo que quiero es que solo se active cuando el jugador Toque el marker y a menos de 20km/h con su vehiculo y recien ahi freeze al jugador y cuente para luego crear otro marker..
×
×
  • Create New...