21.06.2014, 21:14
I'm wondering how can i create in this function when i shoot the player he wont loose any health ?
Код:
public OnPlayerGiveDamage(playerid, damagedid, Float: amount, weaponid, bodypart) { if (playerid != INVALID_PLAYER_ID && damagedid != INVALID_PLAYER_ID) { if (weaponid == 23 && TazerHand[playerid] == 1) { if(ReloadingTazer[playerid] > 0) { SCM(playerid, TOMATO, " (info) {FFFFFF}Reloading!"); return 1; } if(!PlayerTazed[damagedid]) { new string[128]; PlayerPlaySoundInArea(playerid, 6003); PlayerTazed[damagedid] = 1; TogglePlayerControllable(damagedid, 0); TazerTimer[damagedid] = 10; for (new i = 0; i < 3; i ++) { ApplyAnimation(damagedid, "PED", "FLOOR_hit_f", 4.0, 1, 0, 0, 0, 0); } ReloadingTazer[playerid] = 1; } } } return 1; }