include amxmodx include amxmisc include cstrike include fun include cs

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#include <fun>
#include <csx>
#define PLUGIN "Csstats in tab"
#define VERSION "1.0"
#define AUTHOR "chmod"
public plugin_init(){
register_plugin(PLUGIN, VERSION, AUTHOR);
register_clcmd("say /test", "get_my_stats");
register_logevent("new_round", 2 , "1=Round_Start");
}
public new_round(){
new players[32], num, i;
get_players(players, num);
for(i=0;i<num;i++){
get_my_stats(players[i]);
}
}
public get_my_stats(id){
new stats[8], bodyhits[8];
get_user_stats(id, stats, bodyhits);
new frags = stats[0];
new deaths = stats[1];
//~ client_print(id, print_chat, "Kills:%d ^nDeaths:%d", stats[0], stats[1]);
set_user_frags(id, frags)
cs_set_user_deaths(id, deaths);
}