emaa24 Posted October 20, 2012 Posted October 20, 2012 Hola bueno, tengo pensado hacer un servidor de drift, y quisiera saber, como se hace para teletrasportarse a una pista con un comando, por ejemplo para ir a la colina de SF /bigear, y te lleva alla... desde ya muchas gracias, un saludo!
Tonyx97 Posted October 20, 2012 Posted October 20, 2012 Facil, esto ponlo en "Server": Code: function teletransporte (thePlayer) setElementPosition ( thePlayer, -310.43, 1522.56, 75.35937 ) end addCommandHandler ("bigear",teletransporte) esto te llevará a The Big Ear, en El desierto cerca del Area 51.
Renkon Posted October 20, 2012 Posted October 20, 2012 addCommandHandler("tp", function(p, c, x, y, z) if not p or not type(x) == "number" or not type(y) == "number" or not type(z) == "number" then return end setElementPosition(p, x, y, z) end) /tp 0 0 0 te llevaría a una granja
Mixters Posted October 20, 2012 Posted October 20, 2012 @Tonyx97 estando 'thePlayer' no teletransporta como tal. pero intenta ponerlo source.
emaa24 Posted October 20, 2012 Author Posted October 20, 2012 (edited) Muchas gracias a todos por responder, ahora mismo los pruebo y les comento como me fue [EDIT] Genial!! Me funciono muchas gracias por la ayuda _ Edited October 20, 2012 by Guest
Alexs Posted October 20, 2012 Posted October 20, 2012 @Mixters si lo hace, en el comando el primer parámetro es el jugador que lo efectuó.
Mixters Posted October 22, 2012 Posted October 22, 2012 yo decía que podía hacer algo así.. function teletransporte (source) setElementPosition ( source, 1109, 1541, 3269 ) -- Lugar al que vas al poner el comando end addCommandHandler ( "bigear", teletransporte ) Yo digo que mejor lo use así. y si le sirve el otro bueno yo intente con thePlayer y solo te teletrasporta a ti, pero a los demás usuarios no les sirvió.
NodZen Posted October 22, 2012 Posted October 22, 2012 function teletransporte ( source, commandName, posX, posY, posZ ) setElementPosition ( source, 1109, 1541, 3269 ) end addCommandHandler ( "bigear", teletransporte )
emaa24 Posted October 22, 2012 Author Posted October 22, 2012 Con el de the player, me teletrasporta, pero debo estar fuera del vehiculo, como hago para teletrasportarme con el vehiculo ?
Castillo Posted October 22, 2012 Posted October 22, 2012 function teletransporte ( thePlayer ) local theElement = ( isPedInVehicle ( thePlayer ) and getPedOccupiedVehicle ( thePlayer ) or thePlayer ) setElementPosition ( theElement, 1109, 1541, 3269 ) end addCommandHandler ( "bigear", teletransporte )
emaa24 Posted October 22, 2012 Author Posted October 22, 2012 Gracias por responder, pero no me funciona... no sucede nada
NodZen Posted October 23, 2012 Posted October 23, 2012 Gracias por responder, pero no me funciona... no sucede nada Lo pusiste como server?.
emaa24 Posted October 23, 2012 Author Posted October 23, 2012 sisi, osea, me anda teletrasportarme fuera del vehiculo, con el vehiculo no me funciona..
Recommended Posts