View Single Post
eXtrem
Member
Join Date: Jul 2011
Old 08-01-2011 , 05:18   Re: Mortal Headshot v0.0.1
Reply With Quote #8

Quote:
Originally Posted by ConnorMcLeod View Post
PHP Code:
        if( equalszWeapon "weapon_smokegrenade" ) || equalszWeapon "weapon_flashbang" ) || equalszWeapon "weapon_hegrenade" ) , equalszWeapon "weapon_c4" ) )
        {
            return 
PLUGIN_HANDLED
        

This is useless, if you really want to check, then check weaponid it is faster.
No check result in the array to be filled, it's not really a problem.


For victim check, you register the ham forward with classname "player", so victim can't be any other entity than a player, that's why the check is useless.
Ok, fixed. I have checked with weaponid.

Quote:
Originally Posted by Arkshine View Post
He says just the check if victim is a player or not is pointless since your register the forward with "player" and the victim can be only a player anyway.
I didn't understand that, sorry.
eXtrem is offline