Jump to content
Search Community

Carl last won the day on June 9

Carl had the most liked content!

Carl

Moderators
  • Posts

    9,831
  • Joined

  • Last visited

  • Days Won

    547

Everything posted by Carl

  1. you're welcome. and check out loaderMax http://www.greensock.com/loadermax/ it will save a lot of headache.
  2. it seems your problem is not being explained accurately. the swf that contains the phone does infact work fine in a browser: http://www.oromamedia.com/msecenter.com ... header.swf the problem is that your swf is not working when loaded into another swf when you are using AS2 with externally loaded assets _root refers to the parent swf that is doing the loading. once header.swf gets loaded into preloader.swf... _root mentioned in header refers to the root of your preloader. to prevent this add this._lockroot = true; to the first frame of your msecenter-header.swf OR in header.swf use relative paths from the buttons to the phone
  3. hello jemmon, there are a number of things that are messing up here: the biggest problems are in here: var arry:Array = new Array(holder_mc.numChildren); trace(arry.length); for(var n:int = 0; n TweenMax.allTo(arry[n], 1, {alpha:1}, 0.3); } the whole point of allTo is so that you don't need to manually loop through an array... you just tell allTo what array to loop through. i have a video here on allFrom which works in a similar fashion: http://bit.ly/f5qWol so either kill the for loop, or just use the loop to call a bunch of TweenMax.to()s next your arry Array doesn't have anything in it. in your loop add trace(arry[n]) I don't think anything will trace. what you want to do is define your arry Array outside of any functions. in the init function add each b to arry via arry.push( this will put each b into arry so that TweenMax.allTo(arry, 1, {alpha:1}) will work inside animateChildren() lastly the init function is calling animateChildren 28 times because it is inside a loop furthermore animateChildren is hoping to also loop through all the items in holder_mc. So 28 times you are calling a function that is trying to animate everything in holder_mc. so inside the init() function make sure animateChildren doesn't run until all objects are on the stage by moving animateChildren() outside the init() loop. also, each b needs to have it's alpha set to 0 initially so that your tween bringing the alpha to 1 actually has something to do. ultimately your code should look something like this (i can't guarantee it will work) var arry:Array = new Array(); function init():void { for(var i:int = 0; i var b:MovieClip = new box_mc(); b.x = (i % 7) * 49; b.y = int(i / 7) * 49; //make each b alpha 0 b.alpha = 0; holder_mc.alpha = 0; holder_mc.addChild(; // add each b to the arry Array arry.push(; b.addEventListener(MouseEvent.MOUSE_OVER, onMouseOver); b.addEventListener(MouseEvent.MOUSE_OUT, onMouseOut); b.buttonMode = true; b.mouseChildren = false; } //call animateChildren() outside the loop animateChildren(); } function animateChildren():void { //clean up animateChildren by using a single allTo() : no need for a loop // oh an make sure the holder can be seen holder_mc.alpha = 1 TweenMax.allTo(arry, 1, {alpha:1}, 0.3); } } you were very close! hopefully this explanation brings you closer to making something sweet. Carl
  4. does it loop more than once? if you don't want it to repeat at all, remove {repeat:1} if your code you show is the only thing in your movie, and nothing else is forcing that code to execute a second time such as the flash IDE timeline looping... your TA will play only once.
  5. from looking at your code nothing is jumping out at me. as you said the loadSlide, displaySlide, loadSlide, displaySide sequence appears to be working, so that means that the timeline is in fact playing as the onComplete is firing. Its just that you are not "seeing the tween". what I would do is try to figure out what is working and not working. For instance... is the tween playing, but masking isn't working? is the tween playing but you can't see it cause it is on a level/depth beneath the holder? I would probably start by getting rid of the masking and just trying to see if I can see solid bars moving. Once I can see the bars, then I'd try to figure out why the masking isn't working. the fact that it works for the first time makes me thinks things are "pretty right" and its gotta be something small that is getting in the way. if you feel like posting a zip with just this functionality in place I'd take a look at it for you. Carl
  6. try changing var timeline:TimelineMax=new TimelineMax({repeat:1,repeatDelay:1,yoyo:true,onComplete:loadSlide()}); to var timeline:TimelineMax=new TimelineMax({repeat:1,repeatDelay:1,yoyo:true,onComplete:loadSlide}); no parenthesiseeses after loadSlide
  7. hey Dave, glad to help. I've found that just reading the AsDocs and going through old posts on this forum is a great way to learn. http://www.greensock.com/as/docs/tween/ ... layedCall() when I come across something in the docs that sounds cool, but I don't really understand I force myself to try to implement it somehow. Carl
  8. the following will fade a sound in over 1 second after a 3 second delay. you can call myFunction however you like, for the onComplete of a TimelineMax, TweenMax, delayedCall... whatever var sound:Crunches = new Crunches(); var chompSound:SoundChannel; TweenLite.delayedCall(3, myFunction) function myFunction(){ chompSound = sound.play(); TweenMax.fromTo(chompSound, 1, {volume:0}, {volume:1}) } sound.stop() won't work as stop() is a method of SoundTransform, not Sound. could they make this more confusing? this helps a lot: http://www.republicofcode.com/tutorials/flash/as3sound/
  9. hello groovdafied, from what I can muster I'd start here: categoryArray.push(catName); this code is pushing a string into your categoryArray. allTo() needs an array of display objects, not String values of their .name property. i know, its weird. its more an AS3 thing and not a tweenMax issue. try this instead categoryArray.push(; this will actually be adding each b (or a reference to each to the array.
  10. by default strokes are set to scale proportionally so if you make it very wide it automatically gets thicker. go inside your line2_mc and select the stroke. in the properties panel go to the stroke menu and select "none" OR convert your line to a rectangle with a height of 1px also you want to make sure you spell height right.
  11. When using a TweenMax.to() the properties that you set are target / end / destination properties so setting a property there for the beginning of the tween would be counter-intuitive to the entire TweenMax/Lite model. the following should suit your situation box.visible = false; TweenMax.fromTo(box, 1, {visible:true}, {x:300, delay:2}); the box will start invisible after 2 seconds it will appear and tween its x. thanks for bringing this up, I never used the visible plugin before and it I can see it can come in quite handy!
  12. yo attaboy! great job of integrating the mask effect with an externally loaded image! it seems it is all working except the variable transparency of the mask. your code looks really good. the only thing I would suggest as a fix is this: bars.cacheAsBitmap=true; holder.cacheAsBitmap=true; holder.mask=bars; addChild(holder); the problem may be that you are setting the holder.mask = bars BEFORE it is added to the stage. try moving it up above bars.cacheAsBitmap = true; that is only a guess. if that doesn't fix it, zip up all your files and post them here. I'll take a look at it tomorrow. let me know if you get it working. Carl ps. if other snorkl.tv files give you trouble feel free to post in the comments over there. I do my best to address each comment.
  13. unfortunately I don't have any idea what a common problem might be that would cause this. If the issue still remains after stripping out or pausing the non-troublesome timelines, perhaps posting the code to the funky timeline will help us assist you.
  14. yeah just a little adjustment is necessary: TweenMax.to(myLabel, 0.5, {glowFilter:{color:0x000000, alpha:0.75, blurX:15, blurY:15, yoyo:true, repeat:1}}); should be TweenMax.to(myLabel, 0.5, {glowFilter:{color:0x000000, alpha:0.75, blurX:15, blurY:15}, yoyo:true, repeat:1}); it gets tricky with all the {}, but you had the yoyo included as part of the glowFilter props. enjoy.
  15. there are a few ways of doing this probably. using a tweenMax frame tween you could try something like timeline.append(TweenMax.to(countdown_mc, 6, {frame:3, ease:Linear.easeNone, delay:1})) the next tween in the timeline may have to be delayed as well so that the last frame of the countdown_mc has time to be read you may have to play around with the timing to get it to work exactly like you want. i added the delay as without it the first frame didn't seem to show as long as the second frame. also, you may need to have a stop() action in frame 1 of the countdown MovieClip.
  16. hmmm, i used your code exactly as is except I had different instance names on my buttons and it worked fine. try putting trace(e.target.name); right before the switch statement like so function overBtn(e:Event):void{ trace(e.target.name); switch(e.target.name){ case"btn1": buttonTween1.play(); break; case"btn2": buttonTween2.play(); break; } } make sure it is tracing btn1 or btn2 unless there is a good reason to use MOUSE_OVER... I would suggest ROLL_OVER instead.
  17. yup, after the stagger amount you can add the the name of the onCompleteAll function like so var nav_array:Array = [logo_mc, work_btn, about_btn, contact_btn, about_mc, breadcrumb_mc] TweenMax.allFrom(nav_array, 1, { x:253, rotation:"40"}, 0.1, setMainNavBtns);
  18. nothing to worry about. it happens to me all the time
  19. cool thanks! here you Go! function fl_ClickToGoToWebPageS(event:MouseEvent):void { yourTimeline.currentProgress = 0.9; } should be function fl_ClickToGoToWebPageS(event:MouseEvent):void { yourtimeline.currentProgress = 0.9; } the T should be t in yourtimeline! Carl
  20. hello timaging. I am having difficulty understanding your problem. I am confused by also: also please post the error. from what I can tell, your code: buttonSkipOff.addEventListener(MouseEvent.CLICK, fl_ClickToGoToWebPageS); function fl_ClickToGoToWebPageS(event:MouseEvent):void { yourTimeline.currentProgress = 0.9; } appears to be correct. Perhaps if you rephrase the question with just the elements that are not working I can be of better assistance also if you want yourTimeline to stop when it gets to .9 be sure to add yourTimeline.stop(); to the button code. Carl
  21. doh. i thought the scroller was part of the image
  22. i'm glad you got this resolved and updated the post, although it is puzzling that TimelineMax somehow fixed it. I also don't see how the screenshot proved the existence of a scene that was supposedly missing and causing an error. very strange. I wonder, is stateOutline something that is even capable of having a "scene"? i'm happy that you got it working!
  23. Hello Learner_7n, The car animation you linked to is actually a flash timeline animation. The easiest approach would be: TweenLite.to(some_mc, 1, {x:200}); TweenLite.to(some_mc, 1, {x:400, delay:5}); Carl
×
×
  • Create New...