Does anyone here know how I can do this (or a script for it)? I have a flash game site and I want an AD to display for around 5 seconds before the game starts and then right after the AD the game will automatically start. Any help is appreciated, Thanks -
Looks like it can be done using javascript and setTimeout function. maybe create a function to show the ad through the onload event, then after a certain amount of time, hide the div and show the div with the game on.. the idea makes sense to me
Or, could the Flash game be contained in another "loader" Flash with the ad? It would play the ad, and then Actionscript in the last frame would make the game load. You'd have in your html for the Flash <object type="application/x-shockwave-flash" data="loader.swf?path=nameofgamemovie.swf" width="whatever" height="whatever"> <param name="movie" value="loader.swf?path=nameofgamemovie.swf" /> </object> and this in the Actionscript in the last frame of loader.swf: _root.loadMovie("nameofgamemovie",0); However, if the ad is supposed to change now and then, you'd have to make sure that all new ads are called "loader.swf" and the Actionscript would have to be loaded into all of them (and maybe these ads are being sent to you by someone else and you don't have access to the .fla?). And if the ads are supposed to rotate, then the above wouldn't be a good solution at all. Good thing Js and AS can work together on websites (though how isn't clear to me because I'm allergic to programming : )