Change to paginlandscape2.cfg?

CaseyB

13-11-2006 19:41:45

Has there been a change to the way that the paginlandscape2.cfg is parsed? In the past we haddefaultmap=Clevelandand when we updated this was causing an exception we had to change it todefaultmap=CLE
CLE=Cleveland
becuase of this methodconst String &PagingLandScapeOptions::getMapFilename(const String &currMapName) const
{
LandScapeFileNames::const_iterator i = mMapList.find(currMapName);
LandScapeFileNames::const_iterator iEnd = mMapList.end();
if (i != iEnd)
return i->second;

for (i = mMapList.begin(); i != iEnd; ++i)
{
if (StringUtil::match(i->second, currMapName, false) ||
StringUtil::match(i->first, currMapName, false))
{
return i->second;
}
}
OGRE_EXCEPT(Exception::ERR_ITEM_NOT_FOUND,
"Cannot locate a Config File defining the map named " + currMapName,
"PagingLandScapeOptions::loadMap");
}
It looks through the list of aliases and if there are none then it throws an exception. I think that instead of throwing an exception it should simply return the string that was passed in.

tuan kuranes

29-11-2006 15:38:03

Good point, I'll fix that in CVS.

tuan kuranes

30-11-2006 09:13:16

Done.

CaseyB

30-11-2006 17:52:51

Sweet, thanks!