Checking if player is near in the water
#4

Hey pig try this:

pawn Код:
stock IsPlayerInWater(playerid)
{
    new lib[16],anim[32];
    GetAnimationName(GetPlayerAnimationIndex(playerid), lib, sizeof(lib), anim, sizeof(anim));
    if(!strcmp(lib, "SWIM", true) && !isnull(lib)) return 1;
    return 0;
}
You don't have to get all water coordinates, just use the swimming animation.
Reply


Messages In This Thread
Checking if player is near in the water - by JaKe Elite - 01.12.2012, 08:56
Re: Checking if player is near in the water - by dr.lozer - 01.12.2012, 08:58
Re: Checking if player is near in the water - by JaKe Elite - 01.12.2012, 09:02
Re: Checking if player is near in the water - by Face9000 - 01.12.2012, 09:33
Re: Checking if player is near in the water - by JaKe Elite - 01.12.2012, 09:37
Re: Checking if player is near in the water - by Face9000 - 01.12.2012, 09:39

Forum Jump:


Users browsing this thread: 1 Guest(s)