mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-21 14:02:59 +01:00
Close #12428: Refactor OBJECT_SOURCE_GAME to use strong enum
This commit is contained in:
@@ -41,7 +41,7 @@ struct ObjectRepositoryItem
|
||||
std::string Path;
|
||||
std::string Name;
|
||||
std::vector<std::string> Authors;
|
||||
std::vector<uint8_t> Sources;
|
||||
std::vector<ObjectSourceGame> Sources;
|
||||
Object* LoadedObject{};
|
||||
struct
|
||||
{
|
||||
@@ -54,12 +54,12 @@ struct ObjectRepositoryItem
|
||||
std::vector<rct_object_entry> Entries;
|
||||
} SceneryGroupInfo;
|
||||
|
||||
OBJECT_SOURCE_GAME GetFirstSourceGame() const
|
||||
ObjectSourceGame GetFirstSourceGame() const
|
||||
{
|
||||
if (Sources.empty())
|
||||
return OBJECT_SOURCE_CUSTOM;
|
||||
return ObjectSourceGame::Custom;
|
||||
else
|
||||
return static_cast<OBJECT_SOURCE_GAME>(Sources[0]);
|
||||
return static_cast<ObjectSourceGame>(Sources[0]);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user