-
Posts
551 -
Joined
-
Last visited
Everything posted by depato123
-
¿Mi server esta protegido?
depato123 replied to depato123's topic in Ayuda relacionada al cliente/servidor
Otra consulta mas ¿Existe un hack para que me puedan robar los scripts que no lo detecte el anticheat? -
Hola, tengo un problema con este script. addEventHandler("onPlayerLogin", resourceRoot, function() thewindow = guiCreateWindow(476, 577, 405, 95, "Nombre de personaje", false) guiWindowSetSizable(thewindow, false) memousuario = guiCreateMemo(131, 24, 264, 38, "", false, thewindow) Nombredeusuario = guiCreateLabel(14, 34, 140, 15, "Nombre de usuario:", false, thewindow) guiSetFont(Nombredeusuario, "default-bold-small") textoexplicacion = guiCreateLabel(24, 71, 352, 24, "El nombre de usuario debe estar en el formato Nombre_Apellido", false, thewindow) end ) function menuShow () visableornot = guiGetVisible (theWindow) if (visableornot == true) then guiSetVisible (theWindow, false) showCursor (false) end if (visableornot == false) then guiSetVisible (theWindow, true) showCursor (true) end end addEventHandler ("onPlayerLogin", getRootElement(), menuShow) Este escript tendria que funcionar así: Yo tengo un login panel y intente agregarle este script. lo que tendria que pasar es que al registrarse le apareciera este gui pero no aparece. No hay errores en el debug Ayuda¡¡
-
Hola. Un amigo me contó que hay un hack que no lo detecta el anti cheat que sirve para robar scripts de servidores. ¿Esto es verdad? ¿Me pueden robar todos los scripts? PD: Escribí mal algo
-
ah. ok, me estaba confundiendo con otra cosa. Gracias
-
Mejor cierren el tema
-
¿Como puedo hacer un sistema de personajes? ¿Que cosas debo usar?
-
Perdon. Y gracias
-
Si alguien ataca mi server que no tiene protección anti ddos y se cae ¿Que debo hacer? ¿Debo reiniciar el server?
-
¿Como? si ya esta definido así local veh = isElementFrozen ( source )
-
Intenté poner la funcion por comandos envez de marcador y al poner el comando no funciona function HitMarker(player, dimension) if dimension and getElementType( player ) == "player" then local vehicle = getPedOccupiedVehicle( player ) if vehicle then local driver = getVehicleController( vehicle ) if driver == player and not getVehicleInModShop( source ) then for k,v in ipairs( modShops ) do if modShops[ k ].marker == source and getElementType( vehicle ) == "vehicle" then timers[ vehicle ] = setTimer( unfreezeVehicleInModShop, 60000 * TIME_IN_MODSHOP, 1, vehicle ) timersClient[ vehicle ] = setTimer( triggerClientEvent, 60000 * TIME_IN_MODSHOP - 200, 1, driver, "modShop_clientResetVehicleUpgrades", driver ) setModShopBusy( source, vehicle ) freezVehicleInModShop( vehicle, modShops[ k ].marker ) triggerClientEvent( driver, "onClientPlayerEnterModShop", player, vehicle, getPlayerMoney( player ), modShops[ k ].name ) end end end end end end addCommandHandler( "mejorarcoche", HitMarker )
-
Hola, tengo un problema con este script: function frenodedMano ( ) if ( isPedInVehicle ( source ) ) then local veh = isElementFrozen ( source ) if ( isElementFrozen ( veh ) == true ) then setElementFrozen ( veh, false ) local px, py, pz = getElementPosition ( source ) for _, v in ipairs ( getElementsByType ( "player" ) ) do if isPlayerInRangeOfPoint ( v, px, py, pz, chat_range ) then outputChatBox ( "*".. getPlayerName ( source ) .." ah puesto el freno de mano.", v, 255, 40, 80 ) end end else setElementFrozen ( veh, true ) local px, py, pz = getElementPosition ( source ) for _, v in ipairs ( getElementsByType ( "player" ) ) do if isPlayerInRangeOfPoint ( v, px, py, pz, chat_range ) then outputChatBox ( "*".. getPlayerName ( source ) .." ah removido el freno de mano.", v, 255, 40, 80 ) end end end else outputChatBox ("You aren't in a vehicle!", source, 255, 0, 0) end end addEvent ( "frenodeMano",true ) addEventHandler ( "frenodeMano", getRootElement(), frenodedMano ) El error Lo que tendria que pasar si el resource funcionara es lo siguiente: Al apretar un boton que esta trigeado el vehiculo se congela. Pero eso no pasa y sale el error de arriba. !!Ayuda¡¡
-
Si, hay muchos login panel, pero yo quiero uno avanzado y no puedo hacerlo yo solo. Sino no pediría ayuda en el foro
-
Busco Scripter para mta sv. Necesito que me ayude a scriptear 2 resources ►Login Panel ►Un contesta preguntas Busco ayuda y pago bien. :C PD: Creo que hice un fail
-
Ya lo cambie por if (source == modShops[ 1 ].marker) then ¿Para que sirve esto? if dimension and getElementType( player ) == "player" then Pero no ocurre la funcion esta al usar el comando function HitMarker(thePlayer, commandName, ...) if dimension and getElementType( player ) == "player" then local vehicle = getPedOccupiedVehicle( player ) if vehicle then local driver = getVehicleController( vehicle ) if driver == player and not getVehicleInModShop( source ) then for k,v in ipairs( modShops ) do if modShops[ k ].marker == source and getElementType( vehicle ) == "vehicle" then timers[ vehicle ] = setTimer( unfreezeVehicleInModShop, 60000 * TIME_IN_MODSHOP, 1, vehicle ) timersClient[ vehicle ] = setTimer( triggerClientEvent, 60000 * TIME_IN_MODSHOP - 200, 1, driver, "modShop_clientResetVehicleUpgrades", driver ) setModShopBusy( source, vehicle ) freezVehicleInModShop( vehicle, modShops[ k ].marker ) triggerClientEvent( driver, "onClientPlayerEnterModShop", player, vehicle, getPlayerMoney( player ), modShops[ k ].name ) end end end end end end PD: el resource original venia así addEventHandler( "onMarkerHit", getResourceRootElement( getThisResource( ) ),) function( player, dimension ) if dimension and getElementType( player ) == "player" then local vehicle = getPlayerOccupiedVehicle( player ) if vehicle then local driver = getVehicleController( vehicle ) if driver == player and not getVehicleInModShop( source ) then for k,v in ipairs( modShops ) do if modShops[ k ].marker == source and getElementType( vehicle ) == "vehicle" then timers[ vehicle ] = setTimer( unfreezeVehicleInModShop, 60000 * TIME_IN_MODSHOP, 1, vehicle ) timersClient[ vehicle ] = setTimer( triggerClientEvent, 60000 * TIME_IN_MODSHOP - 200, 1, driver, "modShop_clientResetVehicleUpgrades", driver ) setModShopBusy( source, vehicle ) freezVehicleInModShop( vehicle, modShops[ k ].marker ) triggerClientEvent( driver, "onClientPlayerEnterModShop", player, vehicle, getPlayerMoney( player ), modShops[ k ].name ) end end end end end end ) Yo lo cambie para que al pasar por el marker se creara un comando y al usar ese comando se ejecutara las funciones pero al usar el comando no ejecuta las funciones
-
Otra pregunta. ¿Como se llama el marker? modShops[ 1 ].marker = createMarker( -2275.7241210938, 2413.0808105469, 4.4324097633362, "cylinder", 4.5, 255, 0, 0, 100 ) Porque tengo esto if (source == modShops) then pero no me sirve, como que no me reconoce el marker
-
Perdon. lo olvide. Es la linea 46 el addEventHandler
-
[2013-11-12 18:41:06] SCRIPT ERROR: vehiclesystemcarshops2\server.lua:56: 'end' expected (to close 'for' at line 44) near 'else' [2013-11-12 18:41:06] ERROR: Loading script failed: vehiclesystemcarshops2\server.lua:56: 'end' expected (to close 'for' at line 44) near 'else'
-
Hola tengo un problema con esto modShops[ 1 ] = { } --modShops[ 1 ].colShape = createColTube( -2723.7060, 217.2689, 4.0, 200, 1000 ) modShops[ 1 ].veh = false modShops[ 1 ].marker = createMarker( -2275.7241210938, 2413.0808105469, 4.4324097633362, "cylinder", 4.5, 255, 0, 0, 100 ) modShops[ 1 ].name = "Wheel Arch Angles" --createBlipAttachedTo( modShops[ 1 ].colShape, 27 ) createBlipAttachedTo( modShops[ 1 ].marker, 27, 2, 0,0,0,255, 0, 180 ); function markerHit (hitPlayer, matchingDimension) if dimension and getElementType( player ) == "player" then outputChatBox ("Para mejorar el auto decir /mejorarcoche", hitPlayer, 255, 0, 0, false) addCommandHandler( "an", HitMarker ) end end addEventHandler ("onMarkerHit", getRootElement(), markerHit) function markerHit (leavePlayer, matchingDimension) if dimension and getElementType( player ) == "player" then removeCommandHandler ( "an", HitMarker ) end end addEventHandler ("onMarkerLeave", getRootElement(), markerHit) function HitMarker(thePlayer, commandName, ...) if dimension and getElementType( player ) == "player" then local vehicle = getPedOccupiedVehicle( player ) if vehicle then local driver = getVehicleController( vehicle ) if driver == player and not getVehicleInModShop( source ) then for k,v in ipairs( modShops ) do if modShops[ k ].marker == source and getElementType( vehicle ) == "vehicle" then timers[ vehicle ] = setTimer( unfreezeVehicleInModShop, 60000 * TIME_IN_MODSHOP, 1, vehicle ) timersClient[ vehicle ] = setTimer( triggerClientEvent, 60000 * TIME_IN_MODSHOP - 200, 1, driver, "modShop_clientResetVehicleUpgrades", driver ) setModShopBusy( source, vehicle ) freezVehicleInModShop( vehicle, modShops[ k ].marker ) triggerClientEvent( driver, "onClientPlayerEnterModShop", player, vehicle, getPlayerMoney( player ), modShops[ k ].name ) end end end end end end addEventHandler( "onMarkerHit", getResourceRootElement( getThisResource( ) ),) Lo que tendria que pasar en el script es que al pasar con un auto por arriba del marker apareciera un mensaje diciendo "Para mejorar el auto decir /mejorarcoche" y apareciera un comando /mejorarcoche. y al salir del marker el comando desapareciera. El problema es que cuando quise probar el resource no se crea el marker y aparece esto en el debug script ayudaaa por favor
-
Gracias, pero eso no sirve. Al presionar el botón no sucede nada
-
Hola. tengo un problema con este script script original: function engineSwitch () if (isPedInVehicle (source)) then local veh = getPedOccupiedVehicle (source) if (getVehicleEngineState (veh) == true) then setVehicleEngineState (veh, false) outputChatBox ("*".. getPlayerName(source) .." ah apagado el Vehiculo.", v, 255, 40, 80) elseif (getVehicleEngineState (veh) == false) then setVehicleEngineState (veh, true) local px,py,pz = getElementPosition(source) for _,v in ipairs(getElementsByType("player")) do if isPlayerInRangeOfPoint(v,px,py,pz,chat_range) then outputChatBox ("*".. getPlayerName(source) .." ah encendido el Vehiculo.", v, 255, 40, 80) end end end else outputChatBox ("You aren't in a vehicle!", source, 255, 0, 0) end end addEvent("engenieSwitch",true) addEventHandler("engenieSwitch",getRootElement(),engineSwitch) function isPlayerInRangeOfPoint(player,x,y,z,range) local px,py,pz=getElementPosition(player) return ((x-px)^2+(y-py)^2+(z-pz)^2)^0.5 <= range end script editado chat_range = 100 -- Distancia function engineSwitch () if (isPedInVehicle (source)) then local veh = getPedOccupiedVehicle (source) if (getVehicleEngineState (veh) == true) then setVehicleEngineState (veh, false) local px,py,pz = getElementPosition(source) for _,v in ipairs(getElementsByType("player")) do if isPlayerInRangeOfPoint(v,px,py,pz,chat_range) then outputChatBox ("*".. getPlayerName(source) .." ah apagado el Vehiculo.", v, 255, 40, 80) elseif (getVehicleEngineState (veh) == false) then setVehicleEngineState (veh, true) local px,py,pz = getElementPosition(source) for _,v in ipairs(getElementsByType("player")) do if isPlayerInRangeOfPoint(v,px,py,pz,chat_range) then outputChatBox ("*".. getPlayerName(source) .." ah encendido el Vehiculo.", v, 255, 40, 80) end end end else outputChatBox ("You aren't in a vehicle!", source, 255, 0, 0) end end addEvent("engenieSwitch",true) addEventHandler("engenieSwitch",getRootElement(),engineSwitch) function isPlayerInRangeOfPoint(player,x,y,z,range) local px,py,pz=getElementPosition(player) return ((x-px)^2+(y-py)^2+(z-pz)^2)^0.5 <= range end Al agregarle estas 3 renglones en la linea 5 deja de funcionar local px,py,pz = getElementPosition(source) for _,v in ipairs(getElementsByType("player")) do if isPlayerInRangeOfPoint(v,px,py,pz,chat_range) then El resourse lo que tendria que hacer es al apretar un boton que el vehiculo se cierre y que aparezca el mensaje *Usuario: Ha encendido el vehiculo. En el original solo pasa eso al apagarlo pero al encenderlo aparece el mensaje a todo el server. Mientras necesito que solo se vea en un rango de 10
-
¿Como puedo hacer que un comando este solo para adm?
-
Me sigue diciendo que un simbolo esta mal function cnnChat(thePlayer, commandName, ...) if ( getPlayerTeam ( thePlayer ) and getTeamName ( getPlayerTeam ( thePlayer) ) == "Reporteros de CNN" ) then local players = getElementsByType("player") local playerName = getPlayerName ( thePlayer ) local chatContent = {...} for index, player in ipairs ( players ) do outputChatBox( "[CNN] ".. playerName.. ": " ..table.concat ( chatContent, " "), player, 196, 255, 255) end else outputChatBox( "No eres de reportero de cnn"), player, 196, 255, 255) end end addCommandHandler( "sr", cnnChat
