Jump to content
Search Community

isaacalves

Members
  • Posts

    30
  • Joined

  • Last visited

Everything posted by isaacalves

  1. Hi, a colleague at work has created a simple class for visualizing big images (that exceed the dimensions of its container, that could be the stage or whatever movieclip) with the ENTER_FRAME event. Here is the main function of the class: protected function onUpdateMouse(e:Event):void { _posx = ((_hit.mouseX - _size.x) / _size.width) * (_size.width - _content.width) + _size.x; _posy = ((_hit.mouseY - _size.y) / _size.height) * (_size.height - _content.height) + _size.y; _posx = Math.min(_size.x, Math.max(_posx, _size.width - _content.width + _size.x)); _posy = Math.min(_size.y, Math.max(_posy, _size.height - _content.height + _size.y)); TweenLite.to(_content, _time, { x:_posx, y:_posy, ease:Expo.easeOut}); } To make it smooth, he calls a Tween in the ENTER_FRAME handler , instead of using _content.x = _posx; and _content.y = _posy. The problem is that when the ENTER_FRAME listener is added, some other tweens on the page won't complete, for example, some alpha tweens (even in others swfs) that should go to 1 were stopping on the middle, as well as Tint tweens. I changed the ENTERFRAME event to MOUSE_MOVE Event and it seems that it runs even worse. I imagine that is not a very good idea to add Tweens continously each frame or as the mouse moves cause it will be creating a bunch of tweens. So, any ideas of best practices about the subject ? Thanks in advance!
  2. Yes, 3.2.3. I actually solved the problem by switching back to the previous version of TweenLite/TimelineLite. I got a very short deadline. But I hope I can help you with that!! By the way, I can´t want to try LoaderMax ! It sounds really nice. Thanks!
  3. Thank you greensock. I´m not sure if I got what you meant... but I´ve updated the last version of greensock, from the website, then I replaced in my main actionscript files folder (which is included in my projects files source paths) as well as in the 'src' folder of my projects which is automatically generated by Gaia. And I still get this error ... ReferenceError: Error #1069: Propriedade cachedOrphan não encontrada em com.greensock.TweenMax e não há valor padrão. at com.greensock::TimelineLite/addChild() at com.greensock::TimelineLite/insert() at com.greensock::TimelineLite/insertMultiple() at com.greensock::TimelineLite/appendMultiple() Though in another project, It seemed to me that I solved this problem by 'deleting ASO files' from the Control Menu in Flash. how could I fix that ? could there be something wrong with this code ? mainTimeline = new TimelineLite(); mainTimeline .appendMultiple([ TweenLite.to(bar.base, 0.4, {width: stage.stageWidth, scaleY: 1, ease:Quint.easeOut}), TweenLite.to(bar.novidades, 0.4, {x: xBar[0], alpha: 1, ease:Expo.easeOut}), TweenLite.to(bar.vida, 0.4, {x: xBar[1], alpha: 1, ease:Expo.easeOut}), TweenLite.to(bar.pub, 0.4, {x: xBar[2], alpha: 1, ease:Expo.easeOut}) ], 0.3, TweenAlign.SEQUENCE, -0.2); or this one? novTL.appendMultiple([ TweenLite.to(mc3, f, {y: 100}), TweenLite.to(bar.novidades.hit, f/10, {height: 500}), TweenLite.to(mc3, f, {y: 140, ease:Back.easeIn}), TweenLite.to(mc3, f/10, {autoAlpha: 0}), TweenLite.to(mc, f, {rotationX: 360}), TweenLite.to(mc2, f/10, {autoAlpha: 1}), TweenLite.to(mc2, f/10, {y: -140}), TweenLite.to(mc2, f, {rotationX: 360}), TweenLite.to(mc3, f/10, {y: -280, autoAlpha: 0}), TweenLite.to(mc3.container, f/10, {rotationX: 180}), TweenLite.to(mc3, f/10, {autoAlpha: 1}), TweenLite.to(mc3.container, f, {rotationX: 360})], 0, TweenAlign.SEQUENCE, 0); thanks !
  4. I´ve been having this error: ReferenceError: Error #1069: Propriedade cachedOrphan não encontrada em com.greensock.TweenLite e não há valor padrão. at com.greensock::TimelineLite/addChild() at com.greensock::TimelineLite/insert() at MethodInfo-784() at hype.framework.core::MultipleObjectPool/request() at hype.framework.core::MultipleObjectPool/requestAll()..........etc "property cachedOrphan not found in com.greensock.TweenLite..." I upgraded Gaia Flash Framework to 3.2.3 and it automatically upgraded GreenSock to 11.38 (as in Gaia Panel), which is weird cause on GreenSock page it seems that the latest version is 11.36. does anyone kjnow what´is going on here ? Thanks in advance!
  5. how can i cancel an existing delayed tween when i create another tween that tweens the same object´s propoerty? for example, i have: private function showPopUp():void { var inpopup:TweenLite = new TweenLite(popup, 0.25, {alpha: 1, ease: Linear.easeIn, onComplete:function() { var outpopup:TweenLite = new TweenLite(popup, 0.25, {alpha: 0, delay: 3.5, ease: Linear.easeIn}); } }); } that function is called in different situations, to show a popup with some text. i´ll try to say it simple : let´s say the popup mc pops in and before it pops out, i tell him to pop in again, let´s say, after 3 seconds. then the popup mc pops out within 0.5 seconds, instead of 3.5. shouldn´t it overwrite "itself" ? i get confused. its "overwrite" property defaults to true, right? i´ve tried already in different manners, for example, by only creating a new tween instead of declaring it into a variable. obs: it works well in my computer but not in the server !!! help!
×
×
  • Create New...