MCPcopy Create free account
hub / github.com/OpenLoco/OpenLoco / createEntityVehicle

Function createEntityVehicle

src/OpenLoco/src/Entities/EntityManager.cpp:291–300  ·  view source on GitHub ↗

0x00470039

Source from the content-addressed store, hash-verified

289
290 // 0x00470039
291 EntityBase* createEntityVehicle()
292 {
293 if (getListCount(EntityListType::null) <= 0)
294 {
295 return nullptr;
296 }
297
298 const auto newId = rawListHeads()[enumValue(EntityListType::null)];
299 return createEntity(newId, EntityListType::vehicle);
300 }
301
302 // 0x0047024A
303 void freeEntity(EntityBase* const entity)

Callers 1

createVehicleBaseEntityFunction · 0.85

Calls 3

getListCountFunction · 0.85
enumValueFunction · 0.85
createEntityFunction · 0.85

Tested by

no test coverage detected