ECS? https://repl.it/@VictorQueiroz/UniformCookedFirm
Overall looks OK for me for the initial implementation that you can tweak in future for your needs. But some things I would improve: 1) You will need to have ability to iterate over multiple types of components at once. E.g. each<DamageComponent, HealthComponent>(...) That probably will make it much more complex, but you'll see while using the ECS that it is rarely only one component being iterated over. 2) Use static_cast instead of reinterpret_cast 3) Also you don't delete your systems prior exit
Обсуждают сегодня