MCPcopy Create free account
hub / github.com/OpenRCT2/OpenRCT2 / TryGetEntity

Method TryGetEntity

src/openrct2/entity/EntityRegistry.cpp:103–107  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

101 }
102
103 EntityBase* EntityRegistry::TryGetEntity(EntityId entityIndex)
104 {
105 const auto idx = entityIndex.ToUnderlying();
106 return idx >= kMaxEntities ? nullptr : &entities[idx].base;
107 }
108
109 EntityBase* EntityRegistry::GetEntity(EntityId entityIndex)
110 {

Callers 1

Calls 1

ToUnderlyingMethod · 0.80

Tested by

no test coverage detected