Hi folks,
I have a best practice question. I am fairly new to the DOTS world, but I got the principles and have my first things running. However, I am struggling with the concept of having different Entities with different Components affecting each other.
Usually I write a System Based Class that does work for a couple of entities with one or more components. I get that principle and I can work with this.
But I came to the point, where I have one kind of entity which affects an other kind of entity. I don’t quite see how I can handle this, or rather whats the supposed way of doing this is.
The only thing I can come up with, doing an entity query with the first set of entities, storing the needed information (somehow) and then doing a second query with the other type of entity and modifying them with the previously stored data. And doing all that in the update method of the same system class.
This doesn’t feel right and I think there is a better, more sophisticated way of doing this.
I hope I could make myself clear, any help or examples are greatly appreciated.
Cheers
Santo.