Suppressor System
#8

PHP код:
new HasSupp[MAX_PLAYERS]; // on top of the script.
OnPlayerConnect(playerid)
{
    
HasSupp[playerid] = 0;
    return 
1;
}
OnPlayerDisconnect(playerid)
{
    
HasSupp[playerid] = 0;
    return 
1;
}
CMD:suppressor(playeridparams[])
{
    
SendClientMessage(playeridCOLOR_AQUA"You have been given a suppressor");
    
HasSupp[playerid] = 1;
    return 
1;
}
CMD:attachsupp(playeridparams[])
{
    if(
HasSupp[playerid] == 0) return SendClientMessage(playeridCOLOR_AQUA"You don't have a suppressor");
    if(
GetPlayerWeapon(playerid) == 22)
    {
        
GivePlayerWeapon(playerid23100);
        
GivePlayerWeapon(playerid220);
     }
     
SendClientMessage(playeridCOLOR_AQUA"Attached the suppressor!");
     else {
     
SendClientMessage(playeridCOLOR_AQUA"You don't have a colt 45"); }
     return 
1;

Reply


Messages In This Thread
Suppressor System - by Mo123 - 27.05.2018, 16:15
Re: Suppressor System - by Mugala - 28.05.2018, 00:33
Re: Suppressor System - by Mo123 - 28.05.2018, 16:13
Re: Suppressor System - by David (Sabljak) - 28.05.2018, 16:17
Re: Suppressor System - by Mo123 - 28.05.2018, 16:20
Re: Suppressor System - by Lokii - 28.05.2018, 17:30
Re: Suppressor System - by Mo123 - 28.05.2018, 21:04
Re: Suppressor System - by Exhibit - 28.05.2018, 22:46

Forum Jump:


Users browsing this thread: 2 Guest(s)