Animating Curtains Using Predefined Images
Started by Nocek, Jan 19 2008 07:59 PM
5 replies to this topic
#1
Posted 19 January 2008 - 07:59 PM
I have 2 images created in Illustrator one with a stage curtain closed and another with it open. I need to know how to animate them to switch from closed to open when someone clicks a certain link.
#2
Posted 20 January 2008 - 01:15 PM
Obviously, this will only switch them from closed to open. If you want it to be animated, you will have to do that yourself. First, make a movie clip with the first frame being the closed curtain and the second the open curtain. Put a stop action on the first frame and the second frame. Return to the root level and single click the movie clip, open the properties panel, and give it an instance name. Make a button, then use the following code for the button (substituting "instancename" with the movie clip's instance name):
on (release) {
_root.instancename.gotoAndStop(2);
}
on (release) {
_root.instancename.gotoAndStop(2);
}
#3
Posted 20 January 2008 - 06:09 PM
Is there a way to tween the first image to open up so it looks close to the second?
#4
Posted 21 January 2008 - 08:58 PM
Blue_Monkey, on Jan 20 2008, 01:15 PM, said:
Obviously, this will only switch them from closed to open. If you want it to be animated, you will have to do that yourself. First, make a movie clip with the first frame being the closed curtain and the second the open curtain. Put a stop action on the first frame and the second frame. Return to the root level and single click the movie clip, open the properties panel, and give it an instance name. Make a button, then use the following code for the button (substituting "instancename" with the movie clip's instance name):
on (release) {
_root.instancename.gotoAndStop(2);
}
on (release) {
_root.instancename.gotoAndStop(2);
}
So u solved his problem,Thanks to u. You have also solved my problem . I also want to do the same thing on doors.Thax again.
Edited by devils.master, 21 January 2008 - 09:01 PM.
#5
Posted 21 January 2008 - 11:43 PM
In Flash, you can't tween predefined images. Tweens are only for movement, size changes, rotation, or transformations. If you want the opening to be animated, you will have to edit each image. You could have the curtains shrink to the side, but it wouldn't be as fancy as the picture above.
#6
Posted 22 January 2008 - 10:31 PM
Blue_Monkey, on Jan 21 2008, 11:43 PM, said:
In Flash, you can't tween predefined images. Tweens are only for movement, size changes, rotation, or transformations. If you want the opening to be animated, you will have to edit each image. You could have the curtains shrink to the side, but it wouldn't be as fancy as the picture above.
Since I have the images in vector format, can they be used as shapes to tween into eachother?
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users
