Jump to content

por que no se guarda ?


RekZ

Recommended Posts

Posted

tengo un servidor de zombis con el login y el skin selector pero tengo el problema de que las kills y el dinero no se guarda :/ e vinculado el login al admin y tengo el dxscoreboard espero que con eso me puedan ayudar

Admin and Owner of the Pro Chile Community :3

Posted

Como vamos a ayudarte si no posteas tu script para guardar los datos?

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

Posted

Por supuesto, el MTA no trae ningun script para guardar kills, dinero, etc.

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

Posted

solo e encontrado uno en la comunida que me sirva pero solo guarda el dinero :/ las kills se reinician

function playerLeave() 
    local playeracc = getPlayerAccount(source) 
    if ( playeraccount == true ) then 
        local playercash = getPlayerMoney(source) 
        setAccountData(playeracc, "cash", playercash) 
    end 
end 
  
function playerReJoin() 
    local playeracc = getPlayerAccount(source) 
    if (playeracc == true) then 
        local playerbank = getAccountData(playeracc, "cash",) 
        if (playerbank == true) then 
            setPlayerMoney(source, playerbank) 
        else 
            outputChatBox("You have no cash in your bank. no money has been set!", source, 255, 0, 0) 
        end 
    end 
end 
  
addEventHandler("onPlayerJoin", getRootElement(), playerReJoin) 
addEventHandler("onPlayerLeave", getRootElement(), playerLeave) 

Admin and Owner of the Pro Chile Community :3

Posted
function playerLeave() 
    local playeracc = getPlayerAccount(source) 
    if ( playeracc ) then 
        local playercash = getPlayerMoney(source) 
        setAccountData(playeracc, "cash", playercash) 
    end 
end 
  
function playerReJoin() 
    local playeracc = getPlayerAccount(source) 
    if ( playeracc ) then 
        local playerbank = getAccountData(playeracc, "cash") 
        if (playerbank) then 
            setPlayerMoney(source, tonumber(playerbank)) 
        end 
    end 
end 
  
addEventHandler("onPlayerJoin", getRootElement(), playerReJoin) 
addEventHandler("onPlayerQuit", getRootElement(), playerLeave) 

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

Posted

Si, arregle un error, copialo de nuevo y proba.

P.D: Es server side.

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

Posted

es lo mismo no se guardan las kills :/ y gracias por recordar los del server lo abia puesto client

Admin and Owner of the Pro Chile Community :3

Posted

No es magico, eso solo guarda el dinero.

San Andreas Utopia RPG (SAUR) Owner & Developer.

560x95_FFFFFF_FF9900_000000_000000.png

Education is the most powerful weapon which you can use to change the world.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...