Raised This Month: $ Target: $400
 0% 

...


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 12-26-2009 , 13:16   Re: detect user weap
Reply With Quote #5

PHP Code:
new CSW_WHICHiWeaponEntityId
get_user_gun
(idslotCSW_WHICHiWeaponEntityId
PHP Code:
#include <amxmodx>
#include <cstrike>
#include <hamsandwich>

new const m_rgpPlayerItems[MAX_ITEM_TYPES] = {367,368,369,370,371,372}

get_user_gun(idslot, &iCswId, &iEntity)
{
    if( 
is_user_alive(id) )
    {
        if( (
iEntity get_pdata_cbase(idm_rgpPlayerItems[slot])) > )
        {
            
iCswId cs_get_weapon_id(iEntity)
        }
        else
        {
            
iCswId 0
            iEntity 
0
        
}
    }
    else
    {
        
iCswId 0
        iEntity 
0
    
}

__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
 



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 04:03.


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