MX2004: Campus Map, Smooth Scripted Movement and other problems

hi everyone.

I could really use some help. I am working on designing a flash map for our university campus. Using MX2004. I have a lot working so far, but I am running into some stumbling blocks. I’ve used flash for a while, but only for simple animations, I’m pretty new to actionscripting but so far have been able to piece together tutorials, examples and so forth to get the functionality I need so far.

However, I need some tips on a few things and I hope this thread can help with the development of this.

The map loads from an external flash file so it can be updated more easily by other people down the road.
I have the controls to move it around and zoom it in by using a slider and some nav buttons, both of which has been hacked together from different examples.

Now, I am trying to create a list of buildings that when clicked on colors the building and moves the view to where that building is located.

I am doing this in the following way:
each building in the imported map is a movie clip comprised of 2 frames, each with a stop(); command. the first frame is the normal color, the 2nd frame the building is colored orange.

in my list, which will be just a list of text buttons, a user clicks once on a building name and it advances the building movie clip frame foward to the next frame, which changes the color, and the next click on the same button moves to the previous frame setting the color back to green.

Problem is, if the user is not zoomed all the way out, they won’t see which building is being highlighted. So what I would like, is despite what zoom or x/y position the map is currently at, when they click on a building it moves to a preset x/y coordinate and zoom level that is preset to center that selected building within the viewable area of the map window.

I have the movement and zoom kind of working, but it jumps to it. What i would like is some actionscripted smooth movement toward the preset x and y coordinates from whereever the viewer currently is.

here is the code i’m using right now for when a user clicks on a building name button:

on (release) {
    if (Number(button) == 2) {
        _root.mainMap.mainMap.alumnicenter.nextFrame();
        _root.mainMap._y = 404; //vertical position
        _root.mainMap._x = 457; //horizontal position
        _root.mainMap._xscale = 300;
        _root.mainMap._yscale = 300;
        _root.slider._y = 27; //height of slider on range bar
        _root.slider._x = 144.3; //dont change
        button = 1;
    } else {
        _root.mainMap.mainMap.alumnicenter.prevFrame();
        _root.mainMap._y = 204; //vertical position
        _root.mainMap._x = 457; //horizontal position
        _root.mainMap._xscale = 150;
        _root.mainMap._yscale = 150;
        _root.slider._y = 95; //height of slider on range bar
        _root.slider._x = 144.3; //dont change
        button = 2;
    }
}

the flash file is too big to attach and like i said it pulls from external files, if needed I can package up the folder in a zip file, but here is the latest swf file to give you an idea. http://acketon.com/campus_map1.html

here’s what’s being replaced: http://www.selu.edu/map this is all part of a major redesign effort of the entire website. Most of which is done or underway, but I have taken this on as a project.