SA-MP Forums Archive
How to do this ? - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: How to do this ? (/showthread.php?tid=569010)



How to do this ? - VenomMancer - 27.03.2015

How to call this under OnPlayerTakeDamage ?
This :
pawn Код:
OnPlayerDeathEx(playerid, killerid);
I make it for give player money and score who killing.

Why i nedd call under Onplayertakedamage ?
Because cheater use OnplayerDeath for fake kill.

#sorryformybadenglish


Re: How to do this ? - Loot - 27.03.2015

Код:
public OnPlayerTakeDamage(playerid, issuerid, Float: amount, weaponid, bodypart)
{
     // issuerid is the one who caused the damage - playerid is the "victim"
     OnPlayerDeathEx(playerid, issuerid);
     return 1;
}



Re: How to do this ? - ATGOggy - 27.03.2015

PHP код:
public OnPlayerTakeDamage(playeridissueridFloatamountweaponidbodypart)
{
     new 
Float:health;
     
GetPlayerHealth(playeridhealth);
     if(
health==0)
     {
          
CallLocalFunction("OnPlayerDeathEx""ii"playeridissuerid);
     }
     return 
1;




Re: How to do this ? - VenomMancer - 28.03.2015

Quote:
Originally Posted by ATGOggy
Посмотреть сообщение
PHP код:
public OnPlayerTakeDamage(playeridissueridFloatamountweaponidbodypart)
{
     new 
Float:health;
     
GetPlayerHealth(playeridhealth);
     if(
health==0)
     {
          
CallLocalFunction("OnPlayerDeathEx""ii"playeridissuerid);
     }
     return 
1;

This will works ?