We use a fetch-or-create pattern pretty much everywhere - resources, events, threads, components. The exact way we do this is a little different everywhere, too.
Ideally, we could make a helper function for this that takes away a lot of the hassle (like the emplace proposal). At the very least, we should unify around a common pattern of what this code looks like.
We use a fetch-or-create pattern pretty much everywhere - resources, events, threads, components. The exact way we do this is a little different everywhere, too.
Ideally, we could make a helper function for this that takes away a lot of the hassle (like the emplace proposal). At the very least, we should unify around a common pattern of what this code looks like.