SA-MP Forums Archive
script for killing info - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: script for killing info (/showthread.php?tid=65641)



script for killing info - ndr99 - 14.02.2009

does some-one have the script that everyone can see for example --> john killed harry
so that everyone see in the corner --> playerID kind of weapon playerID


Re: script for killing info - Daren_Jacobson - 14.02.2009

pawn Код:
SendDeathMessage(playerid, killerid, reason);
that?
or like
pawn Код:
format(string, sizeof(string), "%s has killed %s with a %s", killername, playername, killerwep);
SendClientMessageToAll(0xFFFFFFFF, string);
not sure which you are talking about


Re: script for killing info - ndr99 - 14.02.2009

that i see who killed who with what

and where to put this?


Re: script for killing info - SilentMouse - 14.02.2009

Quote:
Originally Posted by ndr99
that i see who killed who with what

and where to put this?
Under public OnPlayerDeath(playerid, killerid, reason)


Re: script for killing info - StrickenKid - 14.02.2009

yah do this:
under OnPlayerDeath

Код:
SendDeathMessage(killerid, playerid, reason);
new string[256];
 	new name[MAX_PLAYER_NAME];
 	new dname[MAX_PLAYER_NAME];
  GetPlayerName(killerid, name, sizeof(name));
  GetPlayerName(playerid, dname, sizeof(dname));
	format(string, sizeof(string), "%s(%d) has killed %s(%d).", name,killerid, dname,playerid);
	SendClientMessageToAll(COLOR_RED, string);
and then if you want the killer 's score to go up +1 add this:
Код:
SetPlayerScore(killerid, GetPlayerScore(killerid) + 1);