Editor gizmos improvements: XY movement comfortable for 2D games and 2 important fixes

Gizmo in 2D game

We improved behavior of gizmos (for translating, rotating, scaling TCastleTransform in the editor):

  1. The translation mode is more comfortable for 2D games. When you have typical 2D projection (orthographic, and camera looks along -Z axis) then

    • clicking on a special box in the middle of the gizmo,

    • or clicking on the Z arrow (previously a useless blue dot in case of such typical 2D projection)

    … allows to move the object simultaneously in X and Y. This allows to just move the object in 2D freely. This is done thanks to Andrzej Kilijański!

  2. Fixed a case when translation may behave a bit crazy when the transformation had both rotation and non-uniform scale applied.

  3. Fixed imprecise calculations (that caused the gizmo size to “tremble” sometimes) when using on a scene with large bounding box.

1 Like