Tiled: Command line --export-map broken in 1.4.0 on Windows

Created on 22 Jun 2020  路  3Comments  路  Source: mapeditor/tiled

I'm doing tiled.exe --export-map asdf.tmx asdf.json and that worked well on 1.3.5.

After upgrading to 1.4.0 it stopped working. After switching tiled.exe to console mode it shows this error:
QObject::connect(Tiled::MainWindow, Tiled::ScriptManager): invalid null parameter

The error does not appear for -v or -h, just for --export-map.

After downgrading to 1.3.5 exporting works again without issues.

Edit to add: The error isn't related to asdf.tmx - even if I pass a non-existent file the error still shows up.

bug urgent

Most helpful comment

So, another problem was that the DocumentManager was created at a later stage now. Both issues should be fixed in the above commit. I'll do a Tiled 1.4.1 release soon!

All 3 comments

Thanks for the report, I'll look into this soon!

It looks like a problem that got introduced because of the support for setting a project-specific extensions folder, which is why the script manager is trying to access the main window. But when exporting via the command-line there is no main window instantiated.

So, another problem was that the DocumentManager was created at a later stage now. Both issues should be fixed in the above commit. I'll do a Tiled 1.4.1 release soon!

Thanks!

Was this page helpful?
0 / 5 - 0 ratings