Greetings.
I’ve recently heard about DOTS and I am very excited to try it out, but I have a question to ask.
Many people probably struggle with it because it’s a step away from the traditional OOP but I feel like I’ll have a relatively easy time with it - I never liked OOP and I am not good at thinking of objects, I much prefer thinking of data(components) and logic(functions). Coming from a background of a Roblox developer who never used OOP but functional programing, OOP has always felt like an unnatural overcomplication of things.
However OOP is widely used and there are well-established means of documenting it - UML. Thus, my question is, what do you use to plan and document games using DOTS? Not because I care too much about documentation, on the contrary, as a solo developer I couldn’t care less, but I plan on developing a game as my university graduation project, so I will undoubtedly have to explain the logic behind it and rigorously document things. Which would be all too easy with UML.
Is there a graphical notation that works well for DOTS? I don’t want to have to use OOP just because of the part I least enjoy doing, writing documentation.
Besides, I also think that this would be important for large teams.
That being said, UML may still be applicable, I am not yet very familiar with DOTS but it is mainly designed for OOP, so perhaps something else would work better? Maybe it’s a dumb question to ask, sorry if that’s the case.
Thanks in advance.
It is unrelated to DOTS specifically, but you can try
Auto documentation generator.
1 Like
Doxygen generates documentation, not graphical representation. It has class hierarchy generation graph generation but that really doesn’t work for ECS.
1 Like
I agree that DOD (data-oriented design) is much easier to grasp and reason about than OOP.
This makes that question a bit moot because in DOD you remove all the complexities of OOP where one class depends on another, one assembly requiring others, and so forth.
In DOD and DOTS you have systems that run in sequence. At most you have to make guarantees where system A needs to complete before system E starts.
What you’ll be looking for is a sequential graph, a timeline, something like that. And then for each branch (a system) you’d specify the components and data the system works with. It’s most important to flag reads and writes in some form, so that you can see that one system may write at the same time as another, making them dependent. I don’t have a good solution for this though but just reasoning about the flow of data should make those cases easy to spot.
1 Like
I wish I had a suggestion, this is a struggle for me as well. I’m coming from 17 years of object oriented design philosophy, so patterns that I use to organize my thoughts and my code are largely out the window.
I think UML, specifically for database design, might actually be helpful here. Collections of tags essentially are systems. Each system can interact with one another as they change the properties of a tag, the way a foreign key would in a database.
This is clumsy but it’s helping me, just in this moment as I consider it, to imagine how I might visually organize my project.
It’s also kind of a convenient way to visualize how systems interact with monobehaviours.
I don’t know, just an idea, hopefully more people chime in, I’m also curious.
1 Like