[Maps] Only load usermaps iwd if available
This commit is contained in:
parent
75d202e2b9
commit
c03268347a
@ -32,6 +32,8 @@ namespace Components
|
|||||||
std::string iwdName = Utils::String::VA("%s.iwd", this->mapname.data());
|
std::string iwdName = Utils::String::VA("%s.iwd", this->mapname.data());
|
||||||
std::string path = Utils::String::VA("%s\\usermaps\\%s\\%s", Dvar::Var("fs_basepath").get<const char*>(), this->mapname.data(), iwdName.data());
|
std::string path = Utils::String::VA("%s\\usermaps\\%s\\%s", Dvar::Var("fs_basepath").get<const char*>(), this->mapname.data(), iwdName.data());
|
||||||
|
|
||||||
|
if (Utils::IO::FileExists(path))
|
||||||
|
{
|
||||||
this->searchPath.iwd = Game::FS_IsShippedIWD(path.data(), iwdName.data());
|
this->searchPath.iwd = Game::FS_IsShippedIWD(path.data(), iwdName.data());
|
||||||
|
|
||||||
if (this->searchPath.iwd)
|
if (this->searchPath.iwd)
|
||||||
@ -46,6 +48,7 @@ namespace Components
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void Maps::UserMapContainer::reloadIwd()
|
void Maps::UserMapContainer::reloadIwd()
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user