Event shot with a specific weapon
how to register the event of shot with a specific weapon?
|
Re: Event shot with a specific weapon
RegisterHam(Ham_Weapon_PrimaryAttack, "weapon_weaponname", "Forward_WeaponAttack").
Replace "weapon_weaponname" with the weapon_* names(i.e: weapon_deagle). |
Re: Event shot with a specific weapon
Quote:
|
Re: Event shot with a specific weapon
You can also use CurWeapon event and to filter it, or use VEN's method to catch weapons shot : http://forums.alliedmods.net/showthread.php?t=54887
|
Re: Event shot with a specific weapon
and as i to determine the attacker and the victim?
|
Re: Event shot with a specific weapon
The method you have to choose depend on if you want to catch all shots, or if you only want to catch shots that hit a player.
|
Re: Event shot with a specific weapon
what i want to make an item extra that the buy it, he gives you a awp and shoot infecting the victim
please don't do all the plugin :D |
Re: Event shot with a specific weapon
I would use Ham_TraceAttack, register it with classname "player", then if bitdamage is DMG_BULLET, then check if idattacker is between 1 and maxplayers, and then if attacker weapon is your custom infecting weapon.
Code:
/** |
Re: Event shot with a specific weapon
i am means noob in this. can you explain how to use with an example?
|
Re: Event shot with a specific weapon
PHP Code:
|
| All times are GMT -4. The time now is 09:03. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.