Display map name while downloading

Conflicts:
	src/engine/client.h
	src/engine/client/client.h
This commit is contained in:
def 2014-08-16 01:06:17 +02:00 committed by oy
parent 26ab35dab1
commit f8278ec032
3 changed files with 4 additions and 1 deletions

View file

@ -92,6 +92,7 @@ public:
virtual void EnterGame() = 0;
//
virtual const char *MapDownloadName() = 0;
virtual int MapDownloadAmount() const = 0;
virtual int MapDownloadTotalsize() const = 0;

View file

@ -259,6 +259,7 @@ public:
void ProcessConnlessPacket(CNetChunk *pPacket);
void ProcessServerPacket(CNetChunk *pPacket);
virtual const char *MapDownloadName() { return m_aMapdownloadName; }
virtual int MapDownloadAmount() const { return m_MapdownloadAmount; }
virtual int MapDownloadTotalsize() const { return m_MapdownloadTotalsize; }

View file

@ -1697,7 +1697,8 @@ int CMenus::Render()
pButtonText = Localize("Abort");
if(Client()->MapDownloadTotalsize() > 0)
{
pTitle = Localize("Downloading map");
str_format(aBuf, sizeof(aBuf), "%s: %s", Localize("Downloading map"), Client()->MapDownloadName());
pTitle = aBuf;
pExtraText = "";
NumOptions = 5;
}