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

Prevent Component overwrite through Tiled user properties #51

Open
adrien-bon opened this issue Nov 15, 2024 · 0 comments
Open

Prevent Component overwrite through Tiled user properties #51

adrien-bon opened this issue Nov 15, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@adrien-bon
Copy link
Owner

Right now, a user can add any component he wants to a map through user properties.
I'm not sure we want that.

For instance, if he tries to add a TilePos to a tile or a Transform to an object, it will lead to strange and undefined behaviour. This could be done unintentionnaly, for instance through the use of Bundle.

In order to mitigate this, we could use the new insert_if_new() API to insert components from the Tiled map instead of a regular insert().

This new API will be available in Bevy 0.15: bevyengine/bevy#14646

@adrien-bon adrien-bon added the enhancement New feature or request label Nov 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant