[Ajuda] /comprarvip nгo salva o vip
#1

Slc preciso da ajuda de vocкs jб tentei de tudo...

tipo o /comprarvip nгo salva e o /darvip salva...

acho que й pq no final do /darvip tem os comandos de salvar e eu ja tentei por no /comprarvip mas eu nгo manjo mto pff pessoal alguem me ajuda a funcionar o salvamento do vip...


PHP код:
if(strcmp(cmd"/comprarvip"true) == 0)
{
    if(
IsPlayerConnected(playerid))
    {
        
tmp strtok(cmdtextidx);
        if(!
strlen(tmp))
        {
            
SendClientMessage(playeridCOLOR_WHITE"USE: /comprarvip [Numero do VIP]");
            
SendClientMessage(playeridCOLOR_WHITE"|____[Atenзгo vip dura apenas 1 mкs]______________");
            
SendClientMessage(playeridCOLOR_GRAD1"| Vip normal        Vip Premium        Vip Socio");
            
SendClientMessage(playeridCOLOR_GRAD2"| 50 Cash           100 Cash            175 Cash");
            return 
1;
        }
        
VipVaga();
        if(
VagaSobrando == 0)
        {
            
SendClientMessage(playeridCOLOR_GRAD1"Opб amigo, ta lotado os vip Sorry...");
            return 
1;
        }
        new 
item strval(tmp);
        if (
item == && PlayerInfo[playerid][pCash1] > 50)
        {
            
GranaRockstar(playerid,5000000);
            
PlayerInfo[playerid][pCash1] -= 50;
            
PlayerPlaySound(playerid10840.00.00.0);
            
PlayerInfo[playerid][pVIP] = 1;//teste
            //
            
getdate(yearmonthday);
            
gettime(hour,minute,second);
            
PlayerInfo[playerid][pVIP] = 1;
            new 
Anov,Mesv,Diav,Horav,Minutov,SegV;
            
getdate(AnovMesvDiav);
            
gettime(HoravMinutovSegV);
            if(
Mesv == 12 && Anov == 2012) { Mesv 1Anov++;} else { Mesv++; }
            
//
            
format(gstringsizeof(gstring), "** Seu Vip Termina Dia %d/%d/%d, Hora %d:%d:%d!"Diav,Mesv,Anov,Horav,Minutov,SegV);
            
SendClientMessage(playerid0x77EEA1FFgstring);
            
SendClientMessage(playerid0x95FFDFAA,"** Conta Vip Normal Ativada, Obrigado por nos Ajudar, Bom Jogo!");
               
SalvarPlayer(playerid);
            
SaveVip();
        }
        else if (
item == && PlayerInfo[playerid][pCash1] > 100)
        {
            
GranaRockstar(playerid10000000);
            
PlayerInfo[playerid][pCash1] -= 100;
            
PlayerInfo[playerid][pVIP] = 2;//teste
            //
            
getdate(yearmonthday);
            
gettime(hour,minute,second);
            
PlayerInfo[playerid][pVIP] = 2;
            new 
Anov,Mesv,Diav,Horav,Minutov,SegV;
            
getdate(AnovMesvDiav);
            
gettime(HoravMinutovSegV);
            if(
Mesv == 12 && Anov == 2012) { Mesv 1Anov++;} else { Mesv++; }
            
//
            
PlayerPlaySound(playerid10840.00.00.0);
            
format(gstringsizeof(gstring), "** Seu Vip Termina Dia %d/%d/%d, Hora %d:%d:%d!"Diav,Mesv,Anov,Horav,Minutov,SegV);
            
SendClientMessage(playerid0x77EEA1FFgstring);
            
SendClientMessage(playerid0x95FFDFAA,"** Conta Vip Premium Ativada, Obrigado por nos Ajudar, Bom Jogo!");
              
SalvarPlayer(playerid);
            
SaveVip();
            return 
1;
        }
        else if (
item == && PlayerInfo[playerid][pCash1] > 175)
        {
            
GranaRockstar(playerid,20000000);
            
PlayerInfo[playerid][pCash1] -= 175;
            
PlayerInfo[playerid][pVIP] = 3;//teste
            //
            
getdate(yearmonthday);
            
gettime(hour,minute,second);
            
PlayerInfo[playerid][pVIP] = 3;
            new 
Anov,Mesv,Diav,Horav,Minutov,SegV;
            
getdate(AnovMesvDiav);
            
gettime(HoravMinutovSegV);
            if(
Mesv == 12 && Anov == 2012) { Mesv 1Anov++;} else { Mesv++; }
            
//
            
PlayerPlaySound(playerid10840.00.00.0);
            
format(gstringsizeof(gstring), "** Seu Vip Termina Dia %d/%d/%d, Hora %d:%d:%d!"day,Mesv,Anov,Horav,Minutov,SegV);
            
SendClientMessage(playerid0x77EEA1FFgstring);
            
SendClientMessage(playerid0x95FFDFAA,"** Conta Vip Sуcio Ativada, Obrigado por nos Ajudar, Bom Jogo!");
              
SalvarPlayer(playerid);
            
SaveVip();
            return 
1;
        }
        else
        {
            
SendClientMessage(playeridCOLOR_GREY"   Vocк nгo tem Cash.");
        }
    }
    return 
1;

/darvip

PHP код:
    if(strcmp(cmd"/darvip"true) == 0)
    {
        if(
IsPlayerConnected(playerid))
        {
            if(
PlayerInfo[playerid][pAdmin] < 3000)
            {
                
SendClientMessage(playeridCOLOR_GRAD1"Vocк nгo tem autorizaзгo para usar esse comando.");
                return 
1;
            }
            
VipVaga();
            if(
VagaSobrando == 0)
            {
                
SendClientMessage(playeridCOLOR_GRAD1"Nгo hб mais vagas na lista use /limparvip primeiro.");
                return 
1;
            }
            
tmp strtok(cmdtextidx);
            if(!
strlen(tmp))
            {
                
SendClientMessage(playeridCOLOR_GRAD2"USE: /darvip [id] [Nivel]");
                return 
1;
            }
            new 
para1;
            new 
level;
            
para1 ReturnUser(tmp);
            
tmp strtok(cmdtextidx);
            if(!
strlen(tmp))
            {
                
SendClientMessage(playeridCOLOR_GRAD2"USE: /darvip [id] [Nivel]");
                return 
1;
            }
            
level strval(tmp);
            
GetPlayerName(para1giveplayersizeof(giveplayer));
            
GetPlayerName(playeridsendernamesizeof(sendername));
            if(
IsPlayerConnected(para1))
            {
                if(
para1 != INVALID_PLAYER_ID)
                {
                    
format(stringsizeof string"Vocк deu VIP Nнvel %d para %s"levelgiveplayer);
                    
SendClientMessage(playeridCOLOR_LIGHTBLUEstring);
                    
getdate(yearmonthday);
                    
gettime(hour,minute,second);
                    
PlayerInfo[para1][pVIP] = level;
                    new 
var03 0;
                    new 
Anov,Mesv,Diav,Horav,Minutov,SegV;
                    
getdate(AnovMesvDiav);
                    
gettime(HoravMinutovSegV);
                    if(
Mesv == 12 && Anov == 2012) { Mesv 1Anov++;} else { Mesv++; }
                    if(
level == 1)
                    {
                        new 
VipGrana 5000000;
                        new 
VipNivel 2;
                        
/*format(gstring, sizeof(gstring), "VipInfo: {80E3FF}%s {E84F33} Recebeu R$ %d de Dinheiro na Conta do Banco.",PlayerName(para1) ,VipGrana);
                        SendClientMessage(COLOR_LIGHTRED,gstring);
                        format(gstring, sizeof(gstring), "VipInfo: {80E3FF}%s {E84F33} Recebeu mais %d de Nivel em Sua Conta.",PlayerName(para1) ,VipGrana);
                        SendClientMessage(COLOR_LIGHTRED,gstring); */
                        //SendClientMessage(playerid, 0x80FF80AA,"***.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•[ {0080FF}Brasil Sabotage RPG Recebimento Vip{80FF80} ]•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•***");
                        
PlayerPlaySound(para110840.00.00.0);
                        
SendClientMessage(para10x95FFDFAA,"**~~*~*~*~*~*~*~*|{00FF00}B{FFD700}.S.{1E90FF}R{95FFDF}| Liberaзгo de Vantagens Vips |{00FF00}B{FFD700}.S.{1E90FF}R{95FFDF}|*~*~*~*~*~*~*~~**");
                        
PlayerInfo[para1][pConta] += VipGrana;
                        
PlayerInfo[para1][pLevel] += VipNivel;
                        
format(stringsizeof string"Vocк ganhou VIP Nнvel %d do admin %s"levelsendername);
                        
SendClientMessage(para1COLOR_LIGHTBLUEstring);
                        
format(gstringsizeof(gstring), "** Vocк Recebeu R$ %d na conta do Banco!"VipGrana);
                        
SendClientMessage(para1COLOR_LIGHTBLUEgstring);
                        
format(gstringsizeof(gstring), "** Vocк Recebeu mais %d de Nivel Em Sua conta!"VipNivel);
                        
SendClientMessage(para1COLOR_LIGHTBLUEgstring);
                        
format(gstringsizeof(gstring), "** Seu Vip Termina Dia %d/%d/%d, Hora %d:%d:%d!"Diav,Mesv,Anov,Horav,Minutov,SegV);
                        
SendClientMessage(para10x77EEA1FFgstring);
                        
SendClientMessage(para10x95FFDFAA,"** Conta Vip Normal Ativada, Obrigado por nos Ajudar, Bom Jogo!");
                    }
                    else if(
level == 2)
                    {
                        new 
VipGrana 10000000;
                        new 
VipNivel 4;
                        
/*format(gstring, sizeof(gstring), "VipInfo: {80E3FF}%s {E84F33} Recebeu R$ %d de Dinheiro na Conta do Banco.",PlayerName(para1) ,VipGrana);
                        ABroadCast(COLOR_LIGHTRED,gstring,1);
                        format(gstring, sizeof(gstring), "VipInfo: {80E3FF}%s {E84F33} Recebeu mais %d de Nivel em Sua Conta.",PlayerName(para1) ,VipGrana);
                        ABroadCast(COLOR_LIGHTRED,gstring,1);*/
                        //SendClientMessage(playerid, 0x80FF80AA,"***.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•[ {0080FF}Brasil Sabotage RPG Recebimento Vip{80FF80} ]•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•***");
                        
PlayerPlaySound(para110840.00.00.0);
                        
SendClientMessage(para10x95FFDFAA,"**~~*~*~*~*~*~*~*|{00FF00}B{FFD700}.S.{1E90FF}R{95FFDF}| Liberaзгo de Vantagens Vips |{00FF00}B{FFD700}.S.{1E90FF}R{95FFDF}|*~*~*~*~*~*~*~~**");
                        
format(stringsizeof string"Vocк ganhou VIP Nнvel %d do admin %s"levelsendername);
                        
SendClientMessage(para1COLOR_LIGHTBLUEstring);
                        
PlayerInfo[para1][pConta] += VipGrana;
                        
PlayerInfo[para1][pLevel] += VipNivel;
                        
format(gstringsizeof(gstring), "** Vocк Recebeu R$ %d na conta do Banco!"VipGrana);
                        
SendClientMessage(para1COLOR_LIGHTBLUEgstring);
                        
format(gstringsizeof(gstring), "** Vocк Recebeu mais %d de Nivel Em Sua conta!"VipNivel);
                        
SendClientMessage(para1COLOR_LIGHTBLUEgstring);
                        
format(gstringsizeof(gstring), "** Seu Vip Termina Dia %d/%d/%d, Hora %d:%d:%d!"Diav,Mesv,Anov,Horav,Minutov,SegV);
                        
SendClientMessage(para10x77EEA1FFgstring);
                        
SendClientMessage(para10x95FFDFAA,"** Conta Vip Premium Ativada, Obrigado por nos Ajudar, Bom Jogo!");
                    }
                    else if(
level == 3)
                    {
                        new 
VipGrana 20000000;
                        new 
VipNivel 6;
                        
/*format(gstring, sizeof(gstring), "VipInfo: {80E3FF}%s {E84F33} Recebeu R$ %d de Dinheiro na Conta do Banco.",PlayerName(para1) ,VipGrana);
                        ABroadCast(COLOR_LIGHTRED,gstring,1);
                        format(gstring, sizeof(gstring), "VipInfo: {80E3FF}%s {E84F33} Recebeu mais %d de Nivel em Sua Conta.",PlayerName(para1) ,VipGrana);
                        ABroadCast(COLOR_LIGHTRED,gstring,1);*/
                        //SendClientMessage(playerid, 0x80FF80AA,"***.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•[ {0080FF}Brasil Sabotage RPG Recebimento Vip{80FF80} ]•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•.•***");
                        
PlayerPlaySound(para110840.00.00.0);
                        
SendClientMessage(para10x95FFDFAA,"**~~*~*~*~*~*~*~*|{00FF00}B{FFD700}.S.{1E90FF}R{95FFDF}| Liberaзгo de Vantagens Vips |{00FF00}B{FFD700}.S.{1E90FF}R{95FFDF}|*~*~*~*~*~*~*~~**");
                        
format(stringsizeof string"Vocк ganhou VIP Nнvel %d do admin %s"levelsendername);
                        
SendClientMessage(para1COLOR_LIGHTBLUEstring);
                        
PlayerInfo[para1][pConta] += VipGrana;
                        
PlayerInfo[para1][pLevel] += VipNivel;
                        
format(gstringsizeof(gstring), "** Vocк Recebeu R$ %d na conta do Banco!"VipGrana);
                        
SendClientMessage(para1COLOR_LIGHTBLUEgstring);
                        
format(gstringsizeof(gstring), "** Vocк Recebeu mais %d de Nivel Em Sua conta!"VipNivel);
                        
SendClientMessage(para1COLOR_LIGHTBLUEgstring);
                        
format(gstringsizeof(gstring), "** Seu Vip Termina Dia %d/%d/%d, Hora %d:%d:%d!"Diav,Mesv,Anov,Horav,Minutov,SegV);
                        
SendClientMessage(para10x77EEA1FFgstring);
                        
SendClientMessage(para10x95FFDFAA,"** Conta Vip Sуcio Ativada, Obrigado por nos Ajudar, Bom Jogo!");
                    }
                    
ScoreLevel(para1);
                    for(new 
0sizeof(VipInfo); i++)
                    {
                        if(
strcmp(PlayerName(para1),VipInfo[i][vNick],true)==0)
                        {
                            
VipInfo[i][vDia] = Diav;
                            
VipInfo[i][vMes] = Mesv;
                            
VipInfo[i][vAno] = Anov;
                            
VipInfo[i][vHora] = Horav;
                            
VipInfo[i][vMinuto] = Minutov;
                            
VipInfo[i][vSegundo] = SegV;
                            
SaveVip();
                            
var03 1;
                            break;
                        }
                    }
                    if(
var03 == 0)
                    {
                        for(new 
0sizeof(VipInfo); i++)
                        {
                            if(
strcmp("Ninguem",VipInfo[i][vNick],true)==0)
                            {
                                
strmid(VipInfo[i][vNick], PlayerName(para1), 0strlen(PlayerName(para1)), 255);
                                
VipInfo[i][vDia] = Diav;
                                
VipInfo[i][vMes] = Mesv;
                                
VipInfo[i][vAno] = Anov;
                                
VipInfo[i][vHora] = Horav;
                                
VipInfo[i][vMinuto] = Minutov;
                                
VipInfo[i][vSegundo] = SegV;
                                break;
                            }
                        }
                    }
                    
SalvarPlayer(para1);
                    
SaveVip();
                }
            }
        }
        return 
1;
    } 
Reply


Messages In This Thread
/comprarvip nгo salva o vip - by zGuigui2068 - 24.03.2016, 00:00
Re: /comprarvip nгo salva o vip - by F1N4L - 24.03.2016, 01:29
Re: /comprarvip nгo salva o vip - by ApocaSamp - 24.03.2016, 04:55
Re: /comprarvip nгo salva o vip - by zGuigui2068 - 24.03.2016, 15:45

Forum Jump:


Users browsing this thread: 2 Guest(s)