25A0 / Quadtastic

A tool to manage sprite sheets and color palettes
https://25a0.itch.io/quadtastic
MIT License
52 stars 3 forks source link

'Reload exporters' ignores custom exporters #38

Closed 25A0 closed 6 years ago

25A0 commented 6 years ago

There are currently two different directories in which Quadtastic tries to find exporters. S.exporters_dirname, which is rooted in the Quadtastic source directory, contains the built-in exporters, and S.custom_exporter_dirname -- a directory somewhere in the user's home directory where custom exporters can be stored without having to mess with Quadtastic's source directory.

exporters.list is called from two places in the code: once in main.lua on start-up, and in reload_exporters.

In main.lua, it is called with both, the directory for built-in exporters, and the directory for custom exporters:

76       -- Fetch exporters
77       local list_success, more = pcall(exporters.list,
78                                        {S.exporters_dirname, S.custom_exporters_dirname})

In reload_exporters, S.custom_exporter_dirname is missing, so that the 'Reload exporters' menu entry doesn't actually scan the directory that contains custom exporters.