Created
September 18, 2012 04:40
-
-
Save 40/3741294 to your computer and use it in GitHub Desktop.
as3 blinds effect
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| unction vBlinds() { | |
| var i=0; | |
| var tweens:Array=new Array(16); | |
| var shapes:Array=new Array(16); | |
| var timer:Timer=new Timer(200,16); | |
| timer.addEventListener(TimerEvent.TIMER, function(e:TimerEvent){ | |
| shapes[i]=new Sprite(); | |
| shapes[i].name=i; | |
| transitions.addChild(shapes[i]); | |
| shapes[i].graphics.lineStyle(0,0x000000); | |
| shapes[i].graphics.beginFill(0x000000); | |
| shapes[i].graphics.drawRect(0, 0, 1, 900); | |
| shapes[i].graphics.endFill(); | |
| shapes[i].y=0; | |
| shapes[i].x=(i*100); | |
| runTween(tweens, 16, shapes[i], "width", Strong.easeOut, 0, 100, 2, true); | |
| i++; | |
| } | |
| ); | |
| timer.start(); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment