Jump to content
GreenSock

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

ContraMuffin

Members
  • Posts

    6
  • Joined

  • Last visited

ContraMuffin's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. Ah, thank you! I did not know either of these things. And I probably would not have known them had you not told me. Is it possible to run tweens at the same time instead of in sequence? For example, if I have 5 tweens, 1, 2, 3, 4, and 5, can I make them run in sequence except 2 and 3, which are run together? Also, can I place non-TimelineLite, normal AS3 commands into the timeline?
  2. This is the zipped .fla file that shows the object (sdf) popping to alpha:100 Untitled-4.zip
  3. Ah, OK. That gives me some insight as to how to fix the issue. Should I use a "to" tween instead of a "from" tween and set the alpha to 100? I just did, and I can see that the object CAN be tweened once again, but I now have another issue. Instead of performing a tween, the object just kind of pops to alpha:100. I have posted a a zipped .fla file of what I mean.
  4. While using Greensock, I realized that an object can't be tweened more than 2 times. I haven't tested the parameters of this, but I think that once I do a TweenMax.to tween, I can't tween that object anymore. It does not give me an error, but the tween simply does not happen. An example of the TweenMax.to tween that I use is TweenMax.to(object,1,{alpha:0}); and I'm trying to create a TweenMax.from tween like this TweenMax.from(object,1,{alpha:0}); Is there a way to TweenMax.from tween that object again, and if so, how? EDIT: OK I just tested, and that is what happens. The object no longer tweens whenever I use a TweenMax.to tween on it.
  5. Hello, I'm kind of new to Greensock (and Flash in general), so sorry if it's a stupid mistake. I'm trying to create a textbox (like in games). I fumbled around with the code until it runs properly. However, once I move onto the third frame, the Output panel gives me an error. Error: Cannot tween a null object. Duration: 0.3, data: undefined at com.greensock::TweenLite() at com.greensock::TweenMax() at com.greensock::TweenMax$/to() at textbox_fla::MainTimeline/myKeyDown() TypeError: Error #1009: Cannot access a property or method of a null object reference. at com.greensock::TweenMax/render() at com.greensock.core::SimpleTimeline/render() at com.greensock.core::Animation$/_updateRoot() This is strange, since the function "myKeyDown" is in frame 1. I do not understand why Greensock would throw me an error, since the function is not a functionality of Greensock (it's just a regular AS3 code) . Anyways, here is the code on frame 1. import com.greensock.*; import flash.events.KeyboardEvent; stop(); TweenMax.from(instruc,1,{alpha:0}); TweenMax.from(char1,0.3,{x:"-400"}); TweenMax.from(box, 0.5, {x:"-100", alpha:0}); textbox.visible = false; TweenMax.delayedCall(0.5, myFunctionL); function myFunctionL():void{ textbox.visible = true; TweenMax.from(textbox, 0.3, {x:"-10", alpha:0}); } stage.addEventListener(KeyboardEvent.KEY_DOWN, myKeyDown); function myKeyDown(e:KeyboardEvent):void{ if(e.keyCode == 32){ TweenMax.to(textbox,0.3,{x:"10",alpha:0}); TweenMax.to(char1,0.3,{x:"-400"}); TweenMax.delayedCall(0.3,frame); function frame():void{ nextFrame(); } } }
×