Multi-Gaming Community
It is currently 28 Apr 2024, 14:42

All times are UTC+02:00




Post new topic  Reply to topic  [ 30 posts ] 
Author Message
gb 
 Post subject: FLASH
PostPosted: 17 Jan 2011, 15:04 
Offline
is Wonder Woman (5950)
User avatar
Anyone out there know Flash? I just need a heads up on something. I've got a short animation (flv) that's an intro to a website, once finished it should go straight to the landing page. Any ideas on some action script on how to get it from the end of the intro to the landing page?

Here's a demo of what I mean:

Sony Home Page

_________________
Classy is when a woman has everything to flaunt, but chooses not to show it!


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 17 Jan 2011, 15:49 
Offline
Has no REAL life! (8841)
User avatar
Which version? AS2 or AS3?

_________________
-"You've really worked out your banter, haven't you?"
-"No, not really. This is a different thing, it's spontaneous and it's called wit."


Last edited by ProtectMyBalls on 17 Jan 2011, 16:12, edited 2 times in total.

Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 17 Jan 2011, 16:03 
Offline
is Wonder Woman (5950)
User avatar
AS3 would be better seeing as most Flash players are on v10

_________________
Classy is when a woman has everything to flaunt, but chooses not to show it!


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 17 Jan 2011, 16:13 
Offline
Has no REAL life! (8841)
User avatar
For AS3, put below on the first frame
Code:
var url:URLRequest = new URLRequest("http://web.address.goes.here"); 
URL_button.addEventListener(MouseEvent.CLICK, onStageClick); 

