mirror of
https://github.com/vcmi/vcmi.git
synced 2024-12-24 22:14:36 +02:00
- ignore wog maps if wog is not present
This commit is contained in:
parent
8be801a6dc
commit
b3bbe27089
@ -1,5 +1,3 @@
|
||||
// default configuration for mod system loaded at launch
|
||||
|
||||
{
|
||||
"textData" :
|
||||
{
|
||||
@ -7,7 +5,8 @@
|
||||
"artifact" : 171,
|
||||
"creature" : 197,
|
||||
"faction" : 9,
|
||||
"hero" : 156
|
||||
"hero" : 156,
|
||||
"mapVersion" : 33 // WoG
|
||||
},
|
||||
|
||||
"modules":
|
||||
|
@ -1108,7 +1108,10 @@ void SelectionTab::parseMaps(const std::vector<ResourceID> & files)
|
||||
{
|
||||
CMapInfo mapInfo;
|
||||
mapInfo.mapInit(files[i].getName());
|
||||
allItems.push_back(mapInfo);
|
||||
|
||||
// ignore unsupported map versions (e.g. WoG maps without WoG
|
||||
if (mapInfo.mapHeader->version <= CGI->modh->settings.data["textData"]["mapVersion"].Float())
|
||||
allItems.push_back(mapInfo);
|
||||
}
|
||||
catch(std::exception & e)
|
||||
{
|
||||
|
@ -7,7 +7,8 @@
|
||||
"artifact" : 144,
|
||||
"creature" : 150,
|
||||
"faction" : 9,
|
||||
"hero" : 156
|
||||
"hero" : 156,
|
||||
"mapVersion" : 28 // max supported version, SoD
|
||||
},
|
||||
|
||||
"hardcodedFeatures" :
|
||||
|
@ -278,7 +278,12 @@ namespace EMapFormat
|
||||
{
|
||||
enum EMapFormat
|
||||
{
|
||||
INVALID, WOG=0x33, AB=0x15, ROE=0x0e, SOD=0x1c
|
||||
INVALID = 0,
|
||||
// HEX DEC
|
||||
ROE = 0x0e, // 14
|
||||
AB = 0x15, // 21
|
||||
SOD = 0x1c, // 28
|
||||
WOG = 0x33 // 51
|
||||
};
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user