How to get the unique ID of weapon
In game:
1) Players get (buy or admin give) a weapon. 2) When the weapon is thrown away. 3) The other players pick up this weapon. How can I get this weapon the same ID? |
Re: How to get the unique ID of weapon
|
Re: How to get the unique ID of weapon
cs_get_weapon_id ( index )
What is the index? When a palyer have this weapon : new hid = cs_get_weapon_id ( index ) When this weapon has droped on ground : new gid = cs_get_weapon_id ( index ) When this has pick up by other palyer: new pid = cs_get_weapon_id ( index ) I need: hid == gid == pid I'm sorry for my bad English . |
Re: How to get the unique ID of weapon
Quote:
|
Re: How to get the unique ID of weapon
But it still can not achieve my goal.
Or: When I pick up a weapon, how can I know who is falling for this weapon? |
Re: How to get the unique ID of weapon
Like:
new oid; pev(ent, pev_owner, oid); But it is error . Please help me . |
Re: How to get the unique ID of weapon
To detect weapon pickup, hook Ham_Touch on pre with "armoury_entity" and "weaponbox" entities.
|
| All times are GMT -4. The time now is 00:21. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.