Jump to content

Search the Community

Showing results for tags 'setelementposition'.

  • 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 4 results

  1. Hola hace poco empese a ver tutoriales de scripting mta, y tengo un problema con un marker, una vez en el interior al querer salir aparezco en medio de la nada, veo las edificaciones a lo lejos y escucho el motor del auto que deje en el exterior. No se si el problema estaraen el codigo, si hago dos marker en el exterior no tengo problemas voy de uno a otro sin problemas. marker_entrada = createMarker (1363.81640625, -1279.626953125, 13.546875+1, "arrow", 2, 255, 255, 0, 170) marker_interior = createMarker (285.7109375, -40.9658203125, 1001.515625+1, "arrow", 2, 255, 255, 0, 170) setElementInterior(marker_interior, 1) function La_Entrada(hitElement) setElementInterior(hitElement, 1, 287.466796875, -38.779296875, 1001.515625, 0, 0, 7.7811889648438) end addEventHandler("onMarkerHit", marker_entrada, La_Entrada) function La_Salida(hitElement) setElementPosition(hitElement, 1363.81640625, -1279.626953125+4, 13.546875) end addEventHandler("onMarkerHit", marker_interior, La_Salida) al salir del interior me pasa esto: si alguien tiene una idea de que puede ser, les estare muy agradecidos...
  2. First, I began with this: When entering either marker, you are taken to the specified location. It works perfectly. Both markers take me to the desired location in San Andreas' map. I moved them around and changed the shape of the marker just to be sure. There were no problems. Then, I found this: This is supposed to teleport you into the specified interior (nº0), and the coordinates next to the interior (x, y, z) The chatbox outputs the expected message. However, there is no teleporting to the specified place. The function 'setElementInterior' looks good, judging by what the wiki says. What am I missing? Something tells me it's a very obvious error I'm failing to see.
  3. Hello ! Below code working find without any error ! addEventHandler("onPlayerLogin",root, function () bindKey(source,"1","down", function (p) setElementPosition(p,0,0,5) end) end ) When player login, button 1 will bind to the function. So, when player press 1 key, he will wrap in to the position. But the problem is, when player in a vehicle, he wouldn't wrap into the position... ! There's a way to solve this like if player in a vehicle when he press 1, vehicle will destroy and player wrapped into the position. But, I want to wrap the player to the position without destroying the vehicle. Are there any way to troubleshoot by problem ? or any alternative way ? Please Help Me ! ------------------------------------------------------------------------------------------------------------------------------------------- heheey ! There's a function called 'removePedFromVehicle'. That was helped me in this occasion !! Thank You @removePedFromVehicle ..!!
  4. Con el CommandHandler "Sube" funciona, pero con el Pe, ¿Que hace? Crea el objeto, pero no lo redirecciona con el SetElementPosition y attach, es como si lo ignorara... ¿Alguna solución? function SubenPasajeros () if CantidadDeAsientos >= 0 then if Asiento1 == 0 then Asiento1 = 1 local vehicle = getPedOccupiedVehicle( client ) x1, y1, z1 = getElementPosition ( client ) Asiento1 = createObject (2035, 1421.958984375, 2624.4677734375, 11.392612457275) setElementPosition ( Asiento1, x1, y1, z1) attachElements( Asiento1, vehicle, 0.95, 0.6, 0, 0, 0, 0 ) --Fila 1 A outputChatBox ("Asiento1") else if Asiento2 == 0 then Asiento2 = 1 outputChatBox ("Asiento2") local vehicle = getPedOccupiedVehicle( client ) x1, y1, z1 = getElementPosition ( client ) Asiento2 = createObject (2035, 1421.958984375, 2624.4677734375, 11.392612457275) setElementPosition ( Asiento2, x1, y1, z1) attachElements( Asiento2, vehicle, 0.5, -0.2, 0, 0, 0, 0 ) --Fila 2 B end end end addCommandHandler("sube",SubenPasajeros) function PrenderFuncSubenPasajeros () outputChatBox ("JEJE") setTimer ( SubenPasajeros, 500, 1) end addCommandHandler("pe",PrenderFuncSubenPasajeros)
×
×
  • Create New...