Kill register - 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: Kill register (
/showthread.php?tid=665248)
Kill register -
SaiyanZ - 27.03.2019
Hello, need a little help or more like 'ideas'.
so i'm using this nevada bomber script:
https://sampforum.blast.hk/showthread.php?tid=335514
is there a way to actually get a kill like score n deathlog etc when you kill someone using the bomber?
i tried doing the following
PHP Code:
//under the command
GetPointZPos(X, Y, Z);
MoveObject(bomb[playerid],X,Y,Z,100.0,A,0.0,0.0);
CreateExplosion(X,Y,Z,10,20.0);
new Float:x, Float:y, Float:z;
for(new i; i<MAX_PLAYERS; i++)
{
if(IsPlayerInRangeOfPoint(i, 5.0, x, y, z))
{
bomberid=playerid;
targetedplayer[i]=1;
}
}
// under OnPlayerTakeDamage
if(targetedplayer[playerid]==1 && issuerid == INVALID_PLAYER_ID)
{
issuerid=bomberid;
}
Re: Kill register -
introzen - 27.03.2019
Yes. You're already checking for, and defining issuerid, so just use that together with
pawn Code:
GetPlayerScore();
SetPlayerScore();