function onStageClick(event:MouseEvent):void 
{ 
navigateToURL(url, "_self); 
}

For AS2, put his on first frame.
Code:
getURL("http://web.address.goes.here","_self");
As for the mask (sony O), i guess thats action script as well, but not too sure how, im sure actionscript website might help. I asked the web guy at work, but is a bit too busy atm to explain it :S

_________________
-"You've really worked out your banter, haven't you?"
-"No, not really. This is a different thing, it's spontaneous and it's called wit."


Top
   
nl 
 Post subject: Re: FLASH
PostPosted: 17 Jan 2011, 16:25 
Offline
Has no REAL life! (1620)
User avatar
Set everything (apart from flash) to visibility:hidden in css
Set wmode to transparent on the flash
Have javascript (I recommend jquery) waiting for a call from the flash set all objects to visibility:visible

That means you never have to use Ball's code though, cause you never leave the page.

Wait all that's flash?

Set up the site in another scene or another frame and use goto?

_________________
swedishnitro wrote:
I take it all back. FFFFFFUUUUUU cardboard!!!!!


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 17 Jan 2011, 16:34 
Offline
Has no REAL life! (8841)
User avatar
And listen to cardboard as he is probably better at it than me :(

_________________
-"You've really worked out your banter, haven't you?"
-"No, not really. This is a different thing, it's spontaneous and it's called wit."


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 17 Jan 2011, 16:40 
Offline
is Wonder Woman (5950)
User avatar
The landing page isn't flash, although in the Sony example it is. So whatever is the easiest option for when the flash animation finishes it goes straight to the landing page.

_________________
Classy is when a woman has everything to flaunt, but chooses not to show it!


Top
   
nl 
 Post subject: Re: FLASH
PostPosted: 17 Jan 2011, 16:44 
Offline
Has no REAL life! (1620)
User avatar
Easy or Slick?

Easy is use Balls way and just force flash to make a HTTP call,

Slick is do it some other way that takes a bit more time but is ultimately more interesting (my way).

I'm gonna take a wild guess and say that masks are still done in the same way, and its a layer option like it is in photoshop the only difference is you can animate them.

I checked and it is. Animate the mask, right click the layer, select mask and then re-order the layers as needed.

Also IRC

_________________
swedishnitro wrote:
I take it all back. FFFFFFUUUUUU cardboard!!!!!


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 17 Jan 2011, 16:48 
Offline
is Wonder Woman (5950)
User avatar
Ok cool. I'll give it a go.

The IRC client is a bit buggy to use at work. If you've sent me a query I'll pick it up on the buffer tonight ;)

_________________
Classy is when a woman has everything to flaunt, but chooses not to show it!


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 17 Jan 2011, 16:51 
Offline
Has no REAL life! (8841)
User avatar
[SpA]cardboard wrote:
Easy is use Balls way and just force flash to make a HTTP call,
Technically not my way as i said it was one of the web guys at work (and probably told me the easy way to stop me bugging him) :P just reposted to make it look like i was being intelelegemenetntent! :ugly:

_________________
-"You've really worked out your banter, haven't you?"
-"No, not really. This is a different thing, it's spontaneous and it's called wit."


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 17 Jan 2011, 16:54 
Offline
is Wonder Woman (5950)
User avatar
Well it seems that Balls' version won't work now :( I've just been told that the animation wasn't done in Flash but saved as an FLV using After Effects! Wish they told me that before, sorry for wasting your time. Any suggestions on what to do with the flv? Will your theory still work cardboard?

_________________
Classy is when a woman has everything to flaunt, but chooses not to show it!


Top
   
nl 
 Post subject: Re: FLASH
PostPosted: 17 Jan 2011, 16:58 
Offline
Has no REAL life! (1620)
User avatar
OK well that puts a different complexion on things. I'd make a containing swf for the flv, it should still play and then you can trigger the http request once the animation has finished playing but that codes a little more complex... and that's something I've not done in a very long time.

both solutions should work as long as you can work out how to trigger an event on the last frame of the FLV from within a conainer

_________________
swedishnitro wrote:
I take it all back. FFFFFFUUUUUU cardboard!!!!!


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 17 Jan 2011, 17:33 
Offline
Has learned to write! (217)
swfobject to embed the flash file then something like

http://www.longtailvideo.com/support/fo ... video-ends

to add a javascript listener for when its finished playing

_________________
Don't worry I got some silicon carrots - [SpA]Bucky O'Hare


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 17 Jan 2011, 17:38 
Offline
is Wonder Woman (5950)
User avatar
Yay I made Frosty post :4

_________________
Classy is when a woman has everything to flaunt, but chooses not to show it!


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 17 Jan 2011, 17:43 
Offline
Has learned to write! (217)
yay now go do some work 1 more and I'm at 200 post :o

_________________
Don't worry I got some silicon carrots - [SpA]Bucky O'Hare


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 18 Jan 2011, 14:39 
Offline
is Wonder Woman (5950)
User avatar
Ok, so because I wasn't thinking straight yesterday, I realised that the file being an FLV doesn't make any difference as I can still import it into flash. So I've done that and I tried your code Balls but it came up with this error
Code:
1095: Syntax error: A string literal must be terminated before the line break. navigateToURL(url, "_self);
I'm not an AS3 expert so I've no idea what to change. So I'm going to give Cardboards a go implementing that javascript that Frosty posted.

_________________
Classy is when a woman has everything to flaunt, but chooses not to show it!


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 18 Jan 2011, 14:47 
Offline
is Wonder Woman (5950)
User avatar
Just worked out that problem, there was a missing "

From:
Code:
navigateToURL(url, "_self); 
To:
Code:
navigateToURL(url, "_self"); 
but now I'm getting another error message:
Code:
1120: Access of undefined property URL_button. URL_button.addEventListener(MouseEvent.CLICK, onStageClick);
I'll do some more research in the meantime

EDIT: Fixed that problem, I just had to call my instance URL_button, and afterall that it doesn't work :( It doesn't go to the url!
So back to Plan B (and no I don't mean the band ;) )

EDIT2: By the way, it's not a button, it's an flv so maybe that's why the code doesn't work! I've just been deciphering the code and it says
Code:
URL_button.addEventListener(MouseEvent.CLICK, onStageClick);
So basically that is saying to add a listener when the mouse clicks the button! The mouse doesn't click any button, just when the flv finishes it goes straight to the home page. I have also tried some javascript and still not having any luck :(

Any other suggestions?

_________________
Classy is when a woman has everything to flaunt, but chooses not to show it!


Top
   
se 
 Post subject: Re: FLASH
PostPosted: 18 Jan 2011, 20:45 
Offline
Has no REAL life! (1120)
Since I have no knowledge of AS, I'm going to pull this one out my arse:
Do you actually have a "URL_Button" in scope? If not, it might be interpreted as a (non-existant) property of _root.

EDIT: didn't read whole post
something wrote:
So basically that is saying to add a listener when the mouse clicks the button! The mouse doesn't click any button, just when the flv finishes it goes straight to the home page. I have also tried some javascript and still not having any luck :(
From your code or from something already in the FLV?

If the redirect is contained within the FLV you could just edit the string...

_________________
slurper


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 19 Jan 2011, 02:58 
Offline
is Wonder Woman (5950)
User avatar
No the redirect is not contained in the flv. I saw some code to extract that but unfortunately that's not the case. But it's ok, Cardboard has cracked it for me coz he's amazing :hug:

_________________
Classy is when a woman has everything to flaunt, but chooses not to show it!


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 26 Jan 2011, 12:20 
Offline
is Wonder Woman (5950)
User avatar
Ok, I'm back again for some more help. I'm putting an animation together, I've split the animation into smaller parts and made movie clips. So I then put the movie clips on the main timeline and I'm guessing I need actionscript to control when I want each movie clip to play.

So that's my dilemma, what I would like to do is when the first movie clip has played, stop and then play the next movie clip on the next frame and so on then loop back to the beginning. Now I am familiar with stop(); gotoAndPlay(); but I'm having trouble with the event handler/listener.

So I'm thinking I need an event listenter/handler to find out when the movie clip ends to then instruct it to go to the next movie clip in a particular frame.

Does anyone have any ideas?

I'm using AS3 btw.

_________________
Classy is when a woman has everything to flaunt, but chooses not to show it!


Top
   
nl 
 Post subject: Re: FLASH
PostPosted: 26 Jan 2011, 14:13 
Offline
Has no REAL life! (1620)
User avatar
stop() on each frame

use the event handler that I gave you... Make sure to name each movie instance differently or they won't work

instead of the url call use gotoAndPlay(n)

should work fine.

_________________
swedishnitro wrote:
I take it all back. FFFFFFUUUUUU cardboard!!!!!


Top
   
nl 
 Post subject: Re: FLASH
PostPosted: 26 Jan 2011, 15:26 
Offline
SpA Fookah (4459)
User avatar

_________________
M.A.S.K. , is the mighty power that can save the day


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 26 Jan 2011, 15:28 
Offline
Has no REAL life! (8841)
User avatar
[SpA]Bucky wrote:
ahum.... :|

_________________
-"You've really worked out your banter, haven't you?"
-"No, not really. This is a different thing, it's spontaneous and it's called wit."


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 26 Jan 2011, 15:47 
Offline
is Wonder Woman (5950)
User avatar
[SpA]cardboard wrote:
stop() on each frame

use the event handler that I gave you... Make sure to name each movie instance differently or they won't work

instead of the url call use gotoAndPlay(n)

should work fine.
Yeah that's what I've been trying to do. But it's not working for me, I'm just wondering if I'm putting them on the timeline properly. They are in different layers on different frames. So the first mc is on frame 1 and the second mc is in a different layer on frame 2.

When I test the movie all it does is flash everything at me and not animate :(

_________________
Classy is when a woman has everything to flaunt, but chooses not to show it!


Top
   
nl 
 Post subject: Re: FLASH
PostPosted: 26 Jan 2011, 15:56 
Offline
Has no REAL life! (1620)
User avatar
do you have a separate layer for the AS?

make sure there's a stop(); in the AS layer for every frame.

Then make sure all vids have a unique name if not it will throw each of the event handlers off.

If it still doesn't work email it too me. I'll look for anything obvious and tell you how to fix it and fix anything un-obvious.

_________________
swedishnitro wrote:
I take it all back. FFFFFFUUUUUU cardboard!!!!!


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 26 Jan 2011, 16:01 
Offline
is Wonder Woman (5950)
User avatar
[SpA]cardboard wrote:
do you have a separate layer for the AS?
Yes
[SpA]cardboard wrote:
make sure there's a stop(); in the AS layer for every frame.
already done
[SpA]cardboard wrote:
Then make sure all vids have a unique name if not it will throw each of the event handlers off.
only given an instance name to one of the movie clips for now while testing, I'll name the rest.
[SpA]cardboard wrote:
If it still doesn't work email it too me. I'll look for anything obvious and tell you how to fix it and fix anything un-obvious.
Will do but Flash just crashed and now it won't open up my file. Yes I did save it but it refuses to open it. Luckily I saved a back up.... somewhere!!?

_________________
Classy is when a woman has everything to flaunt, but chooses not to show it!


Top
   
nl 
 Post subject: Re: FLASH
PostPosted: 26 Jan 2011, 16:21 
Offline
Has no REAL life! (1620)
User avatar
Eek! Did it corrupt the original?

I hate flash and its stability issues, I think I preferred it way back at as1 where you had to work hard to do interesting things it felt oddly pioneering working with flash in those days. The bigger it got the more unstable.

_________________
swedishnitro wrote:
I take it all back. FFFFFFUUUUUU cardboard!!!!!


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 26 Jan 2011, 16:36 
Offline
is Wonder Woman (5950)
User avatar
Yeah it bloody corrupted it. Almost back on track! Flash wouldn't even load this morning so I had to download a patch but it's been bugging out all day. The most common problem of any Adobe software not loading has something to do with File Vault, but I don't have that enabled so I had to download a patch instead. Then I had to do the same to Dreamweaver!

Stupid bloody Adobe buggy crap! AND to top it all off I'm working on a bloody MAC :evil:

_________________
Classy is when a woman has everything to flaunt, but chooses not to show it!


Top
   
nl 
 Post subject: Re: FLASH
PostPosted: 26 Jan 2011, 17:00 
Offline
Has no REAL life! (1620)
User avatar
I will never work on a MAC ever again... those years in university were more than enough to prove it as a futile pursuit.

Hope its going OK

_________________
swedishnitro wrote:
I take it all back. FFFFFFUUUUUU cardboard!!!!!


Top
   
gb 
 Post subject: Re: FLASH
PostPosted: 26 Jan 2011, 17:14 
Offline
is Wonder Woman (5950)
User avatar
WTF is wrong with this stupid software, it runs out of memory when I want to paste a bit of text then corrupts my file. So yes this is the third time I'm having to start again. FFS!

_________________
Classy is when a woman has everything to flaunt, but chooses not to show it!


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 30 posts ] 

All times are UTC+02:00


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Limited