Image paths all messed up

My tmx file previously stored image paths relative to the tmx file, now when I saved it to a file in a new location it looks like “…/…/…/…/…/all/the/way/back/up/to/an/old/folder/images/”

Is this a bug or is it something I did wrong?

EDIT: realized it’s probably because I didn’t copy the old map to the new location and save from there. interesting behavior to preserve file references…

Right, the paths are maintained as absolute in memory so when you save the map to a different location, the relative paths stored in the file will still be pointing to the old location.

It could try to be smart by comparing the previous save location with the new one and checking whether your assets are located at the same relative position as they were at the old location, but I think that is going a bit too far. Keeping it simple keeps it predictable as well.

1 Like