Results 1 to 2 of 2

Thread: Get my 90% finished .fla working for beer money?

  1. #1
    Join Date
    Oct 2007
    Posts
    1
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Get my 90% finished .fla working for beer money?

    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/To...ns_garden.html

    -Duff

  2. #2
    Join Date
    Aug 2005
    Location
    Other Side of My Monitor
    Posts
    3,494
    Thanks
    5
    Thanked 105 Times in 104 Posts
    Blog Entries
    1

    Default

    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:

    Code:
    Stage.scaleMode = "noScale";
    and add listeners to your objects you want scaled. There is a nice tutorial HERE


    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"):

    Code:
    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.
    {CWoT - Riddle } {Freelance Copywriter} {Learn to Write}
    Follow Me on Twitter: @InkingHubris
    PHP Code:
    $result mysql_query("SELECT finger FROM hand WHERE id=3");
    echo 
    $result

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •