Moving Stage (Page) Background

Working with Media (graphics, audio, video) & other Assets

Moderator: Nav

Moving Stage (Page) Background

Postby Matthias Kausch » Thu Mar 22, 2012 3:05 am

How can I create the effect of a panning background instead of page change in SmartBuilder? I want to create the impression of somebody looking around a room. The available methods and properties (transitions, graphic image methods) do not seem to support this. Is there a workaround to achieve the same result as if I had an oversized background that moved on trigger and stopped at a specific position?
Matthias Kausch
 
Posts: 13
Joined: Mon May 23, 2011 3:22 am

Re: Moving Stage (Page) Background

Postby jmalatino » Thu Mar 22, 2012 8:24 am

If you wanted a panning background you would probably have to make all of the things that happened seamlessly on one page rather than panning across multiple SmartBuilder pages. I would create this background as a Flash AS2 document and export it as a SWF. The resulting SWF would be placed in a SWF Messenger Object and have some specific code within the Flash file as well as the SmartBuilder page. Here is a link to our Help Resources that has all of the information about how to accomplish this.

http://help.smartbuilder.com/node/202

I can also sum it up here. On the first frame of your animation you will need the following code.

function sbPlay() {
play();
}
//
function sbStop(){
stop();
}

/*This will keep the SWF from playing on the authoring stage.*/

/*Then you will need this code also on the first frame.*/

function sbReceiveMessage(name:String, value:String) {
if (name == "gotoFrame") {
gotoAndPlay(value);
}
}

!!!!!This will allow you to communicate from SmartBuilder to your SWF.!!!!

Then set up some actions like the following:

Trigger: Some Button > onClick
Response: SWF Messenger > sendMessage > "gotoFrame", "10"

Or with whatever trigger you need for your particular situation.
In your Flash file you will need to have stop actions on the frames that you want the panning to stop at. And also some sort of panning tween.

Feel free to contact us via the Support Chat if after attempting this you still have some questions.
jmalatino
 
Posts: 71
Joined: Fri Aug 26, 2011 4:03 pm

Re: Moving Stage (Page) Background

Postby Matthias Kausch » Fri Mar 23, 2012 3:12 am

Thanks for this very elaborate answer. It has helped tremendously!
Matthias Kausch
 
Posts: 13
Joined: Mon May 23, 2011 3:22 am


Return to Media & Assets

Who is online

Users browsing this forum: No registered users and 1 guest

cron
Not able to open ./cache/data_global.php