Disable weapon effect?

pawn Код:
//Other code here
if ( issuerid != INVALID_PLAYER_ID )
        if ( GetPlayerWeapon( issuerid ) == 23 )
            new string[50], Attacker[MAX_PLAYER_NAME], pzName[MAX_PLAYER_NAME];
            GetPlayerName( issuerid, Attacker, sizeof(Attacker) );
            GetPlayerName( playerid, pzName, MAX_PLAYER_NAME );
            format( string, sizeof(string), "(INFO) Officer %s has tazed you.", Attacker );
            SendClientMessage( playerid, COLOR_GOLD, string );
            format( string, sizeof(string), "(INFO) You have tazed %s.", pzName );
            SendClientMessage( issuerid, COLOR_GOLD, string );
            TogglePlayerControllable( playerid, 0 );
This is my tazer system. But the silenced pistol still "remove" health to the issued. I would like it can taze but it has no effect to the player/car health...Just TogglePlayerControllable...

Try adding this to "OnPlayerTakeDamage"


new Float:HP;
GetPlayerHealth(playerid, HP);
if(weaponid == 23) SetPlayerHealth(playerid, HP-0);//SilencedColt
return 1;

Not 100% sure if it works, but it's worth a try

Forum Jump:

Users browsing this thread: 1 Guest(s)