OnPlayerTakeDmg not caling animacion ?
#1

When i do this :

pawn Код:
public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid)
{

ApplyAnimation(playerid,"BEACH", "ParkSit_M_loop", 4.0, 1, 0, 0, 0, 0); // Sit
return 1;
}
Animacion is never called ? Why ?
Reply
#2

pawn Код:
public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid)
{
    if(issuerid != INVALID_PLAYER_ID)
    {
    ApplyAnimation(playerid,"BEACH", "ParkSit_M_loop", 4.0, 1, 0, 0, 0, 0); // Sit
    }
    return 1;
}
Reply
#3

Quote:
Originally Posted by DaRk_RaiN
Посмотреть сообщение
pawn Код:
public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid)
{
    if(issuerid != INVALID_PLAYER_ID)
    {
    ApplyAnimation(playerid,"BEACH", "ParkSit_M_loop", 4.0, 1, 0, 0, 0, 0); // Sit
    }
    return 1;
}
Still same player just take kick and stand not sit?
Reply
#4

Make sure the anim is valid...
Reply
#5

While taking damage, the player's animation might get destroyed. Try running a timer like this:
pawn Код:
public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid)
{
    if(issuerid != INVALID_PLAYER_ID)
    {
      SetTimerEx("Applyanim_OPTD", 500, false, "d", playerid);
    }
    return 1;
}

forward Applyanim_OPTD(playerid);
public Applyanim_OPTD(playerid)
{
    ApplyAnimation(playerid,"BEACH", "ParkSit_M_loop", 4.0, 1, 0, 0, 0, 0); // Sit
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)