Skip to content

Way to use .ldtk file at compile time only #20

Open
@zommerfelds

Description

@zommerfelds

From what I'm experiencing, it seems like the .ldtk file doesn't actually need to be included in the release. In my case I'm loading resources in a PAK file. This library still works if I compile with the full file but only provide an empty .ldtk in the PAK at runtime. So I'm wondering if we should:

  1. Not try to load the .ldtk file at runtime if data is already there. What is the file used for at runtime?
  2. Provide a way to map the relative path to your resource base path in the editor. For example if I put the .ldtk file in the src directory and reference a tile set in a sibling res directory it will be saved as "relPath": "../res/tileset.png". I will see all tiles in the editor, but when running the game it will fail because the assets are not loaded relative to the src directory.

If you are interested I can try to look into making a PR, but wanted to have your input first. It's probably not as simple as I'm imagining. :)
Thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions