OnPlayerGiveDamageActor
#3

My bad invulnerable is false.
But still not called, I created a debug command which would return actors status and this is what i got

pawn Код:
CMD:checkactor(playerid, params[]) {
    if(IsValidActor(cityActor)) {
        print("created");
        if(IsActorInvulnerable(cityActor)) {
            print("undestroyable");
        }
        else {
            print("destroyable");
        }
    }
    else {
        print("not created");
    }
    return true;
}

// callback

public OnPlayerGiveDamageActor(playerid, damaged_actorid, Float: amount, weaponid, bodypart) {
    printf("callback normal called.");
    if(damaged_actorid == cityActor && IsValidActor(cityActor)) {
        print("actor attached");
    }
    return true;
}

// result

[14:52:13] created
[14:52:13] destroyable
Now the part under OnPlayerGiveDamageActor is still not being called even after I attack actor
Reply


Messages In This Thread
OnPlayerGiveDamageActor - by ShoortyFl - 25.11.2017, 12:32
Re: OnPlayerGiveDamageActor - by MEW273 - 25.11.2017, 12:43
Re: OnPlayerGiveDamageActor - by ShoortyFl - 25.11.2017, 12:57
Re: OnPlayerGiveDamageActor - by Joron - 25.11.2017, 13:03
Re: OnPlayerGiveDamageActor - by ShoortyFl - 25.11.2017, 13:05
Re: OnPlayerGiveDamageActor - by MEW273 - 25.11.2017, 13:15
Re: OnPlayerGiveDamageActor - by ShoortyFl - 25.11.2017, 13:46
Re: OnPlayerGiveDamageActor - by ShoortyFl - 25.11.2017, 14:00

Forum Jump:


Users browsing this thread: 1 Guest(s)