Search Unity

Please bring back 2019.X style snapping in Unity 2020.1

Discussion in 'Editor & General Support' started by zapposh, Aug 11, 2020.

  1. zapposh

    zapposh

    Joined:
    Nov 12, 2016
    Posts:
    117
    2D project. Snapping increments are set to .25 on all axis.
    Moving a gameobject around with snapping on worked like a charm these last years.

    Since upgrading to 2020.1, things have changed.
    For ex. moving an object from (1,1) to (0,0) will display as (2.384186e-07,- 4.172325e-07)
    More often than not, this seems to affect 2D objects that have an existing z rotatation on them, like 90°, 180° etc.

    While in the grand scheme of things those values are practically 0, I do not find that readable to work with.
     

    Attached Files:

  2. DiegoDePalacio

    DiegoDePalacio

    Unity Technologies

    Joined:
    Oct 28, 2009
    Posts:
    507
    Hi @zapposh,

    Is the problem only about displaying such very tiny numbers instead of zero?

    Or the objects are not snapping to the proper values if you move them far from the origin?

    If the snapping values are also with some offset while dragging them on positions other than 0, 0, 0... Is the error increasing depending on how far you move them from their original position?

    Sorry for asking so many questions, but I want to know how can I help you better ;)


    Thank you!
     
    zapposh likes this.
  3. zapposh

    zapposh

    Joined:
    Nov 12, 2016
    Posts:
    117
    Hi Diego,
    Thanks for your feedback.

    Easiest is I answer in your text directly. :)

    Is the problem only about displaying such very tiny numbers instead of zero?
    No, but it's highly unpractical and part of the problem.
    The actual problem is the snapping not working:
    -> make a square sprite and reset its transform
    -> rotate it 90° (or 180° or -90° etc)
    -> set snapping options to full units, like 1,1,1
    -> move the sprite around while snapping,
    and instead of values like 2,2,0 or 0,0,0 you'll get things like 2.384186e-07, - 4.172325e-07, 0

    As mentioned, I never had this issue in 2019.x. It is since upgrading to 2020.1.x

    Or the objects are not snapping to the proper values if you move them far from the origin?
    I could not see a correlation between move distance and proper values. While dragging the objects around and snapping the transform values bounce around between expected numbers and weird ones.

    If the snapping values are also with some offset while dragging them on positions other than 0, 0, 0... Is the error increasing depending on how far you move them from their original position?
    Here too, I could not find a correlation between the weird values and the dragging distance from the original position or the world center.

    Hope it helps.
    Thanks
     
  4. DiegoDePalacio

    DiegoDePalacio

    Unity Technologies

    Joined:
    Oct 28, 2009
    Posts:
    507
    So, just to be sure... "Physically" the objects seems to be snapping properly to the values that you configured (on the "Snapping Settings") if you only look to the scene window, but the quantities appearing on the inspector window are approximations, instead of the exact numbers, Right?
     
  5. zapposh

    zapposh

    Joined:
    Nov 12, 2016
    Posts:
    117
    Correct
     
  6. DiegoDePalacio

    DiegoDePalacio

    Unity Technologies

    Joined:
    Oct 28, 2009
    Posts:
    507