Go Back   CodingForums.com > :: Client side development > Flash & ActionScript

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 03-10-2007, 11:04 PM   PM User | #1
Acid
Regular Coder

 
Join Date: Jun 2004
Posts: 194
Thanks: 5
Thanked 0 Times in 0 Posts
Acid is an unknown quantity at this point
Remove Play Button - Make Video Auto Play

This is most likely a really stupid question but I've never used flash before so I have no idea how to do this (had a look around but cant find anything for how to do it).

I have a flash movie that does its "loading" thing when its first opened, then brings up a play button which when clicked plays the actual movie. What I want to do is simply take out the play button so that when the file is opened it does its loading thing and once loaded process straight to playing the main movie without needing to click anything. I deleted the play button itself but then nothing happens after the movie loads, I'm guessing this might need to be done with ActionScript but I dont know that at all.

Any help would be great, cheers.
Acid is offline   Reply With Quote
Old 03-11-2007, 12:17 AM   PM User | #2
StupidRalph
Senior Coder

 
Join Date: Mar 2003
Location: Atlanta
Posts: 1,037
Thanks: 14
Thanked 30 Times in 28 Posts
StupidRalph is on a distinguished road
Try opening your movie. There might be a layer named "Actions". If so, select that layer and open up the ActionScript window. Copy and paste the actionscript here for more help.

Deleting the play button does nothing from an actionscript standpoint. It simply means that you deleted the instance which invokes the play action. (if that makes any sense )
__________________
Most of my questions/posts are fairly straightforward and simple. I post long verbose messages in an attempt to be thorough.
StupidRalph is offline   Reply With Quote
Old 03-11-2007, 07:36 PM   PM User | #3
The_Anomaly
New to the CF scene

 
Join Date: Mar 2007
Location: Albania
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
The_Anomaly is an unknown quantity at this point
I'm not all that experienced in flash, but in my experience the video should automatically play. What would stop it from doing so would be the script "
Code:
stop();'
And some other code saying that when you press the button it will go. And you'd just eliminate this code for it to start automatically.

Of course, all developers have their own way of coding things...so it's very possible it wasn't done like that.

Try copying the actionscript in here if that doesn't fix your problem
The_Anomaly is offline   Reply With Quote
Old 03-28-2007, 04:09 PM   PM User | #4
Acid
Regular Coder

 
Join Date: Jun 2004
Posts: 194
Thanks: 5
Thanked 0 Times in 0 Posts
Acid is an unknown quantity at this point
Thanks for the replies, I figured there would be ActionScript behind this but for the life of me I can't find it anywhere. I'm a PHP programmer but haven't got the first clue when it comes to Flash so I bought a pre built flash intro of a site and got the source and have been gradually working through modifying it, can't see the ActionScript anywhere though (either as an external file or within any of the layers) so I'm a bit stuck on that one.

On the subject of ActionScript however I do have another question, for this same movie, once the intro has finished playing I essentially want it to redirect to another web page, so for instance you'd be on www.whatever.com (index.html) where the intro would play and after its finished playing it would forward you to www.whatever.com/index.php for the main site, seen it done before and I imagine this is using ActionScript. Could do this by doing a timed forward but thats a real dirty way of doing it IMO and would be kind of hit and miss since you have to factor in download times for people on different connections.
Acid is offline   Reply With Quote
Old 03-29-2007, 02:05 PM   PM User | #5
StupidRalph
Senior Coder

 
Join Date: Mar 2003
Location: Atlanta
Posts: 1,037
Thanks: 14
Thanked 30 Times in 28 Posts
StupidRalph is on a distinguished road
Add a new layer to your movie.
Name it 'ACTIONS'
Lock the layer by clicking the padlock
Create a keyframe on the last frame of the movie in the 'ACTIONS' layer
(do this by selecting the frame and by simply pressing F6.)
Open up the actionscript panel and add the following code.

Code:
getURL("http://www.whatever.com/index.php","_self");

As far as finding the actionscript:

If you were to open the actionscript panel and look on the left side. It should show which layers and corresponding frames have actionscript code in them.

Also is it possible to post the .fla file so we can get a peak?
__________________
Most of my questions/posts are fairly straightforward and simple. I post long verbose messages in an attempt to be thorough.
StupidRalph is offline   Reply With Quote
Old 03-29-2007, 06:10 PM   PM User | #6
Acid
Regular Coder

 
Join Date: Jun 2004
Posts: 194
Thanks: 5
Thanked 0 Times in 0 Posts
Acid is an unknown quantity at this point
Cheers for the info Ralph, will give that a try. Will try and post up the fla when I get home (assuming my PC has decided to behave itself), at work at the minute.
Acid is offline   Reply With Quote
Old 03-31-2007, 10:44 PM   PM User | #7
rvchuck
New Coder

 
Join Date: Jan 2007
Location: Left Coast
Posts: 71
Thanks: 3
Thanked 1 Time in 1 Post
rvchuck is an unknown quantity at this point
Change Flash auto play

Open the .fla file and click on the parameters tab.
You will see auto play set to false.
Click on that row, and it will change to a drop down menu.
Drop it down, select true, save and re-export movie.
This is for flash 8 but should be close for other versions.
You shouldn't need to get into the action script section for this but you will for your other request.
This will change the script for you when you export the movie.
Hope that helps.
rvchuck is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 06:50 AM.


Advertisement
Log in to turn off these ads.