HUDEXTRAS messages

git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@5034 e016b1c5-ed68-44aa-a2f7-31cac88cffde
This commit is contained in:
Rafael Barreto
2010-05-24 18:54:53 +00:00
parent cd638cfc81
commit 5c569a3cf1
6 changed files with 28 additions and 6 deletions
+19
View File
@@ -225,6 +225,19 @@ bool good_map()
return checked;
}
VARP(hudextras, 0, 0, 2);
void showhudextras(char hudextras, char value){
void (*outf)(const char *s, ...) = (hudextras == 2 ? hudoutf : conoutf);
switch(value)
{
case 0:
outf("\f2COMBO"); break;
default:
outf("\f2new message"); break;
}
}
void parsemessages(int cn, playerent *d, ucharbuf &p)
{
static char text[MAXTRANS];
@@ -572,6 +585,12 @@ void parsemessages(int cn, playerent *d, ucharbuf &p)
break;
}
case SV_HUDEXTRAS:
{
char value = getint(p);
if (hudextras) showhudextras(hudextras, value);
}
case SV_HITPUSH:
{
int gun = getint(p), damage = getint(p);