mirror of
https://github.com/OpenRCT2/OpenRCT2
synced 2026-01-30 02:05:13 +01:00
Reduce object casting (#24072)
This commit is contained in:
committed by
GitHub
parent
a8e2c6e375
commit
70bdddcf36
@@ -65,6 +65,5 @@ void TerrainEdgeObject::ReadJson(IReadObjectContext* context, json_t& root)
|
||||
TerrainEdgeObject* TerrainEdgeObject::GetById(ObjectEntryIndex entryIndex)
|
||||
{
|
||||
auto& objMgr = OpenRCT2::GetContext()->GetObjectManager();
|
||||
auto* obj = objMgr.GetLoadedObject(ObjectType::terrainEdge, entryIndex);
|
||||
return static_cast<TerrainEdgeObject*>(obj);
|
||||
return objMgr.GetLoadedObject<TerrainEdgeObject>(entryIndex);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user