1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-25 22:42:04 +02:00

Always use ResourcePath for referencing images and animations

This commit is contained in:
Ivan Savenko
2023-08-23 15:07:50 +03:00
parent f79492e5b0
commit 823ffa7a07
201 changed files with 1390 additions and 1362 deletions

View File

@@ -30,7 +30,7 @@
VCMI_LIB_NAMESPACE_BEGIN
std::unique_ptr<CMap> CMapService::loadMap(const ResourceID & name) const
std::unique_ptr<CMap> CMapService::loadMap(const ResourcePath & name) const
{
std::string modName = VLC->modh->findResourceOrigin(name);
std::string language = VLC->modh->getModLanguage(modName);
@@ -40,7 +40,7 @@ std::unique_ptr<CMap> CMapService::loadMap(const ResourceID & name) const
return getMapLoader(stream, name.getName(), modName, encoding)->loadMap();
}
std::unique_ptr<CMapHeader> CMapService::loadMapHeader(const ResourceID & name) const
std::unique_ptr<CMapHeader> CMapService::loadMapHeader(const ResourcePath & name) const
{
std::string modName = VLC->modh->findResourceOrigin(name);
std::string language = VLC->modh->getModLanguage(modName);
@@ -108,7 +108,7 @@ ModCompatibilityInfo CMapService::verifyMapHeaderMods(const CMapHeader & map)
return modCompatibilityInfo;
}
std::unique_ptr<CInputStream> CMapService::getStreamFromFS(const ResourceID & name)
std::unique_ptr<CInputStream> CMapService::getStreamFromFS(const ResourcePath & name)
{
return CResourceHandler::get()->load(name);
}