[Ajuda] Compra Armas Bugado
#10

Quote:
Originally Posted by FabioStralioti
Посмотреть сообщение
Manda esses dois cуdigos
PHP код:
 #define DIALOG_COMPRARARMAS
#define PLAYER_STATE_DRIVER 
STATE_DRIVER COMPLETA
PHP код:
    if ( newstate == PLAYER_STATE_DRIVER || newstate == PLAYER_STATE_PASSENGER)
    {
        
ShowPlayerVelocimetro(playerid) ;
    }
    else
     {
        
HidePlayerVelocimetro(playerid) ;
    }
    if(
Player[playerid][pMTX] == 1)
    {
        if(
newstate == PLAYER_STATE_DRIVER || newstate == PLAYER_STATE_PASSENGER)
         {
              if(
IsABike(GetPlayerVehicleID(playerid)))
            {
                 switch(
GetPlayerSkin(playerid))
                   {
                 
#define NOIX2{%0,%1,%2,%3,%4,%5} SetPlayerAttachedObject(playerid, SLOT, 18976, 2, (%0), (%1), (%2), (%3), (%4), (%5));
                
case 06574149208273:  NOIX2{0.0700000.0000000.00000088.00000075.0000000.000000}
                case 
1..6814162227293341..4982..848687119289NOIX2{0.0700000.0000000.00000088.00000077.0000000.000000}
                case 
710NOIX2{0.0900000.0199990.00000088.00000090.0000000.000000}
                case 
9NOIX2{0.0599990.0199990.00000088.00000090.0000000.000000}
                case 
11..13NOIX2{0.0700000.0199990.00000088.00000090.0000000.000000}
                case 
15NOIX2{0.0599990.0000000.00000088.00000082.0000000.000000}
                case 
17..21NOIX2{0.0599990.0199990.00000088.00000082.0000000.000000}
                case 
23..262830..3234..3957589899104..118120..131NOIX2{0.0799990.0199990.00000088.00000082.0000000.000000}
                case 
40NOIX2{0.0500000.0099990.00000088.00000082.0000000.000000}
                case 
50100..103148150..189222NOIX2{0.0700000.0099990.00000088.00000082.0000000.000000}
                case 
51..54NOIX2{0.1000000.0099990.00000088.00000082.0000000.000000}
                case 
5556636466..73757678..81133..143147190..207209..219221247..272274..288290..293NOIX2{0.0700000.0199990.00000088.00000082.0000000.000000}
                case 
59..62NOIX2{0.0799990.0299990.00000088.00000082.0000000.000000}
                case 
77NOIX2{0.0599990.0199990.00000087.00000082.0000000.000000}
                case 
858889NOIX2{0.0700000.0399990.00000088.00000082.0000000.000000}
                case 
90..97NOIX2{0.0500000.0199990.00000088.00000082.0000000.000000}
                case 
132NOIX2{0.0000000.0199990.00000088.00000082.0000000.000000}
                case 
144..146NOIX2{0.0900000.0000000.00000088.00000082.0000000.000000}
                case 
220NOIX2{0.0299990.0199990.00000088.00000082.0000000.000000}
                case 
223246NOIX2{0.0700000.0500000.00000088.00000082.0000000.000000}
                case 
224..245NOIX2{0.0700000.0299990.00000088.00000082.0000000.000000}
                case 
294NOIX2{0.0700000.0199990.00000091.00000084.0000000.000000}
                case 
295NOIX2{0.0500000.0199980.00000086.00000082.0000000.000000}
                case 
296..298NOIX2{0.0649990.0099990.00000088.00000082.0000000.000000}
                case 
299NOIX2{0.0649980.0199990.00000088.00000082.0000000.000000}
                }
               }
        }
        else
        {
        
RemovePlayerAttachedObject(playeridSLOT);
        }
    }
    if(
newstate == PLAYER_STATE_DRIVER)
    {
        
SCM(playeridCOR_ROXO"[INFO] Para ver todos os comandos em relaзгo ao veнculo, digite /meuveh!");
    }
    if(
newstate == PLAYER_STATE_DRIVER)
    {
        if(
Privados(GetPlayerVehicleID(playerid)))
        {
            if(
Player[playerid][pPMRJ] >= || Player[playerid][pPCRJ] >= || Player[playerid][pReporterLS] >= 1)
            {
            }
            else
            {
                
RemovePlayerFromVehicle(playerid);
                   
SCM(playeridCOR_ERRO"[ERRO] Vocк nгo pode pegar esse veнculo!");
            }
        }
    }
     if(
newstate == PLAYER_STATE_DRIVER)
    {
        if(
VeiculosMTX(GetPlayerVehicleID(playerid)))
        {
             if(
Player[playerid][pMTX] < 1)
            {
                new 
Float:Pos[3];
                
GetPlayerPos(playeridPos[0], Pos[1], Pos[2]);
                
SetPlayerPos(playeridPos[0], Pos[1], Pos[2]+1);
                   
SCM(playeridCOR_ERRO"[ERRO] Moto exclusiva para Moto Tбxis!");
            }
        }
     }
     if(
newstate == PLAYER_STATE_DRIVER)
    {
        if(
VeiculosGM(GetPlayerVehicleID(playerid)))
        {
             if(
Player[playerid][pAdmin] < 5)
            {
                new 
Float:Pos[3];
                
GetPlayerPos(playeridPos[0], Pos[1], Pos[2]);
                
SetPlayerPos(playeridPos[0], Pos[1], Pos[2]+1);
                   
SCM(playeridCOR_ERRO"[ERRO] Veнculo exclusivo para Game-Master!");
            }
        }
     }
     
     if(
newstate == PLAYER_STATE_DRIVER)
    {
        if(
VeiculosHelper(GetPlayerVehicleID(playerid)))
        {
             if(
Player[playerid][pHelper] < 1)
            {
                new 
Float:Pos[3];
                
GetPlayerPos(playeridPos[0], Pos[1], Pos[2]);
                
SetPlayerPos(playeridPos[0], Pos[1], Pos[2]+1);
                   
SCM(playeridCOR_ERRO"[ERRO] Veнculo exclusivo para Helpers!");
            }
        }
     }
    if(
newstate == PLAYER_STATE_DRIVER)
    {
        if(
VeiculosVIP(GetPlayerVehicleID(playerid)))
        {
             if(
Player[playerid][pVIP] >= 1)
            {
            }
            else
            {
                new 
Float:Pos[3];
                
GetPlayerPos(playeridPos[0], Pos[1], Pos[2]);
                 
SetPlayerPos(playeridPos[0], Pos[1], Pos[2]+1);
                
SCM(playeridCOR_ERRO"[ERRO] Veнculo exclusivo para VIP's!");
            }
        }
    }
    return 
