Jump to content
Search Community

moxol last won the day on August 29 2012

moxol had the most liked content!

moxol

Members
  • Posts

    63
  • Joined

  • Last visited

  • Days Won

    1

moxol last won the day on August 29 2012

moxol had the most liked content!

moxol's Achievements

2

Reputation

  1. Thanks, I overlooked that total means including repeats.
  2. Can you explain me what is the difference between progress, totalProgress, duration, totalDuration, time, totalTime methods? Is this a good way to complete timeline while it's playing? timeline.seek(timeline.totalDuration());
  3. I am using v12. This could do, but I already found different solution, you can tell me if it's alright. timeline.append(tween1); timeline.append(tween2); timeline.addLabel("tween3", timeline.duration()); timeline.append(tween3); timeline.append(tween4); and to forward I do: timeline.gotoAndPlay("tween3", false);
  4. How do I do forwarding to specific tween in timeline? If I have: timeline.append(tween1); timeline.append(tween2); timeline.append(tween3); timeline.append(tween4); and I want to forward to tween3, how to do that? Also, tween1 and tween2 have tween events that need to be completed before forwarding.
  5. I didn't say it's bad, but for some serious interactive app, it's not. I was using relatively small number of FXG's in relatively complex MXML, and choppy animation is noticable, slower response to starting animation when mouse clicked... That slower performance has to do with event dispatching mostly, and redrawing of FXG's, even though I used as much performance tweeking I could. It's not due to GSAP, which probably is the best solution, but rather Flash not up to task.
  6. I was wondering if anyone has experience in using GSAP in MXML and Sprite so that comparison can be made in performance. I am working at the moment with MXML and I didn't have chance to try GSAP only in Sprite, and I can say that I am not very pleased with speed of executing tweens. I know that there are many factors that can slow down executing tweens, particularly in Flash runtime, but as it stands now, I think that using GSAP in MXML is limited to simpler work, to what extent, I don't know yet.
  7. That is working, but still if I do that, object's movement is again choppy meaning object would jump to 100 and continue to 300, even though code finishes before tween twe starts. Why?
  8. Can you help me with this example: <?xml version="1.0" encoding="utf-8"?> <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" xmlns:s="library://ns.adobe.com/flex/spark" xmlns:mx="library://ns.adobe.com/flex/halo" click="starts()"> <fx:Declarations> <!-- Place non-visual elements (e.g., services, value objects) here --> </fx:Declarations> <fx:Script> <![CDATA[ import com.greensock.data.TweenMaxVars; import com.greensock.TweenMax; import com.greensock.events.TweenEvent; import com.greensock.TimelineMax; private var timeline:TimelineMax = new TimelineMax(); private function starts():void { var tweenMaxVars1:TweenMaxVars = new TweenMaxVars(); var twe1:TweenMax = new TweenMax(obj, 10, tweenMaxVars1); twe1.addEventListener(TweenEvent.START, write); var tweenMaxVars:TweenMaxVars = new TweenMaxVars(); tweenMaxVars.x(300); var twe:TweenMax = new TweenMax(obj, 5, tweenMaxVars); timeline.append(twe1); timeline.append(twe); } private function write(event:TweenEvent):void { for (var counter:Number = 0; counter < 3000; counter++) { trace('beforeStart') } trace("finished"); TweenMax(event.target).progress(1); } ]]> </fx:Script> <s:Label id="obj" text="object"/> </s:Application> I tried to end tween twe1 with TweenMax(event.target).progress(1) so that it ends when for command ends, but that doesn't work. How to do that?
  9. I don't mind if 3rd tween finishes 0.1 seconds later, that's not important. Lets make it this way. Can I insert empty tween with duration 0.1 between 2nd and 3rd that will do the code, because I tried that and rendering of 3rd tween still is choppy.
  10. I have a tweens that are in timeline and I need to execute code before one tween in timeline that is going to start after some tweens. Because that tween duration is 0.3 seconds, code that is in TweenEvent.START listener disrupts rendering on screen, so I don't need huge gap, just maybe 0.1 seconds. So for example I need this: TIMELINE: 1. Tween 2. Tween 3. Tween 4. Code 5. Tween
  11. I understand how it works. First solution is no good for me because frame rate can seriously drops and tween must finish in time. Second solution is also no good for me beacuse I don't know when I need to call write() function, if we are looking at real scenario for my app, because there are other tweens, and I just need something like Pre-start event. Can some plugin be written?
  12. On screen object moves from 0 to 70-80 and continues to 300, It doesn't smoothly goes to 300.
  13. Here is example I tried: <?xml version="1.0" encoding="utf-8"?> <s:Application xmlns:fx="http://ns.adobe.com/mxml/2009" xmlns:s="library://ns.adobe.com/flex/spark" xmlns:mx="library://ns.adobe.com/flex/halo" click="starts()"> <fx:Declarations> <!-- Place non-visual elements (e.g., services, value objects) here --> </fx:Declarations> <fx:Script> <![CDATA[ import com.greensock.data.TweenMaxVars; import com.greensock.TweenMax; import com.greensock.events.TweenEvent; import com.greensock.TimelineMax; private function starts():void { var timeline:TimelineMax = new TimelineMax(); var tweenMaxVars:TweenMaxVars = new TweenMaxVars(); tweenMaxVars.x(300); var tweenMaxVars1:TweenMaxVars = new TweenMaxVars(); tweenMaxVars1.onStart(function():void { write(); }); tweenMaxVars.startAt(tweenMaxVars1); var twe:TweenMax = new TweenMax(obj,2, tweenMaxVars); timeline.append(twe); } private function write():void { for (var counter:Number = 0; counter < 3000; counter++) { trace('beforeStart') } } ]]> </fx:Script> <s:Label id="obj" text="object"/> </s:Application> I need that write() function executes completely before tween starts. In this example you can see that tween starts while write() function is still executing, which is what I don't want to happen.
  14. I need to execute some code just before tween starts and then let tween play. I was using TweenEvent.START but actually I need before it starts, some event like PRE-START, STARTING... How to do that?
  15. If I have timeline.stop() how to detect that it's stopped?
×
×
  • Create New...