11
« on: February 28, 2014, 10:49:52 PM »
So, I decided to build the repro case anyway, since I have come up against the problem in a different part of the code... And I made an interesting discovery:
One again, I have a prefab: UISprite + Box Collider + UIImageButton + UILabel
When I first set it up, the text moved fine, but I couldn't see the button texture, but when I set the depth of the sprite to 2 so it would be visible, the text no longer moved. The label is depth 4. In fact, after further experimentation, setting the sprite's depth to *anything* (including 0) in code prevents the label text from moving. So, there seems to be some weird interaction between a statement like this:
ButtonSprite.depth = 2;
And the text moving along with the object in a TweenPosition.
This is the simplest possible setup, with a single script attached to an object, a background prefab, and the button prefab above.
It takes ten minutes to set up. Do you still want me to send it to you?