Jump to content

LPM//Bruno

Members
  • Posts

    94
  • Joined

  • Last visited

Details

  • Gang
    MTA-LPM
  • Location
    Argentina

Recent Profile Visitors

1,322 profile views

LPM//Bruno's Achievements

Punk-@ss B*tch

Punk-@ss B*tch (12/54)

0

Reputation

  1. Al precio que aka Blue considere correcto, lo compraré.
  2. Haré la ventana aparte entonces, muchas gracias!
  3. Hi all, I'm putting together a section of My Account on my server, I want it to be a little window with a tabpanel that has the following tabs: Start (where it shows the basic statistics, name, type of account, level, etc) Configuration (where it will show buttons to change the password, delete the account, etc) Clan/Gang (where it would show data exported from the gangystem) For now I can not think of any other flap, if any one sees a utility to a flap I could also recommend it The problem is this, I am creating this through the freeroam resource GUI (since the My Account button is in the freeroam too, then I wanted to do everything together). The code is the following: wndCuenta = { 'wnd', text = 'LPMV2 - Mi Cuenta', x = 380, y = 190, width = 500, height = 800, controls = { {'tbp', id='tbp1', text='pruebaTabPanel', width=200 , height=200}, }, } The result: It's strange, but I say ... maybe the tab is missing for it to work, so I add it and the code looks like this: wndCuenta = { 'wnd', text = 'LPMV2 - Mi Cuenta', x = 380, y = 190, width = 500, height = 800, controls = { {'tbp', id='tbp1', text='pruebaTabPanel', width=200 , height=200}, {'tab', id='tab1', text='pruebaTab', width=200 , height=200}, }, } But the result is that when I want to open this section (My Account) it shows the last 2 errors in the debugscript (ignore 'callesgroove' resource) Somebody could help me? From already thank you very much!
  4. Buenas a todos, estoy armando una sección de Mi Cuenta en mi servidor, quiero que sea una ventanita con un tabpanel que tenga las siguientes pestañas: Inicio (donde muestra las estadisticas basicas, nombre, tipo de cuenta, nivel, etc) Configuración (donde mostrara botones para cambiar la clave, eliminar la cuenta, etc) Clan (donde mostraria datos exportados del gangystem) Por ahora no se me ocurre ninguna otra solapa, si alguno le ve alguna utilidad a una solapa podría recomendármela también El problema es el siguiente, estoy creando esto a través de la GUI del resource freeroam (ya que el botón de Mi Cuenta está en el freeroam también, entonces quería hacer todo junto). El código es el siguiente: wndCuenta = { 'wnd', text = 'LPMV2 - Mi Cuenta', x = 380, y = 190, width = 500, height = 800, controls = { {'tbp', id='tbp1', text='pruebaTabPanel', width=200 , height=200}, }, } Y el resultado el siguiente: Es extraño, pero digo... quizá le faltan las tab para que funcione, entonces la agrego y el codigo queda así: wndCuenta = { 'wnd', text = 'LPMV2 - Mi Cuenta', x = 380, y = 190, width = 500, height = 800, controls = { {'tbp', id='tbp1', text='pruebaTabPanel', width=200 , height=200}, {'tab', id='tab1', text='pruebaTab', width=200 , height=200}, }, } Pero el resultado es que cuando quiero abrir esta sección (Mi Cuenta) muestra los ultimos 2 errores en el debugscript (ignoren el de callesgroove) Alguien podría ayudarme? Desde ya, muchas gracias!
  5. Creo que eso solo le agrega el efecto durante unos segundos y mediante una transición, yo quiero que dure hasta que el usuario inicie sesión, creo que lo voy a hacer con un PNG transparente en negro pero el problema serán las resoluciones. No sé como adaptar ese .PNG a toads las resoluciones
  6. Quiero lograr poner un fondo negro transparente para que se logren ver los mensajes del chatBox cuando sea de día, sería algo como ésto (lo hice con PhotoShop) , pero no tengo idea de como hacerlo, alguien podría ayudarme o decirme algunas ideas? Como se ve: Como quiero que se vea: Desde ya si pueden ayudarme muchas gracias
  7. Hola estoy intentando hacer un login y todo un sistema estructurado en mi servidor basado en bases de datos y consultas MySQL. El problema es que no sé si incluir el login de MTA en el login de mi servidor, es decir.. un usuario inicia sesion en mi servidor con mi login panel y les pone en los setElementData la cuenta y algunos datos mas de la DB. Pero no se si incluir que tambien inicie sesión en el servidor de MTA (logIn) por que si algun usuario en algun momento cambia su clave no va a coincidir la clave del servidor con la que esta registrada en MySQL. Deberia ignorar el login de MTA y hacer todo mi sistema por separado? Desde ya gracias
  8. Me mostró este error https://prnt.sc/fkc5uo Lo solucioné cambiando la sintaxis OOP por las tradicionales pero ahora al salirme de killcam se produce un loop y me banea infinitas veces hasta que me desconecto (agrega muchas veces el ban y los chatBox) Ya lo solucioné, muchas gracias!
  9. Creo que con eso kickearia a las 2 personas que están en la Killcam, no solo al reciever que es lo que necesito, de todos modos ahora lo pruebo y te comento como me fué, muchas gracias!
  10. Hola ando necesitando ayuda con un script, el mismo es el de la clasica Killcam (https://community.multitheftauto.com/index.php?p=resources&s=details&id=5362) pero le quise agregar una seguridad para cuando el jugador que recibe el disparo (Reciever) se desconecte, el mismo sea baneado. Pero no logro hacerlo, he hecho esto: Client (completo con mi codigo): function movecamera() x, y, z = getElementPosition(camobj) th, tj, tk = getElementPosition(tarobj) setCameraMatrix(x, y, z, th, tj, tk) end function shotfunc() if alpha <= 255 and alpha > 0 then alpha = alpha - 1 dxDrawText(text, 576, 544, 778, 601, tocolor(255, 200, 0, alpha), 2, "sans", "center", "top", false, false, false) end end addEventHandler("onClientRender", root, shotfunc) text = " " alpha = 0 function goodguy1() dxDrawLine3D(th, tj, tk, th + (hx - th - (hx - th + 0.2)), tj + (hy - tj - (hy - tj + 0.2)), tk + (hz - tk - (hz - tk + 0.2)), tocolor(64, 64, 64, 255)) end function goodguy2() dxDrawLine3D(tv, tb, tn, tv + (hx - tv - (hx - tv + 0.2)), tb + (hy - tb - (hy - tb + 0.2)), tn + (hz - tn - (hz - tn + 0.2)), tocolor(64, 64, 64, 255)) end function movereciever() tv, tb, tn = getElementPosition(target) h, j, k = getElementPosition(localPlayer) setCameraMatrix(h + 5, j + 5, k + 5, tv, tb, tn) end function killcam(tz, tx, tc, hjx, hjy, hjz, bodypart, moving, reciever, weapon) addEventHandler ( "OnClientChatMessage", getRootElement(), function() cancelEvent() end ) addEventHandler ( "OnClientConsole", getRootElement(), function() cancelEvent() end ) setGameSpeed(0.05) camobj = createObject(327, tz + 2.5, tx + 2.5, tc + 2.5) tarobj = createObject(327, tz, tx, tc) setElementData(localPlayer,"killca",true) setElementAlpha(camobj, 0) setElementAlpha(tarobj, 0) moveObject(camobj, 4000, hjx + 5, hjy + 5, hjz + 5) if bodypart == 9 then moveObject(tarobj, 5000, hjx, hjy, hjz + 1) else moveObject(tarobj, 5000, hjx, hjy, hjz) end hx = hjx hy = hjy hz = hjz addEventHandler("onClientRender", root, movecamera) addEventHandler("onClientRender", root, goodguy1) addEventHandler("onClientPlayerQuit", reciever, function () if getElementData(reciever,"killca") == true then playerToBan = getPlayerName(reciever) triggerServerEvent("banPlayer", getLocalPlayer(), playerToBan) end end) function killz() triggerServerEvent("onKillCamFinish", root, localPlayer, reciever, weapon) fxAddBlood(hjx, hjy, hjz, 0, 0, 0, 5, 1) setElementData(localPlayer,"killca",true) removeEventHandler("onClientRender", root, goodguy1) setGameSpeed(0.2) end setTimer(killz, 5000, 1) if bodypart == 3 then if moving then text = "KILL EN MOVIMIENTO" else text = "KILL" end elseif bodypart == 4 then if moving then text = "Kill en movimiento! ¡Le diste en los testiculos a "..getPlayerName(reciever):gsub("#%x%x%x%x%x%x", "").."" else text = "¡Le diste en los testiculos a "..getPlayerName(reciever):gsub("#%x%x%x%x%x%x", "").."!" end elseif bodypart == 9 then if moving then text = "HEADSHOT en movimiento a "..getPlayerName(reciever):gsub("#%x%x%x%x%x%x", "") else text = "HEADSHOT a "..getPlayerName(reciever):gsub("#%x%x%x%x%x%x", "") end end function setnormalcam() removeEventHandler("onClientRender", root, movecamera) setCameraTarget(localPlayer) destroyElement(camobj) setGameSpeed(1.2) setElementData(localPlayer,"killca",false) alpha = 255 end setTimer(setnormalcam, 6000, 1) end addEvent("onSniperHeadshot", true) addEventHandler("onSniperHeadshot", root, killcam) function recievehs(shx, shy, shz, hitx, hity, hitz) setGameSpeed(0.05) setElementData(localPlayer,"killca",true) target = createObject(327, shx, shy, shz) setElementAlpha(target, 0) moveObject(target, 5000, hitx, hity, hitz) hx = hitx hy = hity hz = hitz addEventHandler("onClientRender", root, movereciever) addEventHandler("onClientRender", root, goodguy2) function gods() removeEventHandler("onClientRender", root, goodguy2) setGameSpeed(0.2) setElementData(localPlayer,"killca",true) end setTimer(gods, 5000, 1) function endcam() removeEventHandler("onClientRender", root, movereciever) destroyElement(target) setCameraTarget(localPlayer) setGameSpeed(1.2) setElementData(localPlayer,"killca",false) end setTimer(endcam, 6000, 1) end addEvent("onRecieveSniperHeadshot", true) addEventHandler("onRecieveSniperHeadshot", root, recievehs) function bloodhead(weapon, ammo, ammoclip, hx, hy, hz, hitelement, sx, sy, sz) if weapon == 34 then a = hx s = hy d = hz function bloods() fxAddBlood(a, s, d, 0, 0, 0, 5, 1) end setTimer(fxAddBlood, 3500, 1) end end addEventHandler("onClientWeaponFire", root, bloodhead) function godci () if getElementData(localPlayer,"killca") == true then cancelEvent() end end addEventHandler("onClientPlayerDamage",root,godci) Aqui solo el codigo que agregue yo para que entiendan mejor y no tengan que buscar: addEventHandler("onClientPlayerQuit", reciever, function () if getElementData(reciever,"killca") == true then playerToBan = getPlayerName(reciever) triggerServerEvent("banPlayer", getLocalPlayer(), playerToBan) end end) Server: function banPlr(who) local targetPlayer = getPlayerFromName ( who ) banPlayer(targetPlayer,false,false,true,root,"Salir de Killcam",14400) outputChatBox ( "#FE2E2E[LPM.KCProtection] "..who.."#FE2E2E ha sido baneado por salir de Killcam (4 horas).", root, 255, 0, 0, true ) outputDebugString ("Jugador "..who.." baneado correctamente por salir de Killcam.") end addEvent("banPlayer", true) addEventHandler("banPlayer", getRootElement(), banPlr) El otro server esta compilado por eso no lo agrego, pero la killcam funciona. El problema esta en el getPlayerFromName, cuando quiero banear al jugador dice que espera recibir el Player, pero recibe un boolean y no se por que, si yo le estoy pasando el string correctamente (ya que en el ChatBox y el DebugString se imprimen correctamente). Espero puedan ayudarme, muchas gracias
  11. Hice lo que me dijeron con los 2 handlers y ninguno funcionó,y tambien probe con elementsData pero tampcoo, ayuda
  12. onResourceStart o onPlayerLogin, decidanse D:
  13. Es onResourceStart solamente no?
  14. Hola como están , estoy editando el script de realdriveby para que solo pueda ser utilizado por usuarios VIP en mi servidor (ACL: VIPs) el problema es que no sé por qué no funciona la forma en la cual lo estoy haciendo, intente con variables comunes y triggers desde el servidor hacia el cliente y hasta con setElementData y getElementData, nada sirvió, el script se inicia y no muestra ningún error (con debugscript 3 activo) y deniega el acceso al realdriveby todo el tiempo (como si el player no estuviese en el ACL VIPs a comprobar, pero en realidad si está); espero puedan ayudarme. driveby_client.lua (Cortado, solo inserte aqui las funciones que yo agrege al script original) local driver = false local shooting = false local helpText,helpAnimation lastSlot = 0 settings = {} usuarioVip = false addEvent ( "activarUsuarioVip", true ) addEventHandler("activarUsuarioVip",getRootElement(), function() usuarioVip = true end ) local function setupDriveby( player, seat ) if usuarioVip == true then outputChatBox("[LPM-VIP] Puedes disparar desde el vehiculo.",0,255,0,true) bindKey ( "mouse2", "down", "Toggle Driveby", "" ) bindKey ( "e", "down", "Next driveby weapon", "1" ) bindKey ( "q", "down", "Previous driveby weapon", "-1" ) toggleControl ( "vehicle_next_weapon",false ) toggleControl ( "vehicle_previous_weapon",false ) helpText = dxText:create("",0.5,0.85) helpText:scale(1) helpText:type("stroke",1) --If his seat is 0, store the fact that he's a driver if seat == 0 then driver = true else driver = false end --By default, we set the player's equiped weapon to nothing. setPedWeaponSlot( localPlayer, 0 ) if settings.autoEquip then toggleDriveby() end else outputChatBox("[LPM] Si deseas disparar desde el vehiculo compra una cuenta VIP en www.mtalpm.com",255,255,0,true) return end end addEventHandler( "onClientPlayerVehicleEnter", localPlayer, setupDriveby ) driveby_server.lua (Cortado, solo inserte aqui las funciones que yo agrege al script original) function verificarVIP ( ) local cuenta = getAccountName( getPlayerAccount(client) ) if isObjectInACLGroup("user."..cuenta, aclGetGroup("VIPs")) then triggerClientEvent ( client, "activarUsuarioVip", client ) else end end addEventHandler("onClientResourceStart", getRootElement(), verificarVIP)
×
×
  • Create New...