- 最后登录
- 2014-10-23
- 注册时间
- 2011-7-19
- 阅读权限
- 90
- 积分
- 81303
- 纳金币
- -1
- 精华
- 11
|
iTween动画编辑器,iTween Visual Editor
Many of you will have read the post I wrote about the awesome iTween class for Unity (by Bob Berkebile aka pixelplacement) back in March of this year. Now another user has stepped up and made this already fantastic resource a visual editor that you can simply drop onto objects. Massive props go to David Koontz, who has developed and is offering this as a free download, take a look at his blog post and find the download here -
http://dkoontz.wordpress.com/2010/10/27/itween-visual-editor/
and remember you’ll also need to grab the actual iTween class itself from Bob’s site, go grab it here
http://itween.pixelplacement.com/index.php
下面是详细介绍:
If you’ve been around the Unity world you may have run into the iTween library. It’s a system for animating various thing in your scene, from positions to rotations to scales to color, and even sound volume! It’s a pretty nifty library but I felt it was missing some usability. For example, in a scene if all I want to use iTween for is to have an object float across my screen repeatedly, I’d need to create a whole class just for one line of code such as this:
iTween.MoveTo(gameObject,{"x":10,"time":4,"looptype":"loop"});
On a one-off basis this wouldn’t be bad, but what if you were making a game where you had lots of levels and each one had some subtly different values for the movement pattern of the objects in it. Well, you’d be writing a lot of tiny throwaway classes which really clutters up your project and is just plain annoying. So I got to thinking about how you could write a script you attached to your GameObject that could store the data for a tween and then activate the tween when the scene starts (or wait until it’s activated programmatically). The result is the iTween Visual Editor which can make even fairly complex tweens quite simple. Here is a tween that is moving the GameObject to the camera’s Transform while looking at position (10,0,0 and using an inOutCubic easing type and finally using a pingPong loop type.
Usage is pretty simple. Just attach an iTweenEvent component to the GameObject you want to tween (you can also use the Component/iTween/iTweenEvent menu item). Then choose the type of tween you want and the options for that tween. Click play to see your tween in action.
|
|