Quellcode durchsuchen

Fix for serialization bug

nordsoft vor 2 Jahren
Ursprung
Commit
059ccdc9bc
1 geänderte Dateien mit 4 neuen und 0 gelöschten Zeilen
  1. 4 0
      lib/mapObjects/CGTownInstance.h

+ 4 - 0
lib/mapObjects/CGTownInstance.h

@@ -89,6 +89,10 @@ public:
 		h & spells;
 		h & events;
 		h & bonusingBuildings;
+		
+		for(auto * bonusingBuilding : bonusingBuildings)
+			bonusingBuilding->town = this;
+		
 		h & town;
 		h & townAndVis;
 		BONUS_TREE_DESERIALIZATION_FIX