Search Unity

Sprite dynamic sorting pivot

Discussion in '2D' started by capsey, Aug 3, 2020.

  1. capsey

    capsey

    Joined:
    Mar 20, 2019
    Posts:
    6
    I need this laser sprite (screenshot) to be in the front of the wall like it's sorting center being in the position of player's shadow



    But now laser sprite's pivot is at the beginning of laser (slightly up than needed) so unity think it is upper than wall sprite (wall sprite's pivot is in the bottom center)

    I know that i can write my own sorting system and change Order in Layer by Y and apply offset, but Unity default sorting is more convenient