1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-27 22:49:25 +02:00

* a bit of custom campaign selection screen

This commit is contained in:
mateuszb
2010-02-13 16:26:47 +00:00
parent 5eef9cde44
commit 40d50aaaa1
8 changed files with 523 additions and 374 deletions

View File

@@ -2106,41 +2106,6 @@ void Mapa::checkForObjectives()
}
}
void CMapInfo::countPlayers()
{
playerAmnt = humenPlayers = 0;
for(int i=0;i<PLAYER_LIMIT;i++)
{
if(players[i].canHumanPlay)
{
playerAmnt++;
humenPlayers++;
}
else if(players[i].canComputerPlay)
{
playerAmnt++;
}
}
}
CMapInfo::CMapInfo(const std::string &fname, const unsigned char *map )
{
init(fname, map);
}
CMapInfo::CMapInfo()
{
version = invalid;
}
void CMapInfo::init(const std::string &fname, const unsigned char *map )
{
filename = fname;
int i = 0;
initFromMemory(map, i);
countPlayers();
}
LossCondition::LossCondition()
{
obj = NULL;