Jump to content
Search Community

Carl last won the day on December 24 2023

Carl had the most liked content!

Carl

Moderators
  • Posts

    9,824
  • Joined

  • Last visited

  • Days Won

    546

Everything posted by Carl

  1. nothing jumps out at me. I tried to break my own example many times with different images and always got the proper result. good news is this should work fine: trace(e.target.rawContent.bitmapData.width);
  2. Sorry I wasn't more clear. the code I provided needs to be run after the asset has loaded. do you have an onComplete handler in place?
  3. what you can get is the scale of the rawContent of the loader. using that you can determine the original width in your case: trace(stageProductImageLoader.rawContent.width/stageProductImageLoader.rawContent.scaleX) // output original width
  4. Carl

    RotationY

    Hello Priya, You have posted the same topic twice. please read my response to your original question in: viewtopic.php?f=1&t=5502 Please feel free to elaborate on your problem in the original post. Your issue, as it appears, has very little to do with the GreenSock Tweening Platform to which these forums are dedicated. Perhaps you can elaborate more on the problem or how it relates to the GreenSock tools in the original topic you created. Thanks Carl
  5. define an onComplete handler for your LoaderMax that is handling the load of all your images. that function can then trigger what ever needs to be done once all images are loaded.
  6. strange, I'm out of ideas, but perhaps more info could help. does you XMLLoader have any LoaderItems in it? when the progress does display does it start at 0? or does it jump to say 10% immediately? I'd experiement with putting an onOpen eventListener on you grandLoader and tracing out and "open" message. and also having a simple trace in onProgress (which you probably already have) I'm suggesting this just to narrow down exactly where the delay might becoming from and perhaps rule out any other failures in how the progress is being displayed. Is it possible you just have a slow server? Furthermore, I would suggest testing in Safari: open the activity window and you can see when requests are being made. if auditing is still taking place you will see loading progress show up and then report that they have failed. in Chrome: do an "inspect element" and watch the "network" tab to see when assets actually are requested.
  7. are you doing an auditSize() ? its possible that 5 seconds is the time that each file is being requested to figure out how much needs to load. you can read about his feature here: http://www.greensock.com/as/docs/tween/ ... auditSize() also read tip 8 http://www.greensock.com/loadermax-tips/ in the interactive demo, clear out the estimated bytes for each child asset and select the auditSize option. you will se a live preview of the files being audited. also read tips 9 and 10 on the same page. I'm pretty sure that should clear things up. Enjoy LoaderMax, Carl
  8. the file that you downloaded references and old and out-dated version of GreenSock tweening classes. Please read #2 in the FAQ here: http://www.greensock.com/v11/ and download the appropriate version. links provided.
  9. Here is a link to a very basic sample fla with greensock files http://www.snorkl.tv/snorklpress/wp-con ... -files.zip it should be as easy as opening up the fla and exporting. if it doesn't work, then there is a problem. if it does work, compare it to the file you have and look for differences.
  10. Hi Procrastino, I am having difficulty understanding. perhaps if you post a simplified fla file I can be of more assistance. If adding frames seems to be a solution, i'm guessing that perhaps the timeline where you are running out of frames may need a stop() action somewhere. maybe where you have the code var tlCalor:TimelineMax=new TimelineMax(); tlCalor.appendMultiple([ TweenMax.from(raiosIv1, .5,{x:-340,y:-260}), TweenMax.from(raiosIv2, .5,{x:-95,y:-330}) ],.5, TweenAlign.START,.4); stop() your previous gotoAndStop should make that unnecessary but I really don't know what the trouble is.
  11. if you can post a simplified fla that just contains the basics of what isn't working I can give it a look later tonight. Carl
  12. invalidating the masterTimeline automatically invalidates all the children. so it might just be an order of operations problem for you. maybe rewind all the children before invalidating the master
  13. here is an idea. when you invalidate() a timeline it clears all the starting data. take for instance this very basic example. 1:assume mc starts with an x of 0 2: look at this code var tl:TimelineLite = new TimelineLite(); tl.append(TweenLite.to(mc, 1, {x:100, onInit:init})); function init(){ trace("init"); } stage.addEventListener(MouseEvent.CLICK, restart); function restart(e:Event):void{ tl.invalidate(); tl.restart(); } it simply creates tl with a single tween that moves the mc from an x of 0 to 100. clicking the stage triggers the restart routine. so after it plays through, mc has an x of 100. once you click the stage to restart tl.invalidate() will make the timeline forget that the mc was initially on the stage with an x of 0. the timeline will re-init that tween and say "i have to move mc to an x of 100... but wait, its already there... nothing for me to do!" the init function WILL fire and trace, but there will be no animation to be seen because mc is already where you want it to go. -------- in order to have the timeline play from the beginning AND run the init function: REWIND the timeline BEFORE invalidating it: function restart(e:Event):void{ //rewind by driving playhead back to beginning. tl.currentProgress = 0; tl.invalidate(); tl.restart(); } let me know if that helps. IN ADDITION: you mentioned you did not want to "hardcode" the starting time into a subsequent tween. that's cool. but note: 1:append() automatically puts a tween directly after the previous tween and 2: using insert(), you can specify a dynamic start time like so: tl.insert(TweenLite.to(mc, 1, {x:100})); tl.insert(TweenLite.to(mc, 1, {y:100}), tl.duration) does that help? Carl
  14. Carl

    rotationY

    what you are experiencing is how 3D objects are rendered in relation to the virtual camera which is by default centered. read about Perspective projection: http://www.flashandmath.com/flashcs4/pp/index.html
  15. are you setting suppressEvents:false inside your restart() call? the default is true. http://www.greensock.com/as/docs/tween/ ... l#restart() perhaps showing the ar() function will help people better assist you. if you are removing /adding the object that you are tweening... that seems like it could be problematic. also having onComplete:function(){TweenLite.to(eInvited, 4, {scaleX:1.2})}}), 0.1 seems a bit odd. is there a reason that tween wouldn't just be the next tween appended to your timeline? i'm a bit confused.
  16. i just got your youtube message: here is the as2 version zipped and working. maybe there is something else you can see that is different best, Carl
  17. hey I replied to you on youtube, but incase you don't see that: change this to _root TweenLite.to(_root, 1,{score:45, onUpdate:showScore, ease:Linear.easeNone});
  18. the problem is you have additional frames and keyframes in your timeline. get rid of all of them. or add a stop() action to frame 1 actions. TweenMax.to(imap, 15, {x:"-115", repeat:-1, ease:Linear.easeNone}); this will work fine once you get rid of the extra stuff. also you are taking a bitmap that is 1400 pixels wide and scaling it down to 300 pixels wide. you should resize your map to the size that it should be in flash for the best performance
  19. i downloaded the swf that you posted. it runs the same with the same bad jump in the browser, or as a standalone swf. you can zip your files and attach them to any message you post. i've found on a mac, the swf preview you get in Flash, performs slower/worse than it plays in most browsers. so I would develop with browser performance in mind.
  20. Carl

    Coin Bounce

    here is a quick attempt: import com.greensock.*; import com.greensock.easing.*; var tl:TimelineMax = new TimelineMax({repeat:10, repeatDelay:1}) tl.insertMultiple([ TweenMax.from(star, .3, {scaleX:.5, scaleY:.5}), TweenMax.to(star, .5, {x:"50", ease:Circ.easeOut}), TweenMax.to(star, .5, {y:"20", ease:Back.easeIn}), TweenMax.to(star, .1, {scaleY:.7, scaleX:1.1, repeat:1, yoyo:true, delay:.5}) ]) tweak some of the timing and scaling to suit your purposes. the Back.easeIn on the y makes the star jump up a bit. a bezierThrough might work better here.
  21. try calling desactivarBotoes onStart. or just put it under the line of code for your pen spin tween. desactivarBotoes should only deactivate the buttons and not move your textfield around. by separating that functionality into different functions you will avoid these conflicts. as for the textfield and font embedding, just place the textfield on the stage and do the embedding through the properties panel
  22. good question. the childTimeline will play regardless of whether or not it is in a master timeline. by putting it in the master timeline you gain the ability to tell the master timeline to pause() or reverse or adjust the playback rate with timeScale and then all the child timelines will obey. if in the future you wanted to stop all the animations or control them all, you can do it through masterTimeline. Carl
  23. you want to tween TO a value that has the second map displaying almost in its entirety, then when the tween repeats it starts with the first map displaying 100%. my method will most definitely work with a mask. you just have to make sure your animation starts with the first map fully visible and then tween until the 2nd map is almost completely visible.
  24. the main probelem is that your instances are box1 - box5 but you look starts counting at 0 so the first childTimeline you create is trying to tween box0... which doesn't exist. attached is a working file : Flash Cs4 Carl
  25. Carl

    Coin Bounce

    if you could post a link to a video, that would be great. I get freaked out when facebook apps ask for access to my information.
×
×
  • Create New...