| 571 | } |
| 572 | |
| 573 | ComponentFrameStorage* EntityCommandBuffer::GetStorage(ComponentTypeIndex type, uint16_t componentSize, void* dtor) |
| 574 | { |
| 575 | auto storage = Data.ComponentPools.Find(type); |
| 576 | if (!storage) { |
| 577 | storage = Data.ComponentPools.Add(type, Allocator); |
| 578 | storage->ComponentSizeInBytes = componentSize; |
| 579 | storage->ComponentTypeId = type; |
| 580 | storage->DestructorProc = dtor; |
| 581 | } |
| 582 | |
| 583 | return storage; |
| 584 | } |
| 585 | |
| 586 | void* EntityCommandBuffer::CreateComponentRaw(EntityHandle entity, ComponentTypeIndex type, uint16_t componentSize, ComponentFrameStorageIndex& index, void* dtor) |
| 587 | { |