mirror of
				https://github.com/vcmi/vcmi.git
				synced 2025-10-31 00:07:39 +02:00 
			
		
		
		
	- Compile fix - unique_ptr can't be serialized
- Linking fix - now MapGenOptions have DLL-interface (but probably shouldn't be called directly from client anyway)
This commit is contained in:
		| @@ -596,7 +596,7 @@ CSelectionScreen::CSelectionScreen(CMenuScreen::EState Type, CMenuScreen::EMulti | ||||
| 		opt = new OptionsTab(); //scenario options tab | ||||
| 		opt->recActions = DISPOSE; | ||||
|  | ||||
| 		randMapTab = new RandomMapTab; | ||||
| 		randMapTab = new RandomMapTab(); | ||||
| 		randMapTab->recActions = DISPOSE; | ||||
| 	} | ||||
| 	sel = new SelectionTab(screenType, bind(&CSelectionScreen::changeSelection, this, _1), multiPlayer); //scenario selection tab | ||||
|   | ||||
| @@ -28,6 +28,8 @@ class CTextBox; | ||||
| class CCampaignState; | ||||
| class CConnection; | ||||
| class JsonNode; | ||||
| class CMapGenOptions; | ||||
| class RandomMapTab; | ||||
| struct CPackForSelectionScreen; | ||||
| struct PlayerInfo; | ||||
|  | ||||
|   | ||||
| @@ -31,7 +31,7 @@ public: | ||||
| 	std::vector <TModID> requirements; | ||||
|  | ||||
| 	/// mod configuration (mod.json). | ||||
| 	std::unique_ptr<JsonNode> config; | ||||
| 	std::shared_ptr<JsonNode> config; //TODO: unique_ptr can't be serialized | ||||
|  | ||||
| 	template <typename Handler> void serialize(Handler &h, const int version) | ||||
| 	{ | ||||
|   | ||||
| @@ -48,7 +48,7 @@ namespace EMonsterStrength | ||||
|  * The map gen options class holds values about general map | ||||
|  * generation settings e.g. the size of the map, the count of players,... | ||||
|  */ | ||||
| class CMapGenOptions | ||||
| class DLL_LINKAGE CMapGenOptions | ||||
| { | ||||
| public: | ||||
| 	/** | ||||
|   | ||||
		Reference in New Issue
	
	Block a user