diff options
| author | oy <Tom_Adams@web.de> | 2010-09-12 13:18:11 +0200 |
|---|---|---|
| committer | oy <Tom_Adams@web.de> | 2010-09-12 13:18:11 +0200 |
| commit | 9ab3e7e121a856f7642c5066e250aa6fe2df685e (patch) | |
| tree | a22fcd38b4a71a49fc173edfe6373d0332b14017 /src/game/client | |
| parent | daab7fdcd4b5cb40161ad137df1632fdaa370a22 (diff) | |
| download | zcatch-9ab3e7e121a856f7642c5066e250aa6fe2df685e.tar.gz zcatch-9ab3e7e121a856f7642c5066e250aa6fe2df685e.zip | |
fixed overlapping voting. Closes #100
Diffstat (limited to 'src/game/client')
| -rw-r--r-- | src/game/client/components/hud.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/game/client/components/hud.cpp b/src/game/client/components/hud.cpp index 192238e3..b9f20231 100644 --- a/src/game/client/components/hud.cpp +++ b/src/game/client/components/hud.cpp @@ -213,10 +213,14 @@ void CHud::RenderVoting() TextRender()->TextColor(1,1,1,1); char Buf[512]; - TextRender()->Text(0x0, 5, 60, 6, m_pClient->m_pVoting->VoteDescription(), -1); - str_format(Buf, sizeof(Buf), Localize("%ds left"), m_pClient->m_pVoting->SecondsLeft()); float tw = TextRender()->TextWidth(0x0, 6, Buf, -1); + + CTextCursor Cursor; + TextRender()->SetCursor(&Cursor, 5.0f, 60.0f, 6.0f, TEXTFLAG_RENDER|TEXTFLAG_STOP_AT_END); + Cursor.m_LineWidth = 100-tw; + TextRender()->TextEx(&Cursor, m_pClient->m_pVoting->VoteDescription(), -1); + TextRender()->Text(0x0, 5+100-tw, 60, 6, Buf, -1); |