1
\$\begingroup\$

I have downloaded this 2d isometric tileset : https://assetstore.unity.com/packages/2d/environments/cute-isometric-town-starter-pack-134286

But when I tried to create a map in Unity, I have this :

enter image description here

But in the tool "Tiled", I was able to do this :

enter image description here

But to do this in Tiled, I had to set tile size to 1024x720px.

How can I do the same thing in Unity ?

\$\endgroup\$

1 Answer 1

4
\$\begingroup\$

It appears that the width/height ratio of your tiles doesn't match that of your Grid component.

Go to the Grid component of your tilemap and set the cell size accordingly. When your tiles are 1024 x 720, then your cell size ratio also needs to have the same ratio. Setting those to 1024 and 720 will probably be far too big, because now a single tile is 1024 Unity units across. You certainly could work like that, but it is probably a bit unwieldy. But you can also set those to a much lower value as long as the ratio stays the same. For example 64 : 45 or 1 : 0.703125.

After you did that, you will probably notice that your tiles are either too small or too large to fill a cell properly. You can fix that by going to the import setting of the tileset image and adjust the "pixels per unit" setting to 1024 divided by the X-size of your grid.

\$\endgroup\$
1
  • \$\begingroup\$ Thank you, It solved the problem. \$\endgroup\$
    – Dasgard
    Dec 12, 2022 at 14:22

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .