From 85eaea50a0a6baae15e4ed9d60e333d3ceb264e0 Mon Sep 17 00:00:00 2001 From: Bukz Date: Mon, 23 May 2011 19:44:54 +0000 Subject: [PATCH] player/player1 commands update git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@6462 e016b1c5-ed68-44aa-a2f7-31cac88cffde --- source/src/clientgame.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/source/src/clientgame.cpp b/source/src/clientgame.cpp index 6f8e072a..724c8b7a 100644 --- a/source/src/clientgame.cpp +++ b/source/src/clientgame.cpp @@ -298,6 +298,8 @@ void playerinfo(const char *cn, const char *attr) { ATTR_INT(magcontent, p->weaponsel->mag); ATTR_INT(ammo, p->weaponsel->ammo); + ATTR_INT(primary, p->primary); + ATTR_INT(curweapon, p->weaponsel->type); ATTR_INT(nextprimary, p->nextprimary); } if((p->team == player1->team && m_teammode) || player1->isspectating() || p == player1) @@ -314,12 +316,13 @@ void playerinfo(const char *cn, const char *attr) ATTR_INT(pj, p->plag); ATTR_INT(state, p->state); ATTR_INT(role, p->clientrole); - ATTR_INT(primary, p->primary); ATTR_INT(frags, p->frags); ATTR_INT(flags, p->flagscore); ATTR_INT(points, p->points); ATTR_INT(deaths, p->deaths); ATTR_INT(tks, p->tks); + ATTR_INT(alive, p->state == CS_ALIVE ? 1 : 0); + ATTR_INT(spec, p->team == TEAM_SPECT || p->spectatemode == SM_FLY ? 1 : 0); ATTR_INT(cn, p->clientnum); // only useful to get player1's client number. conoutf("invalid attribute"); }