void CModHandler::load() { CStopWatch totalTime, timer; CContentHandler content; logGlobal->infoStream() << "\tInitializing content handler: " << timer.getDiff() << " ms"; for(const TModID & modName : activeMods) { logGlobal->traceStream() << "Generating checksum for " << modName; allMods[modName].updateChecksum(calculateModChecksum(modName, CResourceHandler::get(modName))); } // first - load virtual "core" mod that contains all data // TODO? move all data into real mods? RoE, AB, SoD, WoG content.preloadData(coreMod); for(const TModID & modName : activeMods) content.preloadData(allMods[modName]); logGlobal->infoStream() << "\tParsing mod data: " << timer.getDiff() << " ms"; content.load(coreMod); for(const TModID & modName : activeMods) content.load(allMods[modName]); logGlobal->infoStream() << "\tLoading mod data: " << timer.getDiff() << "ms"; VLC->creh->loadCrExpBon(); VLC->creh->buildBonusTreeForTiers(); //do that after all new creatures are loaded identifiers.finalize(); logGlobal->infoStream() << "\tResolving identifiers: " << timer.getDiff() << " ms"; content.afterLoadFinalization(); logGlobal->infoStream() << "\tHandlers post-load finalization: " << timer.getDiff() << " ms"; logGlobal->infoStream() << "\tAll game content loaded in " << totalTime.getDiff() << " ms"; }