Tasharen Entertainment Forum

Support => NGUI 3 Support => Topic started by: stepollo on March 12, 2015, 09:58:46 AM

Title: Progress Bar help
Post by: stepollo on March 12, 2015, 09:58:46 AM
Hello, I am learning Unity and NGUI recently so probably this is a really stupid question.
I have a progress bar on my game and it works. Now i have two problems. I know that I can set a value using this code:powerbar.value = 0.9f;
But how to add a value to an existing value? For example if the bar is set to 0.5f add 0.4f and get the value of 0.9f?
And how to decrease this value over time? I don't need a pre-written code, just some tips to get this by myself! Thank you all!!
Title: Re: Progress Bar help
Post by: ArenMook on March 12, 2015, 08:28:17 PM
bar.value += 0.4f;?

Not sure what the difficulty would be...