Raised This Month: $ Target: $400
 0% 

How to strip the weapons of all and give a knife?


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
xPaw
Retired AMX Mod X Moderator
Join Date: Jul 2008
Old 04-10-2009 , 11:32   Re: How to strip the weapons of all and give a knife?
Reply With Quote #1

you wanna stip guns even if user is not connected? no way

PHP Code:
for(new id 1id <= g_maxplayersid++)
        if( 
is_user_aliveid ) )
                
fm_strip_user_weaponsid ); 
-- Edit:
If you dont want loop, you could try this (not sure what it will work)
PHP Code:
stock fm_strip_weapons( ) {
    new 
iEntity engfunc(EngFunc_CreateNamedEntityengfunc(EngFunc_AllocString"player_weaponstrip"));
    
    if( !
pev_validiEntity ) )
        return 
0;
    
    
dllfuncDLLFunc_SpawniEntity );
    
dllfuncDLLFunc_UseiEntity);
    
engfuncEngFunc_RemoveEntityiEntity );
    
    return 
1;

__________________

Last edited by xPaw; 04-10-2009 at 11:36.
xPaw is offline
Reply



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 02:26.


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