Pārlūkot izejas kodu

- fixed crash in town after loading #1291 + extra check just in case.
- disabled intro menu animation for now - different position in different versions (WoG, SoD)
- removed no longer needed entry for Linux video from filesystem

Ivan Savenko 12 gadi atpakaļ
vecāks
revīzija
0c5a717e08
4 mainītis faili ar 6 papildinājumiem un 5 dzēšanām
  1. 3 0
      client/CCastleInterface.cpp
  2. 1 3
      config/filesystem.json
  3. 1 1
      config/mainmenu.json
  4. 1 1
      lib/CTownHandler.h

+ 3 - 0
client/CCastleInterface.cpp

@@ -39,6 +39,9 @@ using namespace boost::assign;
 
 const CBuilding * CBuildingRect::getBuilding()
 {
+	if (!str->building)
+		return nullptr;
+
 	if (str->hiddenUpgrade) // hidden upgrades, e.g. hordes - return base (dwelling for hordes)
 		return town->town->buildings[str->building->getBase()];
 

+ 1 - 3
config/filesystem.json

@@ -37,9 +37,7 @@
 		[
 			{"type" : "vid", "path" : "ALL/Data/H3ab_ahd.vid"},
 			{"type" : "vid", "path" : "ALL/Data/Heroes3.vid"},
-			{"type" : "vid", "path" : "ALL/Data/video.vid"},
-			// Location of video files in linux release
-			{"type" : "dir",  "path" : "ALL/Data/Video"}
+			{"type" : "vid", "path" : "ALL/Data/video.vid"}
 		],
 		"CONFIG/":
 		[

+ 1 - 1
config/mainmenu.json

@@ -9,7 +9,7 @@
 	{
 		"background" : "gamselbk",
 		//"scalable" : true, //background will be scaled to screen size
-		"video" :    {"x": 8, "y": 105, "name":"CREDITS.SMK" },//Floating WoG logo
+		//"video" :    {"x": 8, "y": 105, "name":"CREDITS.SMK" },//Floating WoG logo. Disabled due to different position in various versions of H3.
 		//"images" : [],//Optioal, contains any additional images in the same format as video
 		"items" : 
 		[

+ 1 - 1
lib/CTownHandler.h

@@ -78,7 +78,7 @@ struct DLL_LINKAGE CStructure
 
 	template <typename Handler> void serialize(Handler &h, const int version)
 	{
-		h & pos & defName & borderName & areaName & building & buildable;
+		h & pos & defName & borderName & areaName & building & buildable & hiddenUpgrade;
 	}
 };