24.08.2016, 22:48
Hello guys i made the derby system but when the player get in the water he didn't die why?
stock IsPlayerInWater(playerid)
{
new animlib[32],tmp[32];
GetAnimationName(GetPlayerAnimationIndex(playerid),animlib,32,tmp,32);
if(!strcmp(animlib, "SWIM") && !IsPlayerInAnyVehicle(playerid) ) return true;
return false;
}
if(IsPlayerInWater(playerid))
{
SetPlayerHealth(playerid,0.0);
}