Hi, this should be a relatively quick question.
I'm thinking about the approaches to simple events related to player input and their interaction with the UI - like player pressing CTRL to crouch or clicking on an item in their inventory.
Since these are one-off events that can happen at most once every frame, I believe it might be preferable to simply use an enablable components for each of these events, and add them onto the Player Entity directly (or some external InputEventHandler).
The other option of adding/removing components would constantly cause structural changes (not to mention it might allocate a new chunk after each change?), which might not be preferable if the number of these events is not large anyways - checking 10 different enablable components shouldn't likely be that big of a deal.
For events created by my DOTS entities (damage event from an NPC, and such), I'd likely choose a completely different approach - likely one utilising a shared buffer/stream for registering the events, with separate system to apply them. Unless the events were 'rare' and happened only occasionally - in which case adding/removing a component from some shared EntityManager could fare better (since I could use RequireForUpdate in related systems or use Singleton checks).
Is my understanding of these principles correct, and my approach sound?
It is a basic question, but making a mistake early in development and sticking with it when developing other systems is a path to hell, so I want to get my habits straight as soon as possible.