Tilemap with different tile sizes

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By kiel814

I’m just starting to learn to use the engine and I have come across the following issue:
I’ve downloaded an isometric tileset.

So first I made a tilemap node for the floor tiles. They are all 64x32 so everything was fine.
The problem was when I decided to add all the other objects. Some of them are higher. Even as high as 64x128.
So when I place an object tile on top of a floor tile, they do not align, I have to place the object on another place for it to match with the floor.
I tried changing the Tile Origin of both tilemaps, but none seems to make sense to me.

Let’s take for example a railway floor and a cart object:
The cart is 64x64.

If I set the origins to “top left”, the floor is placed as expected…
TopLeftFloor
But then, the cart is below…
TopLeftObject

With “bottom left”…
BottomLeftFloor
BottomLeftObject

And with “center”…
CenterFloor
CenterObject

So no matter what origin I choose, the cart is always below the floor.

I could just place the cart one tile above… But that doesn’t feel really natural… Besides, I expect I will have lots of trouble when I try to use bigger tiles, like walls and columns.
No to mention when I want to have characters drawn in front or behind different objects.

So… Is this regular behavior? Is this a bug? Am I doing something wrong?

EDIT: I found there is an “Isometric Game” template. And I can place those tiles perfectly even when they are different sizes…
But I don’t find the difference between that template and my project.

:bust_in_silhouette: Reply From: kiel814

Ok, I found the answer in the end.

I had to properly set the offset of each sprite in the scene before converting it to a tilemap.

I had tried this before, and re-converted the scene to a tilemap, and made sure the “merge” option was disabled on the save dialog.
But apparently, the assets in my main scene were not reloaded. Even after removing and re-setting the Tile Set property of the Tilemap. I had to delete the old .tres file, create a new one, delete the tilemap node, close the project, reopen it, and create the tilemap from scratch.
Not sure which of these actions caused the assets to reload. Probably there was a faster way to do it.

I want to add that the offset that needs to change is the Tex Offset, for me it was the Y-Axis and I had to set mine to -32. I did not have to remove anything or change anything in my scene or reload. I just had to change it for each tileset piece and then save the tileset. Once I move back into my Tilemap everything was placing just fine.

reefcrazed | 2019-12-14 17:08