Currently resources are stored in a hashmap which is likely quite slow to iterate through. We should investigate Arena Allocators as an alternative to ECS (unsure if they could be used together). Arena Allocators would allow better iteration through entities/resources whilst still providing stable pointers (having them in all in a vec would mean the pointers move whenever the vec grows). Will need to do some memory profiling to figure out how/if we need to segment the resources/entities.
Currently resources are stored in a hashmap which is likely quite slow to iterate through. We should investigate Arena Allocators as an alternative to ECS (unsure if they could be used together). Arena Allocators would allow better iteration through entities/resources whilst still providing stable pointers (having them in all in a vec would mean the pointers move whenever the vec grows). Will need to do some memory profiling to figure out how/if we need to segment the resources/entities.