tiled-pico8
tiled-pico8 copied to clipboard
awkward workflow for simultaneous editing (both pico8 and Tiled)
This happens to me often enough:
- I open a p8 cart in pico8
- I open the same cart in Tiled
- I edit some non-map data in pico8 (sprites, music, etc)
- I edit the map in Tiled, and save it
- My edits from 3 were overwritten!
This can be avoided by adding extra steps after 3: 3.1. ctrl-S in pico8 to save the cart 3.2. ctrl-R in Tiled to load the cart
But it's a bit awkward. Would it be possible when saving from Tiled to re-read the pico8 cart and only edit the map? That would eliminate the need for step 3.2.
Having written this up, I've realized that step 3.1 will still be necessary, so this probably isn't actually a very helpful suggested solution. Maybe what I want instead is to be able to save the map to a custom .txt format that I can #include
and then parse during game startup...
Alright, I got it working! The workflow is much nicer for me -- no accidental overwriting or pico8 saying "didn't save; conflicting external changes" anymore. But it's pretty janky; the user has to create a .p8l file beforehand with the exact right info in it, and Tiled only knows how to load the sprites by reading an absolute path from a comment in the custom .p8l file... it's a bit of a mess. I think I'll make a separate repo for this
Yeah, unfortunately the workflow you aim for can’t really happen without some additional help from PICO-8. Maybe Zep would agree to implement some kind of interval-based autosave feature?
If you are running Windows, another, maybe less intrusive solution, could be a AutoHotKey script that detects whenever PICO-8 is about to lose focus, or Tiled gains focus, and sends PICO-8 a Ctrl-S
keystroke. Not sure if this accounts for all situations, but it’s probably the approach I’d try.