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

Can't parse LDtk 1.2.0 #24

Closed
jpvanoosten opened this issue Jan 3, 2023 · 1 comment · Fixed by #25
Closed

Can't parse LDtk 1.2.0 #24

jpvanoosten opened this issue Jan 3, 2023 · 1 comment · Fixed by #25

Comments

@jpvanoosten
Copy link
Contributor

It seems that LDtk 1.2.0 removed the autoTilesetDefUid property from the layer defs. This causes LDtkLoader to break when parsing 1.2.0 levels:

m_auto_tileset(j["autoTilesetDefUid"].is_null() ? nullptr : &p->getTileset(j["autoTilesetDefUid"].get<int>()))

nlohmann/json requires that these keys exist. An assertion is thrown if it doesn't exist:

JSON_ASSERT(m_value.object->find(key) != m_value.object->end());

@Madour
Copy link
Owner

Madour commented Jan 7, 2023

Thank you for reporting and fixing this issue.

@Madour Madour closed this as completed Jan 7, 2023
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 a pull request may close this issue.

2 participants