mirror of
https://github.com/vcmi/vcmi.git
synced 2025-06-17 00:07:41 +02:00
Split massive CModHandler class/file into multiple parts:
- IdentifierStorage is now a separate handler in VLC - Renamed ModHandler::Incompatibility exception to ModIncompatibility - Extracted ModScope namespace from ModHandler - Extracted ModUtilities namespace from ModHandler - Split CModHandler.cpp on per-class basis - Replaced some direct members with unique_ptr to reduce header includes
This commit is contained in:
@ -31,8 +31,10 @@
|
||||
#include "../CCallback.h"
|
||||
#include "../lib/CGeneralTextHandler.h"
|
||||
#include "../lib/filesystem/Filesystem.h"
|
||||
#include "../lib/modding/CModHandler.h"
|
||||
#include "../lib/modding/ContentTypeHandler.h"
|
||||
#include "../lib/modding/ModUtility.h"
|
||||
#include "../lib/CHeroHandler.h"
|
||||
#include "../lib/CModHandler.h"
|
||||
#include "../lib/VCMIDirs.h"
|
||||
#include "CMT.h"
|
||||
|
||||
@ -229,7 +231,8 @@ void ClientCommandManager::handleGetConfigCommand()
|
||||
|
||||
for(auto contentName : contentNames)
|
||||
{
|
||||
auto& content = (*VLC->modh->content)[contentName];
|
||||
auto const & handler = *VLC->modh->content;
|
||||
auto const & content = handler[contentName];
|
||||
|
||||
auto contentOutPath = outPath / contentName;
|
||||
boost::filesystem::create_directories(contentOutPath);
|
||||
@ -242,7 +245,7 @@ void ClientCommandManager::handleGetConfigCommand()
|
||||
{
|
||||
const JsonNode& object = nameAndObject.second;
|
||||
|
||||
std::string name = CModHandler::makeFullIdentifier(object.meta, contentName, nameAndObject.first);
|
||||
std::string name = ModUtility::makeFullIdentifier(object.meta, contentName, nameAndObject.first);
|
||||
|
||||
boost::algorithm::replace_all(name, ":", "_");
|
||||
|
||||
|
Reference in New Issue
Block a user