Author Topic: UITooltip not scaling background sprite  (Read 2029 times)

terravires

  • Guest
UITooltip not scaling background sprite
« on: May 20, 2013, 03:37:46 AM »
Ok,

So back again with more problems. :(  I've spent hours reading forums and searching google for a working solution but can't find one that works.  I found a post saying to use a Offset object under UITooltip because the Z axis is reset otherwise.  I have two atlases, one for my UI + fonts, and another for item icons.

UI Root 2D (fixed size)
- UICamera
- - Panel (0,0,0)
- - - UIToolTip (0,0,0) (objects set for camera label and sprite)
- - - - Offset Gameobject (0, 0, -5)
- - - - - Label  (0,0,0) layer 102
- - - - - Sprite (0,0,0) layer 100 (tried simple, sliced, etc.)

I get the tooltip label to show up, but the background sprite is never scaled correctly.  I see things like:   Ne[w Lab]el where the [ ] is the sprite image and the text overlaps both sides.  My label size also seems to change in scale, sometimes getting smaller then it started.

When running the sprite scale sometimes is -70x30, but only when running.  When I stop it goes back to my setting of 150x75.  Both label and sprite are on the same atlas.  But I need the Z axis offset to keep it from being drawn under another UI atlas below.

I'm using 2.6.1e

ArenMook

  • Administrator
  • Hero Member
  • *****
  • Thank You
  • -Given: 337
  • -Receive: 1171
  • Posts: 22,128
  • Toronto, Canada
    • View Profile
Re: UITooltip not scaling background sprite
« Reply #1 on: May 20, 2013, 09:12:07 AM »
Is your panel marked as static?