Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Calling RemoveRange(Entity entity, Span<ComponentType> types) can break entity slot #253

Open
Orcolom opened this issue Jan 11, 2025 · 1 comment
Labels
bug Something isn't working

Comments

@Orcolom
Copy link

Orcolom commented Jan 11, 2025

When calling the public void RemoveRange(Entity entity, Span<ComponentType> types) method with an empty span it will move the entity slot even though the size doesn't change. This throws no exception. So, the next time you add an entity with the same archetype they will point to the same data.

Not sure if this is part of arch philosophy "You should know what you are doing" or considered a bug. Its definitely not something I expected to happen.

@genaray genaray added the bug Something isn't working label Jan 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants
@Orcolom @genaray and others