Hello Guest

Author Topic: How can I reduce the size of the white border to only contain the green border?  (Read 6279 times)

nikolay1243

  • Newbie
  • *
  • Posts: 4
    • View Profile


Hi, so I have a bunch of building sprites that share the same image dimensions
However since they all overlap, most of the time I'm clicking on the empty space outside the green border in the image which is super annoying...
Is there a way to fix this?

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Hi,

One option is to disable the sprite controls - (preferences, enable sprite controls). The handles are controlled by that.

If you want them enabled, but want it to be the tighter bounds, tk2dsprite.cs, line 249 or so
   void OnDrawGizmos() {
         Gizmos.DrawCube(Vector3.Scale(sprite.untrimmedBoundsData[0], _scale), Vector3.Scale(sprite.untrimmedBoundsData[1], _scale));

Rename untrimmedBoundsData to boundsData