Seanba / Tiled2Unity

Export Tiled Map Editor (TMX) files into Unity
Other
499 stars 121 forks source link

Tiled2Unity exports only .xml and creates no prefab / Preview complains about index out of range #181

Open VladDerptastic opened 6 years ago

VladDerptastic commented 6 years ago

Hey there!

Trying to export a small level (T2U v.1.0.9.4, Unity: 2017.3.1f1) greeted me with 2 problems, which I just can't resolve:

First, I can't preview the map when I load it in Tiled2Unity, because I'm greeted with a "Index out of range" exception: error

Nonetheless I tried to export, which resulted only in an .xml file being generated in the Imported folder and then the following Unity error: unityerror ("castle.png" is one of the tilesets I'm using)

A bit of context, I had an image layer before that, with a fairly big image in it. First it was complaining about that file, so I removed it just to test if that was the issue, now it's just complaining about the next file in order.

Said "castle.png" is not existing in that folder, prior to exporting (nor does it exist afterwards, as I said, I just get the .xml file).

I'm a bit stumped by this, so any suggestion would be appreciated.

Seanba commented 6 years ago

Hi there. Tiled2Unity will require write-access to textures. Was that texture opened in an editor? Or are you using Perforce or a similar version management system?

BTW, I'm moving over to SuperTiled2Unity now which has much improved importer system.

VladDerptastic commented 6 years ago

Hey! Other than Tiled itself, no editor had them open. I closed Tiled too with no difference in the result. No, I'm using Git with Sourcetree, which wasn't running either. Played around with the individual files' permissions, just to see if maybe there was a hitch there, since you hinted at the read-write access, but they had full permissions and nothing has changed.

As a side note, I saw SuperT2U before, but it was leveraging on a few new features in Unity 2018, wasn't it? I was hoping for a resolution for my current versions, but if that's not an option, I'll just might have to make that transition. =)