Destroy a brassknuckle?
#1

I can't destroy that brassknuckle xD I tried with SetPlayerAmmo but it's not working lol
I don't want to ResetPlayerWeapons because I want to remove only the brassknuckle lol
Reply
#2

Quote:
Originally Posted by Lirbo
Посмотреть сообщение
I can't destroy that brassknuckle xD I tried with SetPlayerAmmo but it's not working lol
I don't want to ResetPlayerWeapons because I want to remove only the brassknuckle lol
Put this at the botom of the script:

PHP код:
stock RemovePlayerWeapon(playeridweaponid)
{
    new 
plyWeapons[12];
    new 
plyAmmo[12];
    for(new 
slot 0slot != 12slot++)
    {
        new 
wepammo;
        
GetPlayerWeaponData(playeridslotwepammo);
        if(
wep != weaponid)
        {
            
GetPlayerWeaponData(playeridslotplyWeapons[slot], plyAmmo[slot]);
        }
    }
    
ResetPlayerWeapons(playerid);
    for(new 
slot 0slot != 12slot++)
    {
        
GivePlayerWeapon(playeridplyWeapons[slot], plyAmmo[slot]);
    }

And this in the command:

PHP код:
RemovePlayerWeapon(playerid1); 
Reply
#3

Quote:
Originally Posted by Mouiz
Посмотреть сообщение
Put this at the botom of the script:

PHP код:
stock RemovePlayerWeapon(playeridweaponid)
{
    new 
plyWeapons[12];
    new 
plyAmmo[12];
    for(new 
slot 0slot != 12slot++)
    {
        new 
wepammo;
        
GetPlayerWeaponData(playeridslotwepammo);
        if(
wep != weaponid)
        {
            
GetPlayerWeaponData(playeridslotplyWeapons[slot], plyAmmo[slot]);
        }
    }
    
ResetPlayerWeapons(playerid);
    for(new 
slot 0slot != 12slot++)
    {
        
GivePlayerWeapon(playeridplyWeapons[slot], plyAmmo[slot]);
    }

And this in the command:

PHP код:
RemovePlayerWeapon(playerid1); 
Ty mate
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)