[L4D2]Exclude projectiles that have been thrown
Is there a better way to get the player's weapon without throwing projectiles?
The method currently in use PHP Code:
|
Re: [L4D2]Exclude projectiles that have been thrown
|
Re: [L4D2]Exclude projectiles that have been thrown
Quote:
|
Re: [L4D2]Exclude projectiles that have been thrown
...awful code.
Anyway, you do know, projectiles are "used" grenades or missiles? Example, player carry weapon_smokegrenade. Player throw weapon_smokegrenade, weapon_smokegrenade get destroyed and smokegrenade_projectile appear, flying object in world. Then projectile get destroyed after few secongs after that throw. If you want look player weapons, there few way: -Loop to look all player weapon slots. - Look player array, "m_hMyWeapons" and perhaps current weapon in hands "m_hMyWeapons" My favourite. - Or harder way, loop all weapon entities from world by FindEntityByClassName, look m_hOwner... Then look ammo and clip amount. From client "m_iAmmo" array, from weapon "m_iClip1" Here example plugin about auto reload weapon, if you like check. https://forums.alliedmods.net/showpo...38&postcount=3 |
Re: [L4D2]Exclude projectiles that have been thrown
Detect projectiles that have been thrown.
PHP Code:
use Exploit Fix - Unlimited Grenades by Silvers. Silvers instantly removes player's slot 2 throwable item when player throws a projectile PHP Code:
|
Re: [L4D2]Exclude projectiles that have been thrown
Quote:
|
Re: [L4D2]Exclude projectiles that have been thrown
Found more efficient way today, thanks to Forgetest
PHP Code:
|
All times are GMT -4. The time now is 08:44. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.