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

Exporter: better handling of duplicate object names #1595

Merged
merged 1 commit into from
Mar 3, 2020

Conversation

MoritzBrueckner
Copy link
Collaborator

Fix/Workaround for #1523.

Iron does not allow duplicate names for objects but the now replaced code was still adding exporting objects to collections if their names were already "taken".

Also, objects in collections are now always exported with their full asset name, taking the collection name into account which decreases the rate of name conflicts massively.

In the very rare case that an object from a collection still has the same name as another object in the scene (that object then must be named [collection_name]_[object_name].blend for this problem to occur, which is very unusual), a warning is printed to the console and the collection object with the duplicate name is not exported.


Just an idea for the future (off-topic): Warnings sometimes get buried amongst all other kinds of messages in the console and tend to get overseen. I think a message at the start of the game that says that n warnings occurred during export could help here. Or a hint in the UI if it is not too annoying). Maybe I will look into that and open another PR.

@luboslenco
Copy link
Member

Thanks!

Just an idea for the future (off-topic): Warnings sometimes get buried amongst all other kinds of messages in the console and tend to get overseen. I think a message at the start of the game that says that n warnings occurred during export could help here. Or a hint in the UI if it is not too annoying). Maybe I will look into that and open another PR.

Sounds good. We could also de-clutter console output a bit by default, I think khamake has some silent mode switch.

@MoritzBrueckner MoritzBrueckner deleted the fix-object-names branch March 3, 2020 21:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants