View Full Version : Get my 90% finished .fla working for beer money?
panomotion_studio
10-18-2007, 09:56 PM
Hello, I'm trying to get the link below to resize fullscreen according to the users monitor and within the confines of my html page (leaving room at the bottom for logo as it stands now). I dont know how to check for the stage.width and stage.height and set my panoramic swf to resize accordingly. I also need to make the navigation map stick to the bottom left corner and be able to minimize/maximize the map.
Any takers?
http://panomotionstudio.com/flash/Tourist%20Attractions/Dallas%20Arboretum/womans_garden.html
-Duff
BLiZZaRD
10-20-2007, 03:36 PM
Well, you have to pick one.. full screen or within the HTML.. you can't have both...
if you look in the HTML (use notepad etc) you can change the pixles to percentages. This will make it expand or contract based on the users screen size. Although this method can distort things on lower resolutions.
Use scale mode:
Stage.scaleMode = "noScale";
and add listeners to your objects you want scaled. There is a nice tutorial HERE (http://www.moddular.org/log/stage-object)
use the Flash pop up to minimize maximize the map and use specific placement useing X/Y to place the nav map.
example (navigation map named "mc_sample"):
Stage.scaleMode="noScale";
screen = new Object();
screen.w = 900;
screen.h = 600;
list_resize = new Object();
list_resize.onResize = function () {
//center movieClip
var pos = get_pos(Stage.width/2-mc_sample_a._width/2,Stage.height/2-mc_sample_a._height/2);
mc_sample_a._x = pos.x;
mc_sample_a._y = pos.y;
//place this movieCLip in the upper left corner
var pos = get_pos(0,0);
mc_sample_b._x = pos.x;
mc_sample_b._y = pos.y;
//center movieClip at the bottom
var pos = get_pos(Stage.width/2-mc_sample_c._width/2,Stage.height-mc_sample_c._height);
mc_sample_c._x = pos.x;
mc_sample_c._y = pos.y;
//center movieClip at the bottom
var pos = get_pos(Stage.width-mc_sample_d._width,Stage.height-mc_sample_d._height);
mc_sample_d._x = pos.x;
mc_sample_d._y = pos.y;
}
Stage.addListener(list_resize);
//sub function to get the resized coordinates
get_pos = function(x,y){
return( {x:int((screen.w-Stage.width)/2+x) ,y:int((screen.h-Stage.height)/2+y )});
}
There are 4 different spots you can put the map (you can put it anywhere, I have shown 4) THis works best with the 100% in the HTML codes as stated above.
Powered by vBulletin® Version 4.2.2 Copyright © 2021 vBulletin Solutions, Inc. All rights reserved.