Hi, hope you are doing well.
I have been learning Unity DOTS recently and I am struggling with a concept (Structural Change). I also attended the DOTS bootcamp recently held, but still i didn't find the answer I was looking for.
Imagine a game where I have lots and lots (1000+) of enemies, and i have a player who can shoot these enemies down. Now, in a DOTS setup, lets say when the player kills the enemies, should I "Destroy" the enemy or should i just "Hide" it?
I know the question seems very trivial, but if you let me explain quickly. If I destroy the enemies entities, (and it will happen very frequently)....it will be a "structural change" which can be heavy and should be avoided, right? But if I just "Hide" the enemies, now that's a lot of hidden enemies in the chunk which serves very little purpose. Which one should i opt for?
I come from a OOP background, and I have been developing games for almost 6 years now. Very rarely I "Destroyed Gameobjects" because I know thats a significant thing to do in a game and should be avoided. I always tried to hide it (like pooling) in case i need it later. But for this particular problem, where I have lots and lots of enemies, I am very confused what to do.
I am trying my best to avoid structural changes, but its becoming really tedious at some points to hide something that I wont need at a later point in the game.