Though that If statement admittedly isn't the best way to go about it.
Edit: Just saw this: http://www.tasharen.com/forum/index.php?topic=7799.0 (http://www.tasharen.com/forum/index.php?topic=7799.0) I'm thinking either that's quite a coincidence, or this sort of question gets asked a lot.
Title: Re: UITweenerEditor Method
Post by: ArenMook on January 26, 2014, 09:09:39 PM
Because it's legacy functionality. You should be using the curve on the tweens. Using that field you can create all kinds of interpolation methods, not just linear, ease and bounce.
Title: Re: UITweenerEditor Method
Post by: beermoney on January 27, 2014, 09:04:30 AM
sounds like it would be useful to add bounce in/bounce out to the list of NGUI presets
Title: Re: UITweenerEditor Method
Post by: zeiphon on January 30, 2014, 04:58:36 PM
Because it's legacy functionality. You should be using the curve on the tweens. Using that field you can create all kinds of interpolation methods, not just linear, ease and bounce.
Ah so it's deprecated. Would you mind marking it as such? To be honest, it's still actually quite useful for adding another layer of smoothing on top of the animation curve. I don't know about everyone else, but I find animation curves tricky to get right due to their relatively low fidelity and the inability to specify numeric values in the editor.
Thanks!
Title: Re: UITweenerEditor Method
Post by: beermoney on January 31, 2014, 07:19:23 AM
since bounce is a mathematical function, it doesn't make sense to try and create it by hand it's too fiddly and the end results is unlikely to look good, I've left mine using the deprecated functions
Title: Re: UITweenerEditor Method
Post by: beermoney on January 31, 2014, 07:45:25 AM
ok just doing a little digging and realised the animations curves aren't a feature of NGUI, (which is kinda a relief because I'm always asking myself "how da mook" does this guy keep adding all these features? - there isn't the hours in the day)
the curve presets live in the following directory (windows): ...\AppData\Roaming\Unity\Editor-4.x\Preferences\Presets in a file called "default.curves", which makes me think it'd be very easy to find a bunch of presets already setup something like this... http://stackoverflow.com/questions/5161465/how-to-create-custom-easing-function-with-core-animation
but I couldn't find anything, possibly could use itweens to generate some curves