Author Topic: How do I stop a child objects alpha being set by parent alpha?  (Read 3401 times)

Meltdown

  • Jr. Member
  • **
  • Thank You
  • -Given: 10
  • -Receive: 0
  • Posts: 56
    • View Profile
I find it quite frustrating when I use a button prefab, and I want to set the alpha of the 'normal' state alpha to about 50%.
But this then sets the alpha of all child items of the button.

How do I stop this from happening?

pahe

  • Newbie
  • *
  • Thank You
  • -Given: 2
  • -Receive: 1
  • Posts: 37
    • View Profile
Re: How do I stop a child objects alpha being set by parent alpha?
« Reply #1 on: March 09, 2014, 07:04:34 AM »
I guess you have a hierarchy like:

- buttontexture + buttonscript
-- icontexture

So when you change the alpha of the parent object it will also effect the child. You can instead change it to:

- buttonscript
-- buttontexture
-- icontexture