Injury System like LS:RP
#5

Your system is flawed. I imagine it doesn't work either with melee weapons OR fists?

Unless you've got it setup under take/give dmg for other weapons.

Anyway, just use OnPlayerTakeDamage. There's no plausible way of doing it with OnPlayerWeaponShot FOR players in a vehicle.

PHP код:
public OnPlayerTakeDamage(playerid, .. )
{
     if(
IsPlayerInAnyVehicle(playerid)){
         if(
health 50 && GetPVarInt(hitid"Dead") == 0)
           {
             
SetPlayerHealth(hitid50);
            
SetTimerEx("Wounded"00"ii"playeridhitid);
           }
     }
}
return 
true;

BULLET_HIT_TYPE_PLAYER doesn't work if a player is inside a vehicle.
Reply


Messages In This Thread
Injury System like LS:RP - by valelele - 22.06.2017, 00:20
Re: Injury System like LS:RP - by JasonRiggs - 22.06.2017, 00:48
Re: Injury System like LS:RP - by valelele - 22.06.2017, 01:09
Re: Injury System like LS:RP - by Rocket16 - 22.06.2017, 01:24
Re: Injury System like LS:RP - by Kane - 22.06.2017, 01:26

Forum Jump:


Users browsing this thread: 2 Guest(s)