[Ajuda] Sistema de [UP Level]
#1

Bom, o erro й bem simples, porйm nгo tф conseguindo resolver.
Й o seguinte, to criando o sistema de UP level/Experiкncia, eu criei e tб tudo certo, mais quando vocк upa 1 Level aparece a mensagem:

"[UP] Parabйns, vocк upou mais 1 level bla la bla , seu level й: 0 " invйs de aparecer "Seu level й: 102/Ou o level do cara" aparece 0, sempre 0.

Cуdigo do UP level.

pawn Код:
public Exp()
{
    new string[70];
    for(new i=0; i < MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i))
        {
                if(PlayerInfo[i][Exp] == 5)
                {
                    SetPlayerScore(i,GetPlayerScore(i) + 1);
                    PlayerInfo[i][Exp] = 0;
                    format(string, sizeof(string), "(UP) Vocк acaba de ganhar +1 level, seu level agora й: %d",PlayerInfo[i][Level]);
                    SendClientMessage(i, 0x00FF00AA, string);
                    PlayerPlaySound(i, 1057, 0.0, 0.0, 10.0);
                    SalvarDadosPlayer(i);
                }
                else
Se precisarem do resto da public sу pedir.
Reply
#2

pawn Код:
public Exp()
{
    new string[70];
    for(new i=0; i < MAX_PLAYERS; i++)
    {
        if(IsPlayerConnected(i))
        {
            if(PlayerInfo[i][Exp] == 5)
            {
                SetPlayerScore(i,GetPlayerScore(i) + 1);
                PlayerInfo[i][Level] = GetPlayerScore ( i );
                PlayerInfo[i][Exp] = 0;
                SalvarDadosPlayer(i);
                format(string, sizeof(string), "(UP) Vocк acaba de ganhar +1 level, seu level agora й: %d",PlayerInfo[i][Level]);
                SendClientMessage(i, 0x00FF00AA, string);
                PlayerPlaySound(i, 1057, 0.0, 0.0, 10.0);
            }
Reply
#3

Obrigado Lуs.
Estarei testando e depois dou Edit.

Obrigado mesmo.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)