Kaynağa Gözat

Fix header.mapLevels saving

AlexVinS 10 yıl önce
ebeveyn
işleme
f6e2cd16ed
2 değiştirilmiş dosya ile 5 ekleme ve 5 silme
  1. 1 1
      lib/mapping/MapFormatJson.cpp
  2. 4 4
      test/MapComparer.cpp

+ 1 - 1
lib/mapping/MapFormatJson.cpp

@@ -267,7 +267,7 @@ void CMapSaverJson::saveHeader()
 	header["versionMinor"].Float() = VERSION_MINOR;	
 	
 	//todo: multilevel map save support	
-	JsonNode levels = header["mapLevels"];
+	JsonNode & levels = header["mapLevels"];
 	levels["surface"]["height"].Float() = map->height;	
 	levels["surface"]["width"].Float() = map->width;
 	levels["surface"]["index"].Float() = 0;

+ 4 - 4
test/MapComparer.cpp

@@ -60,22 +60,22 @@ void MapComparer::compareHeader()
 	VCMI_REQUIRE_FIELD_EQUAL(width);
 	VCMI_REQUIRE_FIELD_EQUAL(twoLevel);
 
-	BOOST_FAIL("Not implemented");
+	BOOST_ERROR("Not implemented");
 }
 
 void MapComparer::compareOptions()
 {
-	BOOST_FAIL("Not implemented");
+	BOOST_ERROR("Not implemented");
 }
 
 void MapComparer::compareObjects()
 {
-	BOOST_FAIL("Not implemented");
+	BOOST_ERROR("Not implemented");
 }
 
 void MapComparer::compareTerrain()
 {
-	BOOST_FAIL("Not implemented");
+	BOOST_ERROR("Not implemented");
 }
 
 void MapComparer::compare()