Y Sorting Not Working on Isometric Tile

Godot Version

4.3

Question

Hi guys- I have isometric block tiles mimicing cubes (fitting in a 32x32px square) on an isometric tilemap (32x16px tiles). I cannot get Y sorting to work on the cube tiles- I have a sprite and an enemy which have Y sorting functioning perfectly, but it will not work on the cubes.

-Player & Sprite have a Z index of 1.

-The parent tilemap (level 0) has a Z index of 0.

-The child tilemap has a Z index of 0 and the tile itself has a Z index of 1.

-With an index of 1 on the tile, the player and the enemy sprite will always appear behind the tile.

-With an index of 0 on the tile, the player and the enemy sprite will always appear infront of the tile.

-Both the player and the enemy sprite have y sorting fixed near the bottom of their sprites.

-I have played about with the tile’s y sort origin; it is where it should be in the base of the tile. If i move the tiles y sort origin up or down any amount it has zero effect.

-y sorting simply isnt happening on the cube.

-The option ‘y sort enabled’ is toggled ‘on’ on the child map as well as on all parent nodes.

-Tile Shape is set to Isometric, Tile Layout to Diamond Down, and Tile Offset Axis set to Vertical Offset.

-Toggling top level on or off had no effect.

-Recreating the tile on the parent level had no effect.

-Dividing the tile into x2 32x16px tiles had no effect.

I found a potential workaround using separate layers here Y-sorting enabled but not working - #10 by andrewdavidson0980 which I will try tomorrow.

I’ve been trying to sort this all day; any help would really be appreciated!!!

I solved this issue. Y sorting was not working because my maps had a parent (simply called maps) that was a simple 2dnode. I replaced the 2dnode with a tilemap layer node and turned y sorting on, thus resolving the issue.

1 Like