Forum Topic: The many mysteries of Flash!

(473 views • 6 replies)

This topic is 1 page long.

<< < > >>
None

GRIMRIPPER

Reply To Post Reply & Quote

Posted at: 3/3/03 10:12 PM

GRIMRIPPER EVIL LEVEL 12

Sign-Up: 03/18/02

Posts: 75

This thread is for everyone. Be sure to go in number order when posting your questions!

If you truly know the answers to any of these questions, put what number you are answering next to your post.

1. How do you use a part of a movie clip? (Like the clip is 100 frames, and u want to use frames 42 through 78)

2. How do you use part of an mp3? (Same example as #1)

3. How do you make an audio on/off button? (Like the one that the had on the portal a long time ago that went: do do do DO do..do do...dododo...etc...)

4. How exactly do u make a damn preloader? (And don't give me that "Well they already have one on NG!" shit!)

5. How do you make text fade in and out?

6. Is there an easier way to relocate a sprite(GIF) without going through every single damn frame and changing the X and Y factors individually?


Thinking

gorman2001

Reply To Post Reply & Quote

Posted at: 3/3/03 10:32 PM

gorman2001 NEUTRAL LEVEL 14

Sign-Up: 08/18/02

Posts: 1,879

At 3/3/03 10:12 PM, GRIMRIPPER wrote: This thread is for everyone. Be sure to go in number order when posting your questions!

If you truly know the answers to any of these questions, put what number you are answering next to your post.

1. How do you use a part of a movie clip? (Like the clip is 100 frames, and u want to use frames 42 through 78)

2. How do you use part of an mp3? (Same example as #1)

3. How do you make an audio on/off button? (Like the one that the had on the portal a long time ago that went: do do do DO do..do do...dododo...etc...)

4. How exactly do u make a damn preloader? (And don't give me that "Well they already have one on NG!" shit!)

5. How do you make text fade in and out?

6. Is there an easier way to relocate a sprite(GIF) without going through every single damn frame and changing the X and Y factors individually?

If you're mishing that your 5 would be answered, here u go:

1- Select the text you wanna fade;
2- Once selected, press F8, choose the behavior "Graphic", and give a name;
3- Select your text symbol, right-click, select "Properties", then reduce the alpha from 100% to 0%;
4- Go to, let's say, 20 frames forward and press F6;
5- In this new keyframe, reselect your text symbol, right-click, select "Properties", then set back the alpha to 100%.
6- Go ONE frame backwards, right-click on its square on the Timeline and select "Create Motion Tween".

That'S all.


None

AngryBinary

Reply To Post Reply & Quote

Posted at: 3/4/03 12:28 AM

AngryBinary EVIL LEVEL 06

Sign-Up: 02/18/03

Posts: 255

6. Is there an easier way to relocate a sprite(GIF) without going through every single damn frame and changing the X and Y factors individually?

1- Create a blank layer in the MC, and make keyframes in each frame that you'd want to start and stop from (say, if you have a section of a movie clip that just shows a guy walking, go to the start of that segment, make a blank keyframe in the blank layer, and label the frame "walkStart". then another at the end of that segment, name it "walkEnd"). In the walkEnd frame, either set it up to loop (gotoAndPlay("walkStart");) or to stop (stop();) or something to keep it from rolling further. When you want to play that segment, use gotoAndPlay("walkStart"); in the movie clip actions, or CharName.gotoAndPlay("walkStart") in the main timeline.

2- To use part of an MP3, you can set an offset in the "start" command in actionscript, which uses the syntax

someSound.start(offset, loops);

this assumes you've exported the MP3 object in the linkage window (right click the symbol in the library), created a sound object "someSound" and attached a sound to it... like this...

someSound = new Sound();
someSound.attachSound("exportedMP3name");

So to skip the first 12 seconds, use

thisSong.start(12, 1);
music = "on"; //for the next example
Then, simply stop the sound in the frame you want it to end, or after a certain number of frames. To stop after a certain number of seconds, multiply seconds by the framerate.

thisSong.stop();

3- Continuing the previous example, to make an audio ON/OFF button, put this action in the button:

this.onRelease = function(){
if (music=="on"){
_root.thisSong.stop();
music="off";
} else {
_root.thisSong.start();
music="on";
}
}

4- I've just put this up on another post, but i'll do it here since it'd be nice to have all the scripts together...

Make a seperate Scene (from menu:insert... scene) for the preloader, and use the scene editor to place it before the main scene (from menu:windows... scene), and rename it Preloader. In the first frame, make a dynamic text field called "percentLoaded", and a movie clip called "loadbar1" that contains just a rectangle (it'll grow horizontally as the movie loads). Make sure that "loadbar1" is the instance name (properties), too. This action goes in the first frame of the main timeline:

_root.onEnterFrame = function() {
lBytes = _root.getBytesLoaded();
tBytes = _root.getBytesTotal();
allBytes = Math.floor(tBytes/1024);
percentLoaded = Math.floor((lBytes/tBytes)*100);
loadbar1._xscale = percentLoaded;
percent.text = percentLoaded+"% of "+allBytes+"K loaded.";
if (lBytes>=tBytes) {
gotoAndPlay("Scene 1", 1);
}
}

and this goes in the second frame:

gotoAndPlay(1);

6- To relocate sprites and such, make them movie clip symbols. Put them all in seperate layers. Keyframes can be motion tweened each other, just put it in one spot in one keyframe, and then another in another keyframe, right click on the first keyframe and "create motion tween".


None

ValorXII

Reply To Post Reply & Quote

Posted at: 3/4/03 04:27 AM

ValorXII LIGHT LEVEL 03

Sign-Up: 07/03/02

Posts: 52

"1. How do you use a part of a movie clip? (Like the clip is 100 frames, and u want to use frames 42 through 78)"

Copy and paste the frames in the timeline.

2. How do you use part of an mp3? (Same example as #1):"

You could use a free sound edit program like 'Audacity'.


None

GRIMRIPPER

Reply To Post Reply & Quote

Posted at: 3/4/03 04:26 PM

GRIMRIPPER EVIL LEVEL 12

Sign-Up: 03/18/02

Posts: 75

7. How do you make pictures fade? (I'm guessing it is the same way as text.)

8. How do you make the background scroll? (I have no idea what this question is really asking, someone asked me to ask it here.)


None

StarCleaver

Reply To Post Reply & Quote

Posted at: 3/4/03 10:14 PM

StarCleaver LIGHT LEVEL 29

Sign-Up: 01/03/03

Posts: 10,103

for number 2 i use CDEX for converting the MP3s to .wav and then you can edit them in the windows sound recorder.

I could surely die
If I only had some pie
Club-a-Club Club, son

BBS Signature

None

Cominatcha

Reply To Post Reply & Quote

Posted at: 3/5/03 01:00 AM

Cominatcha LIGHT LEVEL 10

Sign-Up: 02/16/03

Posts: 687

lol didnt feel like reading but for number three audio buttons just make a button when on press use the actionscript stop all sounds its under control>movie control on the pre made as menu


All times are Eastern Standard Time (GMT -5) | Current Time: 09:18 AM

<< Back

This topic is 1 page long.

<< < > >>
You need a Grounds Gold Account to post on the NG BBS! If you don't have one, click here to sign up now! It's fast, free, and easy — and opens up tons of great NG features!