3 ms·
> How generic should I make my systems? It's easy to make them very specific, but, at a certain specificity, it feels like it's just lazier OOP. More generic an
by meheleventyone 3y ago
> How generic should I make my systems? It's easy to make them very specific, but, at a certain specificity, it feels like it's just lazier OOP. More generic and I start spending my time handling edge-cases that don't actually need to exist.
Making a game is already hard so my advice is to “make the game” and get specific. Personally it doesn’t matter if you go top-down or bottom-up you really want to go from simple->complex at all levels. Doing this will help structure the game and make it easier to restructure as you go. You can also always generalize later.
Managing dependencies is definitely trickier in the parallel ECS context because often you’re naturally inclined to thinking about Entities interacting but systems update across all Entities in a piece-wise manner so it’s very easy to end up with implicit ordering dependencies between systems that cause subtle weirdness in the game when evaluated out of order. Especially when the execution order isn’t fixed. In some respects the Actor model would be a better fit.