Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <a_samp>
- #define COLOR_YELLOW 0xFFFF00AA
- enum stats
- {
- deaths,
- kills
- }
- new pInfo[MAX_PLAYERS][stats];
- #if defined FILTERSCRIPT
- public OnFilterScriptInit()
- {
- return 1;
- }
- public OnFilterScriptExit()
- {
- return 1;
- }
- public OnPlayerConnect()
- {
- pInfo[playerid][deaths]=0;
- pInfo[killerid][kills]=0;
- return 1;
- }
- public OnPlayerDeath(playerid, killerid, reason)
- {
- pInfo[playerid][deaths]++;
- pInfo[killerid][kills]++;
- return 1;
- }
- public OnPlayerCommandText(playerid, cmdtext[])
- {
- if (strcmp("/stats", cmdtext, true, 10) == 0)
- {
- new string[200];
- format(string, sizeof(string),"Ölések:%d Halások:%d",pInfo[playerid][kills],pInfo[playerid][deaths]);
- SendClientMessage(playerid,COLOR_YELLOW,string);
- return 1;
- }
- return 0;
- }
- #endif
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement