Get Output Chunk size and Enum values via JavaScript

Hi, guys. Working on the exporter using Scripting API (JavaScript). Have couple questions, could you please help me.

1.Is it possible to get map properties
Output Chunk Width
Output Chunk Height
through the JavaScript API?

2.Is it possible to get string values of Enum defined in project through the JavaScript API?

  1. Doesn’t look like it. On the bright side, in a script, you can hard-code the value to whatever you want, it’s only needed for the built-in formats where you have no other way to control it. It would be nice if it could be exposed though.

  2. No. Custom types (including enums) are not yet fully supported by the scripting API, there is an issue open to add this support: Scripting: the API for getting PropertyTypes · Issue #3419 · mapeditor/tiled · GitHub

1 Like

Thank you very much.