mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-23 23:04:36 +01:00
Pass object repository as a dependency when loading objects
This commit is contained in:
@@ -234,7 +234,7 @@ namespace ObjectJsonHelpers
|
||||
{
|
||||
std::vector<rct_g1_element> result;
|
||||
auto objectPath = FindLegacyObject(name);
|
||||
auto obj = ObjectFactory::CreateObjectFromLegacyFile(objectPath.c_str());
|
||||
auto obj = ObjectFactory::CreateObjectFromLegacyFile(context->GetObjectRepository(), objectPath.c_str());
|
||||
if (obj != nullptr)
|
||||
{
|
||||
auto &imgTable = static_cast<const Object *>(obj)->GetImageTable();
|
||||
|
||||
Reference in New Issue
Block a user