See #2991 for details; in short, this significantly speeds up GameObjectManager::get_objects_by_type() and GameObjectManager::get_object_count(), by no longer scanning over unrelated object types.
However, the first version had an issue with disappearing objects with paths when a level was being tested from the level editor (#3008). I believe it was caused by the PathObject base class not being recorded in GameObject::get_class_types implementations. I've updated the code to do this (and also record the other intermediate classes, TriggerBase and CollisionListener, even though those are not currently searched for.) I was able to reproduce #3008 with the old version and no longer see it with the new.
I've updated this PR to account for the new Boss and BigSnowball classes, implementing get_class_types for each and adjusting Yeti/GhostTree for their changed base class.
See #2991 for details; in short, this significantly speeds up
GameObjectManager::get_objects_by_type()
andGameObjectManager::get_object_count()
, by no longer scanning over unrelated object types.However, the first version had an issue with disappearing objects with paths when a level was being tested from the level editor (#3008). I believe it was caused by the PathObject base class not being recorded in
GameObject::get_class_types
implementations. I've updated the code to do this (and also record the other intermediate classes, TriggerBase and CollisionListener, even though those are not currently searched for.) I was able to reproduce #3008 with the old version and no longer see it with the new.