ktf cleanup; demo playback fixes

git-svn-id: svn://svn.code.sf.net/p/actiongame/code/trunk/ac@2628 e016b1c5-ed68-44aa-a2f7-31cac88cffde
This commit is contained in:
ac_stef
2008-09-15 15:06:54 +00:00
parent 69e4cf7fde
commit 4dd4b46f2a
7 changed files with 30 additions and 28 deletions
+5 -5
View File
@@ -42,7 +42,7 @@ void drawctficon(float x, float y, float s, int col, int row, float ts)
{
if(htftex) drawicon(htftex, x, y, s, col, row, ts);
}
else if(m_ktf || m_tktf)
else if(m_ktf)
{
if(ktftex) drawicon(ktftex, x, y, s, col, row, ts);
}
@@ -379,16 +379,16 @@ void drawradar(playerent *p, int w, int h)
entity *e = f.flagent;
if(!e) continue;
float yaw = showmap ? 0 : p->yaw;
if((m_ktf || m_tktf) && f.state == CTFF_IDLE) continue;
if(m_ktf && f.state == CTFF_IDLE) continue;
if(f.state==CTFF_STOLEN)
{
bool tm = i != team_int(p->team);
if(m_htf) tm = !tm;
else if(m_ktf || m_tktf) tm = true;
else if(m_ktf) tm = true;
if(f.actor && tm && insideradar(centerpos, res/2, f.actor->o))
drawradarent(f.actor->o.x*coordtrans+iconsize/2, f.actor->o.y*coordtrans+iconsize/2, yaw, 3, m_ktf || m_tktf ? 2 : f.team, iconsize, true); // draw near flag thief
drawradarent(f.actor->o.x*coordtrans+iconsize/2, f.actor->o.y*coordtrans+iconsize/2, yaw, 3, m_ktf ? 2 : f.team, iconsize, true); // draw near flag thief
}
else if(insideradar(centerpos, res/2, vec(e->x, e->y, centerpos.z))) drawradarent(e->x*coordtrans, e->y*coordtrans, yaw, 3, m_ktf || m_tktf ? 2 : f.team, iconsize, false); // draw on entitiy pos
else if(insideradar(centerpos, res/2, vec(e->x, e->y, centerpos.z))) drawradarent(e->x*coordtrans, e->y*coordtrans, yaw, 3, m_ktf ? 2 : f.team, iconsize, false); // draw on entitiy pos
}
}