3 ms·
As a beginner not thinking too much about performance, ECS is beautifully elegant and easy to reason about. However I found it nearly impossible to integrate i
by Waterluvian 6y ago
As a beginner not thinking too much about performance, ECS is beautifully elegant and easy to reason about.
However I found it nearly impossible to integrate into libraries/engines that aren't made for it.
I really wanted to use React for my complex RPG UI and PhaserJS or Pixi for I/O, but the state management paradigms just didn't work together (for me at least).
- ralusek 6y agoDo you mind elaborating a bit? My understanding is that ECS would be providing data in a way not unlike most web applications do, such that building a React UI over that data model should be quite easy.
- monocasa 6y agoOne of the nice things about ECS is how easy it is to integrate into an existing structure. In the engine case you just make your existing object hierarchy one component type, and whatever subsystem you're making ECS into its own component. At a library level you just wrap that library's per object state in its own component. What issues did you have?
- mmis1000 6y agoIf your problem is "you can't mutate state of a react app easily because they decides to make their own state management system that can't mutate by part out of the app directly". Probably you can give vue a try. It is designed to work like a plain object. And mutate the data belongs to it from outside of a vue app also reflect to the view instantly. (Just alter the property of the vue component, that's all you need to change it from outside)
- EamonnMR 6y agoI feel your pain. I wanted to combine AngularJS and BabylonJS for a GUI heavy RPG but it proved impractical.