14.11.2017, 06:33
Код:
new Injured[MAX_PLAYERS]; public OnFilterScriptInit() { print("\n--------------------------------------"); print(""); print("--------------------------------------\n"); return 1; } public OnFilterScriptExit() { print("\n--------------------------------------"); print(""); print("--------------------------------------\n"); return 1; } public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid) { new Float:HP; new Float:Armour; GetPlayerHealth(playerid, HP); GetPlayerArmour(playerid, Armour); if(weaponid == 24) SetPlayerHealth(playerid, HP-50);//DesertEagle Deducts HP if(weaponid == 24) SetPlayerArmour(playerid, Armour-50);//DesertEagle Deducts Armour/Kevlar if(weaponid == 22) SetPlayerHealth(playerid, HP-50);//Colt45 Deducts HP if(weaponid == 22) SetPlayerArmour(playerid, Armour-50);//Colt45 Deducts Armour/Kevlar if(weaponid == 32) SetPlayerHealth(playerid, HP-10);//Tec9 Dedcuts HP if(weaponid == 32) SetPlayerArmour(playerid, Armour-10);//Tec9 Deducts Armour/Kevlar if(weaponid == 28) SetPlayerHealth(playerid, HP-10);//Uzi Deducts HP if(weaponid == 28) SetPlayerArmour(playerid, Armour-10);//Uzi Deducts Armour/Kevlar if(weaponid == 23) SetPlayerHealth(playerid, HP-50);//Silenced Colt if(weaponid == 23) SetPlayerArmour(playerid, Armour-50);//Silenced Colt if(weaponid == 31) SetPlayerHealth(playerid, HP-35);//M4 if(weaponid == 31) SetPlayerArmour(playerid, Armour-35);//M4 if(weaponid == 30) SetPlayerHealth(playerid, HP-40);//AK if(weaponid == 30) SetPlayerArmour(playerid, Armour-40);//AK if(weaponid == 29) SetPlayerHealth(playerid, HP-18);//MP5 if(weaponid == 29) SetPlayerArmour(playerid, Armour-18);//MP5 if(weaponid == 34) SetPlayerHealth(playerid, HP-300);//SniperRifle if(weaponid == 34) SetPlayerArmour(playerid, Armour-300);//SniperRifle if(weaponid == 33) SetPlayerHealth(playerid, HP-35);//Country Rifle if(weaponid == 33) SetPlayerArmour(playerid, Armour-35);//Country Rifle if(weaponid == 25) SetPlayerArmour(playerid, Armour-100);//12 Guage Pump Action Remington Shotgun if(weaponid == 25) SetPlayerHealth(playerid, HP-100);//12 Guage Pump Action Remington Shotgun if(weaponid == 27) SetPlayerArmour(playerid, Armour-70);//SPAZ-12 if(weaponid == 27) SetPlayerHealth(playerid, HP-70);//SPAZ-12 return 1; } public OnPlayerUpdate(playerid) { new Float: playersHealth; GetPlayerHealth(playerid, playersHealth); if(playersHealth <= 10 && playersHealth != 0) { SendClientMessage(playerid, -1, "You are critically injured. You may /acceptdeath or wait for a medic to ressussatate you."); ApplyAnimation(playerid,"SWEET","Sweet_injuredloop", 4.0, 1, 0, 0, 0, 0); Injured[playerid] = 1; } } public OnPlayerGiveDamage(playerid, damagedid, issuerid, Float: amount, weaponid, bodypart) { if(!IsPlayerConnected(playerid)) return 0; if(!IsPlayerConnected(issuerid)) return 0; if(playerid != INVALID_PLAYER_ID && bodypart == 9 ) { SetPlayerHealth(playerid, 10.0); SetPlayerArmour(playerid, 0.0); Injured[damagedid] = 1; } if(Injured[damagedid] == 1) { SetPlayerChatBubble(damagedid, "(( THIS PLAYER HAS BEEN CRITICALLY INJURED WITH A GSW TO THE HEAD ))", COLOR_RED, 100.0, 4343344); SendClientMessage(playerid, -1, "NOTICE: You have a GSW in the head, you are now critically injured, make sure to-.."); SendClientMessage(playerid, 01, "..-roleplay your injuries"); } return 1; }
Quote:
(84) : error 025: function heading differs from prototype |