Welcome,
Guest
. Please
login
or
register
.
May 20, 2025, 05:01:26 PM
Home
Help
Search
Login
Register
Tasharen Entertainment Forum
»
Support
»
NGUI 3 Support
»
Changing texture at UITexture resets alpha to 1 (after update to 3.8.0)
« previous
next »
Print
Pages: [
1
]
Author
Topic: Changing texture at UITexture resets alpha to 1 (after update to 3.8.0) (Read 1751 times)
smallbit
Newbie
Thank You
-Given: 0
-Receive: 0
Posts: 5
Changing texture at UITexture resets alpha to 1 (after update to 3.8.0)
«
on:
March 11, 2015, 03:15:30 AM »
Hi
I have a character preview in my game I am changing texture every 3 secs. I first lower the alpha (UIWidget.color.a) by lerp), than flip texture and than lerp alpha to 1. It worked all fine before updating NGUI from 3.0+ to 3.8.0. Now in the moment of switching texture the alpha is reset to 1 (just alpha r.g.b remains the same) which creates an unpleasant effect because next just after that my lerp takes control from 0-1 so I have texture appearing just for a frame. I am changing texture using UITexture.mainTexture =. Any ideas what can be causing this problem and how to tackle it ?
Thanks in Advance.
Logged
ArenMook
Administrator
Hero Member
Thank You
-Given: 337
-Receive: 1171
Posts: 22,128
Toronto, Canada
Re: Changing texture at UITexture resets alpha to 1 (after update to 3.8.0)
«
Reply #1 on:
March 12, 2015, 07:47:08 PM »
You should be adjusting UIWidget.alpha, not color.a. Nothing in NGUI will change the alpha for you, unless you have some component doing it, such as a button. Assigning UITexture.mainTexture doesn't alter the alpha.
Logged
Print
Pages: [
1
]
« previous
next »
Tasharen Entertainment Forum
»
Support
»
NGUI 3 Support
»
Changing texture at UITexture resets alpha to 1 (after update to 3.8.0)