1;
}
stock EVeiculoComMotorista(vehicleid)
{
    for(new 
0MAX_PLAYERSi++)
    {
    if(
IsPlayerInVehicle(ivehicleid) && GetPlayerState(i) == PLAYER_STATE_DRIVER)
    return 
1;
    }
    return 
0;

DIALOG_COMPRAARMAS
PHP код:
if (strcmp("/comprararmas"cmdtexttrue10) == 0)
    {
        
ShowPlayerDialog(playeridDIALOG_COMPRARARMASDIALOG_STYLE_TABLIST_HEADERS"Escolha a Arma Desejada","Armas\tValor\nM4-A1\t$30.000\nMP5\t$25.000\nAK-47\t$50.000\nDeagle\t$15.000","Comprar""Cancelar");
           return 
1;
       }
if(
dialogid == DIALOG_COMPRARARMAS)
    {
        if(!
response) return SCM(playeridVermelho,"[ERRO] Compra Cancelada.");
        {
             if(
listitem == 0)
            {
               if(
Player[playerid][pPresoADM] == || Player[playerid][pPresoSF] == || Player[playerid][pPresoLV] == || Player[playerid][pPresoLS] == || Player[playerid][InHospital] == true || Player[playerid][InHospital] == true || Player[playerid][InDM] == true)
                return 
SCM(playeridCOR_ERRO"[ERRO] Vocк nгo fazer isso!");
              if(
GetPlayerMoney(playerid) < 30000) return SCM(playerid,Vermelho,"[ERRO] Vocк nгo tem dinheiro para comprar esta arma.");
            {
                    
GivePlayerMoney(playerid,-30000);
                    
SCM(playerid,COR_LIGHTBLUE,"Vocк comprou uma M4");
                    
GivePlayerWeapon(playerid,31,3000000);
                }
            }
            if(
listitem == 1)
            {
                if(
GetPlayerMoney(playerid) < 25000) return SCM(playeridVermelho,"[ERRO] Vocк nгo tem dinheiro para comprar estб arma.");
                {
                    
GivePlayerMoney(playerid,-25000);
                    
SCM(playerid,COR_LIGHTBLUE,"Vocк comprou uma MP5");
                    
GivePlayerWeapon(playerid,29,3000000);
                }
            }
            if(
listitem == 2)
            {
                if(
GetPlayerMoney(playerid) < 30000) return SCM(playeridVermelho,"[ERRO] Vocк nгo tem dinheiro para comprar estб arma.");
                {
                       
GivePlayerMoney(playerid,-50000);
                    
SCM(playerid,COR_LIGHTBLUE,"Vocк comprou uma AK-47");
                    
GivePlayerWeapon(playerid,30,3000000);
                }
            }
              if(
listitem == 3)
            {
                if(
GetPlayerMoney(playerid) < 15000) return SCM(playeridVermelho,"[ERRO] Vocк nгo tem dinheiro para comprar estб arma.");
                {
                       
GivePlayerMoney(playerid,-15000);
                    
SCM(playerid,COR_LIGHTBLUE,"Vocк comprou uma Desert Eagle");
                    
GivePlayerWeapon(playerid,24,3000000);
                }
            }
        }
        return 
1;
    } 
Reply


Messages In This Thread
Compra Armas Bugado - by Dimbalada - 18.04.2018, 22:21
Re: Compra Armas Bugado - by AutoMatic2 - 18.04.2018, 22:29
levemente entendi o que tu falou - by RazorGuigo - 18.04.2018, 22:30
Re: Compra Armas Bugado - by AutoMatic2 - 18.04.2018, 22:38
Re: Compra Armas Bugado - by AutoMatic2 - 18.04.2018, 22:41
Re: Compra Armas Bugado - by SpikeCompiler - 18.04.2018, 23:16
Re: Compra Armas Bugado - by Dimbalada - 19.04.2018, 00:59
Re: Compra Armas Bugado - by Dimbalada - 19.04.2018, 01:36
Re: Compra Armas Bugado - by FabioStralioti - 19.04.2018, 03:08
Re: Compra Armas Bugado - by Dimbalada - 20.04.2018, 12:52

Forum Jump:


Users browsing this thread: 2 Guest(s)