Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* FILTERSCRIPT UTILE POUR LES SERVEURS ROLEPLAY ! */
- #define FILTERSCRIPT
- #include <a_samp>
- #if defined FILTERSCRIPT
- public OnFilterScriptInit()
- {
- print("\n--------------------------------------");
- print(" Dégat d'arme réaliste by Arth pour forum.sa-mp.com");
- print("--------------------------------------\n");
- return 1;
- }
- public OnFilterScriptExit()
- {
- return 1;
- }
- #else
- #endif
- public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid)
- {
- new Float:hp,Float:ap,Float:dg;
- GetPlayerArmour(playerid,ap);
- GetPlayerHealth(playerid,hp);
- if (weaponid==24) dg=51.0;
- if (weaponid==0) dg=15.0;
- if (weaponid==2) dg=25.0;
- if (weaponid==3) dg=25.0;
- if (weaponid==4) dg=35.0;
- if (weaponid==5) dg=25.0;
- if (weaponid==15) dg=25.0;
- if (weaponid==17) dg=10.0;
- if (weaponid==22) dg=35.0;
- if (weaponid==23) dg=35.0;
- if (weaponid==25) dg=65.0;
- if (weaponid==26) dg=65.0;
- if (weaponid==27) dg=65.0;
- if (weaponid==28) dg=20.0;
- if (weaponid==29) dg=27.0;
- if (weaponid==30) dg=45.0;
- if (weaponid==31) dg=45.0;
- if (weaponid==32) dg=20.0;
- if (weaponid==33) dg=70.0;
- if (weaponid==34) dg=125.0;
- if (weaponid==41) dg=15.0;
- if (weaponid==9) dg=50.0;
- if (weaponid==1) dg=20.0;
- if (hp+ap<=dg)
- {
- SetPlayerArmour(playerid,0.0);
- SetPlayerHealth(playerid,0.0);
- }
- else
- {
- ap-=dg;
- if (ap<0.0)
- {
- SetPlayerHealth(playerid,hp+ap);
- ap=0.0;
- }
- SetPlayerArmour(playerid,ap);
- }
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment