Raised This Month: $ Target: $400
 0% 

Strip weapons and give new ones w/o bullets


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
kileedyg
BANNED
Join Date: Dec 2008
Location: Lithuania
Old 06-25-2012 , 09:52   Strip weapons and give new ones w/o bullets
Reply With Quote #1

when player respawns from first time when he connected and everytime when he dies on spawn remove for example t and ct glock,usp,and give those w/o bullets


PHP Code:
public client_putinserver(id) {
    
set_task(0.1,"w")
}
 
public 
w(id) {
    if(
is_user_alive(id)) {
    
strip_user_weapons(id)
    new 
W[][] = {"weapon_m3","weapon_xm1014""weapon_mp5navy""weapon_mac10""weapon_p90""weapon_aug""weapon_ump45""weapon_elite""weapon_ak47""weapon_m4a1""weapon_sg552""weapon_sg550""weapon_awp""weapon_scout""weapon_fiveseven""weapon_g3sg1""weapon_m249""weapon_deagle""weapon_glock18""weapon_famas""weapon_galil""weapon_tmp""weapon_usp"};
    const 
sizeOfW sizeof W
    
    
for(new i=0;i<sizeOfW;i++) {
    
give_item(id,W[i])
    }
    for(new 
i=0;i<sizeOfW;i++) {
    new 
WeapEntIndex find_ent_by_owner(-1W[i],id0); 
 
    if(
is_valid_ent(WeapEntIndex)) {
    
cs_set_weapon_ammo(WeapEntIndex0
    }
    }
    } 
    return 
1

kileedyg is offline
Send a message via Skype™ to kileedyg
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 06:18.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode