Search In
• More options...
Find results that contain...
Find results in...

# ilanb

Members

27

3. ## Optimisation

Hey Carl ! thanks for tips ! this work fine for me, I don't know how to quantify benefits but work fine thanks again ! for (var i:int = 0; i < flipListArray.length; i++) { element = flipListArray[i] as CardFlip; element.flipToFront(); if( i % 2 == 0) TweenLite.to(element, .5, {alpha:0, x:-1000, y:String( Math.random()* 1000 ), delay:Math.random() * 1, z:Math.random()*3000 , ease:Quad.easeInOut}); else TweenLite.to(element, 1, {alpha:0, x:-1000, y:String( Math.random()* -1000 ), delay:Math.random() * 1, z:Math.random()*3000 , ease:Quad.easeInOut}); }

5. ## TimelineMax "gotoAndStop in insertMultiple"

Thx Carl ! very useful example ! try this and adapt for my need !
6. ## TimelineMax "gotoAndStop in insertMultiple"

Hi Carl, I would like to have color change for one movieClip when rotation of this movieClip is finished, actually color are change when rotation of all movieClip is ended (see onComplete function in code) Sorry for poor english... thx num = int(e.target.name.split("img_")[1]); var timeline:TimelineMax = new TimelineMax({onComplete:function() { var tmp:MovieClip; for (var i:int = 1; i <= 10; i++) { tmp = getChildByName("img_" + i) as MovieClip; tmp.gotoAndStop(num); } }}); var clicked_img:MovieClip; var listArray:Array = new Array(); listArray.push(img_1, img_2, img_3, img_4, img_5, img_6, img_7, img_8, img_9, img_10); for (var i:int = 1; i <= 10; i++) { clicked_img = getChildByName("img_" + i) as MovieClip; timeline.insertMultiple( TweenMax.allFrom(listArray, .5, {rotationY:clicked_img.rotationY - 180, ease:Cubic.easeOut}, .06), .5); }
7. ## TimelineMax "gotoAndStop in insertMultiple"

Hi Carl, Thanks for reply, I have tested your solution, but don't make what I need, you can look my attached file to see what i would like. All movieClip turnaround and all movieClip colors changes when tween is finished. But I need change color when a rotation movieClip is finished. Sorry for my poor english File is more explicit Ilan
8. ## TimelineMax "gotoAndStop in insertMultiple"

Hello, I have ten movieClip on stage (img_1, img_2...) each have 10 key (different color). I try to change color for each movieClip when rotation of movieClip is ended here is my test: actually color of movieClip change when timeline is completed not when rotation of movieClip is ended. function onClickItem(e:MouseEvent):void { num = int(e.target.name.split("img_")[1]); var timeline:TimelineMax = new TimelineMax({onComplete:function() { var tmp:MovieClip; for (var i:int = 1; i <= 10; i++) { tmp = getChildByName("img_" + i) as MovieClip; tmp.gotoAndStop(num); } }}); var clicked_img:MovieClip; for (var i:int = 1; i <= 10; i++) { clicked_img = getChildByName("img_" + i) as MovieClip; var listArray:Array = new Array(); listArray.push(img_1, img_2, img_3, img_4, img_5, img_6, img_7, img_8, img_9, img_10); timeline.insertMultiple( TweenMax.allFrom(listArray, .5, {transformAroundCenter:{rotationY:clicked_img.rotationY - 180}, ease:Cubic.easeOut}, .06), .5); } } Thx for point me to the right direction !
9. ## LoaderMax error with "videoItem.content"

Ok sorry, I make a zip today. For MonsterDebugger, yes I have tried with removing trace and it's same.

Hi Jack, the class : https://files.me.com/ibompuis/9uvspy thanks

Hello Jack, I use the last SVN version 1.772 of loadermax Problem are methodes : onChildFail:_onChildFail, onChildCancel:_onChildCancel or skipFailed:true don't work and I don't no why thanks

14. ## Contentdisplay and dispose() error

Thanks Jack, It's much clearer now !! I have created a generic videoloader class and use _genericVideosLoader.playVideoByIndex(cpt); to play video and public function videoEnd():void { return _currentVideo.unload(); } to unload Work like a charm I have found good tuts to help me a lot : http://active.tutsplus.com/tutorials/actionscript/smart-as3-video-loading-with-greensock-loadermax-free-active-premium/

16. ## VideoLoader: all video start at same time

Thanks for the tips, Another great tools the LoaderMax... Greensock Rocks !!

19. ## TimelineMax Array + Rotation with timer

THANKS !!! like this: Work perfectly ! {transformAroundPoint:{point:new Point(POINT_ROTATION_X,POINT_ROTATION_Y), rotation:ROTATION_VOLET_CCW}, ease:Quart.easeInOut})], numVolet * CLOSE_TPS); I'm happy to use and support your work ! happy codding Ilan
20. ## TimelineMax Array + Rotation with timer

Ok sorry for my bad english I try to explain what I need. I try to open and close an Array of sheets ("v0"+numVolet+"_mc") The open function work fine but when I close the sheets with TweenAlign.SEQUENCE all the sheets close at same time. I would like close sheets like range, not at same time you can see the problem on this screencast: http://screencast.com/t/W2RGTKqppheF function to open sheet: Work Fine public function openV(idFiche:int):void { // var ficheAnimOpen:TimelineMax = new TimelineMax({onComplete:endOpenV}); for(var numVolet:int = 1 ; numVolet <= this["OPEN_TPS_F"+idFiche].length; numVolet++) { //trace("fiche :"+idFiche+" volet :"+numVolet+ " temps :"+this["OPEN_TPS_F"+idFiche][numVolet - 1]); ficheAnimOpen.append(new TweenMax(this["fiche0"+idFiche+"_mc"]["v0"+numVolet+"_mc"], ROTATION_VOLET_TPS, {transformAroundPoint:{point:new Point(POINT_ROTATION_X,POINT_ROTATION_Y), shortRotation:{rotation:ROTATION_VOLET_CC}}, ease:Quart.easeInOut}), this["OPEN_TPS_F"+idFiche][numVolet - 1]); } } Function to close sheet: SEQUENCE don't work public function closeV(idFiche:int):void { var ficheAnimClose:TimelineMax = new TimelineMax({onComplete:endCloseV}); for(var numVolet:int = this["OPEN_TPS_F"+idFiche].length; numVolet >= 1; numVolet--) { //trace("fiche :"+idFiche+" volet :"+(numVolet)); ficheAnimClose.insertMultiple([new TweenMax(this["fiche0"+idFiche+"_mc"]["v0"+numVolet+"_mc"], ROTATION_VOLET_TPS, {transformAroundPoint:{point:new Point(POINT_ROTATION_X,POINT_ROTATION_Y), rotation:ROTATION_VOLET_CCW}, ease:Quart.easeInOut, delay:0.1, overwrite:true})], 0, TweenAlign.SEQUENCE, -0.2); } } Thanks for time
21. ## TimelineMax Array + Rotation with timer

Thanks for tips, I'v tried to simplify but I don't find how to use SEQUENCE: you can see effect here: http://screencast.com/t/d1KtuMx88 the 4 sheets back at same time and I would like make delay between sheet fiche.insertMultiple([new TweenMax(this["fiche0"+idFiche+"_mc"]["v0"+(numVolet)+"_mc"], ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CCW})], CLOSE_TPS, TweenAlign.SEQUENCE, 0.2); to understand the array and variables: //----------------------------------------------------------------------------------- // CONSTANTES //----------------------------------------------------------------------------------- // Angle de rotation des volets private const ROTATION_VOLET_CC = 90; private const ROTATION_VOLET_CCW = -45; private const ROTATION_VOLET_TPS = 1; //----------------------------------------------------------------------------------- // VARIABLES //----------------------------------------------------------------------------------- // MovieClip des 8 fiches public var fiche01_mc:MovieClip; public var fiche02_mc:MovieClip; public var fiche03_mc:MovieClip; public var fiche04_mc:MovieClip; public var fiche05_mc:MovieClip; public var fiche06_mc:MovieClip; public var fiche07_mc:MovieClip; public var fiche08_mc:MovieClip; // Temps de lecture des volets des fiches private var OPEN_TPS_F1:Array = [2,2,2,2]; private var OPEN_TPS_F2:Array = [2,2]; private var OPEN_TPS_F3:Array = [2,2,2]; private var OPEN_TPS_F4:Array = [2]; private var OPEN_TPS_F5:Array = [2]; private var OPEN_TPS_F6:Array = [2,2,2]; private var OPEN_TPS_F7:Array = [2,2]; private var OPEN_TPS_F8:Array = [2,2,2,2,2,2]; // Vitesse de fermeture des volets private var CLOSE_TPS:Number = 0.2; thanks
22. ## TimelineMax Array + Rotation with timer

Hi trying to optimise... work fine but I don't understand how to use appenMultiple in function closeV public function openV(idFiche:int):void { var fiche:TimelineMax = new TimelineMax({onComplete:endOpenV}); var iterator:int = 1; for each( var j:int in this["OPEN_TPS_F"+idFiche]) { trace("fiche :"+idFiche+" volet :"+iterator+ " temps :"+j); if (iterator==1) { fiche.append(new TweenMax(this["fiche0"+idFiche+"_mc"]["v0"+iterator+"_mc"], ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),j); } else fiche.append(TweenMax.to(this["fiche0"+idFiche+"_mc"]["v0"+iterator+"_mc"], ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),j); iterator++; } } public function endOpenV():void { trace("done!"); dispatchEvent(new Event("eventOpenEnd")); } public function closeV(idFiche:int):void { var fiche:TimelineMax = new TimelineMax({onComplete:endCloseV}); var iterator:int = 1; for each( var j:int in this["CLOSE_TPS_F"+idFiche]) { trace("fiche :"+idFiche+" volet :"+iterator+ " temps :"+j); if (iterator==1) { fiche.append(new TweenMax(this["fiche0"+idFiche+"_mc"]["v0"+iterator+"_mc"], ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CCW}),j); } else fiche.append(TweenMax.to(this["fiche0"+idFiche+"_mc"]["v0"+iterator+"_mc"], ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CCW}),j); iterator++; } } public function endCloseV():void { trace("done!"); dispatchEvent(new Event("eventCloseEnd")); }
23. ## TimelineMax Array + Rotation with timer

Hi, Thanks for reply, Tried offset but in my exemple I need offset on f01_mc and not fiche01_mc I'v make little example work fine but very not optimised: maybe you can point me to better direction. package { import com.greensock.*; import com.greensock.easing.*; import flash.display.MovieClip; import flash.events.Event; import tools.events.CustomEvent; import tools.events.Dispatcher; public class FicheLearningRecordView extends MovieClip { //----------------------------------------------------------------------------------- // CONSTANTES //----------------------------------------------------------------------------------- // Angle de rotation des volets private static const ROTATION_VOLET_CC = 90; private static const ROTATION_VOLET_CCW = -45; // Durée de rotation des volets private static const ROTATION_VOLET_TPS = 1; // Temps de lecture des volets en secondes // Fiche 1 les règles d'or private static const TPS_F1_V01 = 2; private static const TPS_F1_V02 = 3; private static const TPS_F1_V03 = 7; private static const TPS_F1_V04 = 2; // Fiche 2 les points principaux de la présentation private static const TPS_F2_V01 = 2; private static const TPS_F2_V02 = 5; // Fiche 3 l'uniforme de pénélope private static const TPS_F3_V01 = 2; private static const TPS_F3_V02 = 5; private static const TPS_F3_V03 = 2; // Fiche 4 votre maquillage private static const TPS_F4_V01 = 2; // Fiche 5 l'efficacité à l'accueil private static const TPS_F5_V01 = 2; // Fiche 6 les expressions private static const TPS_F6_V01 = 2; private static const TPS_F6_V02 = 5; private static const TPS_F6_V03 = 7; // Fiche 7 la banque d'accueil private static const TPS_F7_V01 = 4; private static const TPS_F7_V02 = 2; // Fiche 8 gérer les situations difficiles private static const TPS_F8_V01 = 2; private static const TPS_F8_V02 = 6; private static const TPS_F8_V03 = 2; private static const TPS_F8_V04 = 7; private static const TPS_F8_V05 = 2; private static const TPS_F8_V06 = 10; //----------------------------------------------------------------------------------- // VARIABLES //----------------------------------------------------------------------------------- // MovieClip des 8 fiches public var fiche01_mc:MovieClip; public var fiche02_mc:MovieClip; public var fiche03_mc:MovieClip; public var fiche04_mc:MovieClip; public var fiche05_mc:MovieClip; public var fiche06_mc:MovieClip; public var fiche07_mc:MovieClip; public var fiche08_mc:MovieClip; //----------------------------------------------------------------------------------- // INIT //----------------------------------------------------------------------------------- public function FicheLearningRecordView():void { var fiche01:TimelineMax = new TimelineMax({onComplete:finishSheet}); var fiche02:TimelineMax = new TimelineMax({onComplete:finishSheet}); var fiche03:TimelineMax = new TimelineMax({onComplete:finishSheet}); var fiche04:TimelineMax = new TimelineMax({onComplete:finishSheet}); var fiche05:TimelineMax = new TimelineMax({onComplete:finishSheet}); var fiche06:TimelineMax = new TimelineMax({onComplete:finishSheet}); var fiche07:TimelineMax = new TimelineMax({onComplete:finishSheet}); var fiche08:TimelineMax = new TimelineMax({onComplete:finishSheet}); // Applique une rotation sur chaques volets de la fiche toutes les x secondes fiche01.append(new TweenMax(fiche01_mc.v01_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F1_V01); fiche01.append(TweenMax.to(fiche01_mc.v02_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F1_V02); fiche01.append(TweenMax.to(fiche01_mc.v03_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F1_V03); fiche01.append(TweenMax.to(fiche01_mc.v04_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F1_V04); // Replace les volets à leurs positions initiales fiche01.appendMultiple([new TweenMax(fiche01_mc.v01_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW}), new TweenMax(fiche01_mc.v02_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW}), new TweenMax(fiche01_mc.v03_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW}), new TweenMax(fiche01_mc.v04_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW})], 1, TweenAlign.START, 0.2); fiche02.append(new TweenMax(fiche02_mc.v01_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F2_V01); fiche02.append(TweenMax.to(fiche02_mc.v02_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F2_V02); fiche02.appendMultiple([new TweenMax(fiche02_mc.v01_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW}), new TweenMax(fiche02_mc.v02_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW})], 1, TweenAlign.START, 0.2); fiche03.append(new TweenMax(fiche03_mc.v01_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F3_V01); fiche03.append(TweenMax.to(fiche03_mc.v02_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F3_V02); fiche03.append(TweenMax.to(fiche03_mc.v03_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F3_V03); fiche03.appendMultiple([new TweenMax(fiche03_mc.v01_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW}), new TweenMax(fiche03_mc.v02_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW}), new TweenMax(fiche03_mc.v03_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW})], 1, TweenAlign.START, 0.2); fiche04.append(new TweenMax(fiche04_mc.v01_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F4_V01); fiche04.appendMultiple([new TweenMax(fiche04_mc.v01_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW})], 1, TweenAlign.START, 0.2); fiche05.append(new TweenMax(fiche05_mc.v01_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F5_V01); fiche05.appendMultiple([new TweenMax(fiche05_mc.v01_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW})], 1, TweenAlign.START, 0.2); fiche06.append(new TweenMax(fiche06_mc.v01_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F6_V01); fiche06.append(TweenMax.to(fiche06_mc.v02_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F6_V02); fiche06.append(TweenMax.to(fiche06_mc.v03_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F6_V03); fiche06.appendMultiple([new TweenMax(fiche06_mc.v01_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW}), new TweenMax(fiche06_mc.v02_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW}), new TweenMax(fiche06_mc.v03_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW})], 1, TweenAlign.START, 0.2); fiche07.append(new TweenMax(fiche07_mc.v01_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F7_V01); fiche07.append(TweenMax.to(fiche07_mc.v02_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F7_V02); fiche07.appendMultiple([new TweenMax(fiche07_mc.v01_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW}), new TweenMax(fiche07_mc.v02_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW})], 1, TweenAlign.START, 0.2); fiche08.append(new TweenMax(fiche08_mc.v01_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F8_V01); fiche08.append(TweenMax.to(fiche08_mc.v02_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F8_V02); fiche08.append(TweenMax.to(fiche08_mc.v03_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F8_V03); fiche08.append(TweenMax.to(fiche08_mc.v04_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F8_V04); fiche08.append(TweenMax.to(fiche08_mc.v05_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F8_V05); fiche08.append(TweenMax.to(fiche08_mc.v06_mc, ROTATION_VOLET_TPS, {rotation:ROTATION_VOLET_CC}),TPS_F8_V06); fiche08.appendMultiple([new TweenMax(fiche08_mc.v01_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW}), new TweenMax(fiche08_mc.v02_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW}), new TweenMax(fiche08_mc.v03_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW}), new TweenMax(fiche08_mc.v04_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW}), new TweenMax(fiche08_mc.v05_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW}), new TweenMax(fiche08_mc.v06_mc, ROTATION_VOLET_TPS,{rotation:ROTATION_VOLET_CCW})], 1, TweenAlign.START, 0.2); } private function finishSheet():void { trace("done!") } } }
24. ## How can I create an array?

Maybe: var lettersArray:Array = new Array("A", "B", "C"); ...
25. ## TimelineMax Array + Rotation with timer

Hi, I would like to set a timer between each fiche01_mc.f01_mc, fiche01_mc.f02_mc, fiche01_mc.f03_mc, fiche01_mc.f04_mc, like 1'30" between fiche01_mc.f01_mc and fiche01_mc.f02_mc... But dont how to begin and if it's possible ? Second question I have found in club member the TransformAroundPointPlugin, Can I use with my exemple to set the point on f01_mc and not on fiche01_mc... ? screenshot : http://screencast.com/t/PlmvswvKv public function FicheLearningRecordView() { var fiches_arr = new Array(fiche01_mc.f01_mc, fiche01_mc.f02_mc, fiche01_mc.f03_mc, fiche01_mc.f04_mc); var timeline:TimelineMax = new TimelineMax(); for(var key:String in fiches_arr){ var mc:MovieClip = MovieClip(fiches_arr[key]); timeline.append(TweenMax.to(mc, .5, {y:180})); timeline.append(TweenMax.to(mc, .5, {scaleX:2, scaleY:2})); timeline.append(TweenMax.to(mc, 1, {rotation:180})); timeline.append(TweenMax.to(mc, .5, {y:0, alpha:0})); } } Thanks
×