OnPlayerGiveDamageActor don't work
#1

Код:
CMD:actor(playerid)
{
        new Float:pos[3];
        GetPlayerPos(playerid, pos[0], pos[1], pos[2]);
	Actor[playerid] = CreateActor(28, pos[0], pos[1], pos[2], 0.0);
	SetActorInvulnerable(Actor[playerid], false);
        SetActorHealth(Actor[playerid], 100);
return 1;
}

public OnPlayerGiveDamageActor(playerid, damaged_actorid, Float: amount, weaponid, bodypart)
{
    new string[128], attacker[MAX_PLAYER_NAME];
    new weaponname[24];
    GetPlayerName(playerid, attacker, sizeof (attacker));
    GetWeaponName(weaponid, weaponname, sizeof (weaponname));

    format(string, sizeof(string), "%s has made %.0f damage to actor id %d, weapon: %s", attacker, amount, damaged_actorid, weaponname);
    SendClientMessageToAll(0xFFFFFFFF, string);
    return 1;
}
nothing happens when I shoot or punch actor
Reply


Messages In This Thread
OnPlayerGiveDamageActor don't work - by ax1 - 07.05.2016, 14:56
Re: OnPlayerGiveDamageActor don't work - by Sew_Sumi - 07.05.2016, 15:28
Re: OnPlayerGiveDamageActor don't work - by ax1 - 07.05.2016, 15:49
Re: OnPlayerGiveDamageActor don't work - by Sew_Sumi - 07.05.2016, 15:50
Re: OnPlayerGiveDamageActor don't work - by Dayrion - 07.05.2016, 16:15
Re: OnPlayerGiveDamageActor don't work - by ax1 - 07.05.2016, 16:52
Re: OnPlayerGiveDamageActor don't work - by Sew_Sumi - 07.05.2016, 17:11

Forum Jump:


Users browsing this thread: 2 Guest(s)