Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

*.exp → *.png + *.json #17

Open
annaeus opened this issue Feb 9, 2017 · 3 comments
Open

*.exp → *.png + *.json #17

annaeus opened this issue Feb 9, 2017 · 3 comments

Comments

@annaeus
Copy link

annaeus commented Feb 9, 2017

With Tibia 11 getting newer updates and some features not being implemented on the flash client, I suspect more people will make the switch and want to bring along their map files.

That's the case for me, only I'm not familiar enough with Node / JS to attempt it myself and the byte handling went over my head.

I did workout a quick shell command to extract the coordinates from the .exp file and copy over the corresponding .png files from a full map download and for the most part that worked okay, but I lost the data on areas explored. The whole section is uncovered even though I might have only explored a small part of it.

One thing I do like about having everything uncovered is the ability to see the water between islands instead of it being blanked out. I'm wondering if it'd be possible to detect the large bodies of water in a given map file and configure it so water gets shown.

@mathiasbynens
Copy link
Member

You shouldn’t need this tool for that. When you install the Tibia 11 client, it automatically converts your Tibia 10 maps (from the default location) to the new format!

One thing I do like about having everything uncovered is the ability to see the water between islands instead of it being blanked out. I'm wondering if it'd be possible to detect the large bodies of water in a given map file and configure it so water gets shown.

I’m not sure what exactly you’re trying to do here — could you clarify? Our map data already contains water on the ground floor: https://tibiamaps.github.io/tibia-map-data/floor-07-map.png That could be “automated” by setting unexploredMapByte to the water color ID (0x33) if floorID == '07'.

@annaeus
Copy link
Author

annaeus commented Feb 10, 2017

Thanks for the quick reply!

I want to convert from a Tibia flash client export to the Tibia 11 format. I play on Linux, with the flash client, I don't have Tibia 10 or a default directory for Tibia 11 to convert.

The reasoning is this, I don't want a fully explored map, I want to transfer over the one I've explored manually on the flash client.

I've looked into import functions on both Tibia 10 and Tibia 11, but I've had no luck, it seems that import/export functionality was meant for Tibia 10 -> Flash or Flash -> Flash

My maps are in my browser/flash cache and can be exported as an .exp file.

Looking into it, where I get lost is taking the Base64 encoded string and converting that to a .png image. I saw you documented some steps for doing the reverse, converting a .png into that Base64 string, but I haven't fully grasped it. I'll be spending more time figuring this out, it's only a matter of reversing the process.

As for that last part, what I meant is that on a manually explored map, the water would never be uncovered since we can't walk there. I was thinking it could be fun to go over our map files and uncover water that's part of the ocean. We'd either get a general contour over areas we haven't explored or a nice revealed map over the ocean / between islands.

@e-seger
Copy link

e-seger commented Oct 3, 2023

I am looking to do a conversion from automap .map files to minimap .png files.
I am trying to use your script but I get issues. Any command or old version of the code I can use to convert .map to .png?
tibia-maps --from-maps=./Automap --output-dir=./data

Missing --from-minimap or --from-data flag.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants