Felipe Viedma Posted January 31, 2013 Posted January 31, 2013 bueno eh estado trabjando en un script de eventwarp al estilo CIT y ya casi esta listo solo me falta hacer la funcion para que los player al teclear /eventwarp se warpeen al marker que se creo en mi posicion aqui el script server_side : function consoleCreateMarker ( thePlayer, commandName ) if hasObjectPermissionTo ( thePlayer, "command.mute" ) then local x, y, z = getElementPosition ( thePlayer ) if ( theMarker ) then if isElement(theMarker) then destroyElement(theMarker) theMarker = nil end if isElement(blip) then destroyElement(blip) blip = nil end outputChatBox ( "event disabled", thePlayer ) else theMarker = createMarker ( x + 2, y + 2, z - 1, "cylinder", 1.5, 255, 255, 0, 170 ) blip = createBlipAttachedTo ( theMarker, 49, 1 ) dim = getElementDimension ( thePlayer ) int = getElementInterior(thePlayer) setElementDimension ( theMarker, dim ) setElementInterior ( theMarker, int) outputChatBox ( "#00FF00An event has just been created use #FF0000/eventwarp #00FF00now!", getRootElement(), 255, 255, 255, true ) end end end addCommandHandler ( "evento", consoleCreateMarker ) la ayuda es si me pudieran complementar con alguna funcion o bien comentarme algunas de las cosas que puedo hacer gracias de ante mano
RekZ Posted January 31, 2013 Posted January 31, 2013 enserio eso te funciona ? tiene menos orden que mi cuarto un fin de semana te recomiendo que lo ordenes un poco
Alexs Posted January 31, 2013 Posted January 31, 2013 Yo lo veo por completo ordenado: function consoleCreateMarker ( thePlayer, commandName ) if hasObjectPermissionTo ( thePlayer, "command.mute" ) then local x, y, z = getElementPosition ( thePlayer ) if ( theMarker ) then if isElement(theMarker) then destroyElement(theMarker) theMarker = nil end if isElement(blip) then destroyElement(blip) blip = nil end outputChatBox ( "event disabled", thePlayer ) else theMarker = createMarker ( x + 2, y + 2, z - 1, "cylinder", 1.5, 255, 255, 0, 170 ) blip = createBlipAttachedTo ( theMarker, 49, 1 ) dim = getElementDimension ( thePlayer ) int = getElementInterior(thePlayer) setElementDimension ( theMarker, dim ) setElementInterior ( theMarker, int) outputChatBox ( "#00FF00An event has just been created use #FF0000/eventwarp #00FF00now!", getRootElement(), 255, 255, 255, true ) end end end addCommandHandler ( "evento", consoleCreateMarker )
Felipe Viedma Posted January 31, 2013 Author Posted January 31, 2013 si pero la idea es que despues creado el marker los player tecleen /eventwarp y se warpeen al marker esa es la funcion que me complica
Felipe Viedma Posted January 31, 2013 Author Posted January 31, 2013 mira tu tienes algun server para qe vallamos a probarlo?
Sensacion Posted January 31, 2013 Posted January 31, 2013 Te di ese pedazo de código incompleto para que aprendas directamente de la wiki... ya veo que no puedes.
Felipe Viedma Posted January 31, 2013 Author Posted January 31, 2013 denle lock a este topic no quiero contar lo que hace en realidad esta persona
Recommended Posts