There is probably a tutorial on the matter but where? what I want to do is: ie: a birthday present wrapped and when the viewer clicks on it he sees what is inside; easy you may say, it can be done with a button, trouble is with a button when you move the mouse away from it it reverts to the first image; I want it to stay open then do other presents the same way until they are all showing the contents. Is it that difficult?
Well it seems I am doing something very wrong, this movie clip thing; in your example Wizard, in the library the movie clip has a little arrow and when you click on it it shows what the movie clip is; mine doesn't so I probably didn't make the movie clip properly; just as well it rains a lot here, because learning Flash takes ages!
Actually now that I think about it, xfykzz is right. Using Movie Clips instead of buttons is the quicker and easier way to go. I've created a new file.
Fine this movie clip, if... I could do it! I don't know how; What I am doing:
1.File/ new
2.import - box (present) -
3. the box is in the left corner of the stage, so I put it in the middle.
4. with it selected, I do: Insert/convert to symbol, name: box, tick movie clip,
5. edit/edit document.
So it is in the library as a movie clip, that is the pic with a little circle in the middle. no little arrow.
Also how do you get your "present" to split in four? I think that is cool.
I just did a simple Shape Tween. You create a Shape Tween the same way you would create a Motion Tween. Except you change it from Motion to Shape in the Properties Panel. I rarely use Shape Tweens and I don't want to give you the wrong information. As far as the steps you listed, everything seems to be right. You create the animation (present opening, etc.) inside the Movie clip and then you give a Frame Label wherever the animation will begin and you use it in the AS.
code:
on (press){
this.gotoAndPlay("frameLabel");
}
My animation (box splitting) was a crappy example. If you take the time, you can create something 10x better whether it's frame by frame or a clever usage of Motion/Shape tweens. Good Luck!
Forget about the box splitting for the moment; one thing at a time; I still don't understand how to create the animation inside the movie clip; Frame label? I have looked at your example more than once and I can't understand how it is done. You have nothing written in your frame label, and there appears to be only one frame in the timeline; could you please explain step by step how to this, present/surprise; I am sorry to be such a nuisance.
Perseverance is my only virtue.
No, you're not a nuisance. You're just eager to learn I guess.
Double click on one of the boxes, so you'll be in symbol editing mode. There you'll see everything, the frame label, the animation. I can't give you too much of an explanation right now, but I will as soon as I get home.
Here's an example that uses what you already know(even if you don't realize it.
it's very basic but, is also very entertaining.
1st when you want to make a movieclip (MC). create it right on the "stage". then select it, right click on it and choose "convert to symbol" choose movie clip, and name it. now you have the MC already on the stage.
Now, right click your MC and choose "edit in place". you'll notice that you get a new timeline. that timeline is for your MC and the 1st key frame is already exposed with the art work you created on the stage.
this method is a way good seeing your MC and the stage at the same time. you can always just "edit" the MC by itself by choosing "edit" instead of "edit in place". your MC was automatically placed in your library when you 1st created it.
the example I gave you is a MC with a button inside of it. the "bow" is a button and the "up state" is the bow you see. now the "over state" is just a MC within the button. click the "over" keyframe. and then "rt. click/editin place" you can see the timeline and the animation. that is what makes it pull.
the "present MC" (the one you see on the stage) has a stop action on the 1st frame that stops the MC from playing until you click the button. but the button still is active and that's why when the mouse rolls over it. it plays the MC that I placed in the button.
when the button is released. the buttons actionscript say "on release go to and play "OPEN" it goes to the next frame of the "present MC". I labeled the frame "OPEN" and used that label in the buttons action script.) when the button was released the MC plays till the end were I have a keyframe that has actionscript telling the MC to stop playing and hold on the last frame.
down load this and then click on the MC and right click over the MC and start looking at and breaking down what I did. It will start to make more sense.
This present thing is getting more exciting by the minute! I will be glued to my computer, and pestering you all at Flashkit until I can do it. It all started when I received an e-card and wondered how it was done; and I want to do better!
Perseverance etc!
I looked back on some of the posts in this thread. here is the answer to some of your questions.
frame label?
if you open the properties panel and then click on a frame. there is a window in the panel that looks like this,
<frame label>. what you can do is click that window and give that frame a name. in this case I called my frame "OPEN". then when you use buttons to go to a frame. instead of trying to remember, what scene, what frame (counting those little squares on the timeline is a pain). you can give the frame a name and then when you want to have Flash to go to it. you can just tell it by it's name. more friendly.
As far as seeing just 1 frame in the "scenes" timeline. (note that MC's have timelines of their own). that is so you can have a held backround while you have MC's running. kind of like going to a 3 ring circus and even though you're under one tent, something is going on in all three rings at the same time.
Well I have been paddling with this thing for days; it's working but it isn't right; I have all this stuff in the timeline, when all you have is one miserable keyframe; and that is for one present, when I do my Xmas card I want lots of presents all different; so can you, please, have a look and tell me what is wrong? thanks,
It still doesn't tell me why I have 3 layers on the main timeline when in yours to see what goes on I have to right click; also in your example I can copy and paste one of the boxes and it works whereas I can't in mine; what's more Sanchini's example works in the same way as yours Wizard; is it going to create problems when I put lots of different presents on the stage? I want all the presents to be present! at the beginning and then for the viewer to open them one at a time with a click.
Ohhh, that's because in my file they where in Movie Clips. That's why you would only see one frame. All the frames where inside the Movie Clip itself. You say that in my file you can copy them, that's because you're really just copying the movie clip. It won't create problems and actually it'll make it easier to make them all present at the first frame. The way you where doing it you would've had to add many layers to be able to see em' all.
Take the present, prior to any animation, and make it a Movie Clip Symbol. Then you can do the animation inside the MC.