Skip to content

Best approach for handling collisions #121

Answered by Doraku
roo-oliv asked this question in Q&A
Discussion options

You must be logged in to vote

Hey, thanks for you kind words :) I will try to comment as best as I can your different approaches:

# 1

Adding storage as component seems indeed a little too memory hungry. You could always use a pool of queues but I feel it complexifies too much for too little gain. I do have an idea I want to explore to allow storing multiple components of the same type on an entity, maybe it could help with this scenario in the futur but it is not there yet ^^"

# 2

I have seen this approach in a lot of other framework, using entities as messages. In DefaultEcs I would actually advise against doing this. Changing an entity composition is not free, using the full inner storage of entities and components …

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@roo-oliv
Comment options

@Doraku
Comment options

@roo-oliv
Comment options

Answer selected by roo-oliv
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants