All this is is a way to add kills, deaths, and headshot counts. Its easy after apoc showed me how
.
Here we go
Some globals :
Code:
int killer
int victim
int headshot
int kills
int deaths
int headshots
char *weaponname// leave like this
all set to zero.
Now move down to death message
Read the byes for killer, victim, headshot and the string for weapon name. Like so
Code:
killer = READ_BYTE();
weaponname = READ_STRING();
now we have the messages found now we allow to do the counters
Code:
if(killer = engfuncs->getlocalplayer()->index && victim != engfuncs->getlocalplayer()->index)
{
kills++
}
else if(victim==engfuncs->getlocalplayer()->index)
{
deaths++;
}
if(killer==engfuncs->getlocalplayer()->index && headshot==1)
{
headshots++;
}
Now in where you want to print it (drawonhud/hud_redraw)
Make an extern interger for kills,deaths, and headshots in whichever file you are printing it through(client source file)
and then print them...
Code:
DrawHudString(1,300,255,255,255," Kills : %d", kills)