Macromedia Flash 8-爱尔兰地图,鼠标悬停都柏林,都柏林扩展

Macromedia Flash 8-爱尔兰地图,鼠标悬停都柏林,都柏林扩展,flash,actionscript,actionscript-2,Flash,Actionscript,Actionscript 2,Macromedia Flash 8问题: 我有一张爱尔兰地图,只有一张gif,还有几个小按钮代表爱尔兰各地的不同兴趣点,它们分散在地图上。 这部分很好用 问题是: 都柏林太小,无法容纳所有的兴趣点(约20个) 解决方案 在都柏林上空,我希望都柏林能够扩大到原来的5到6倍,我希望能够在这个位于爱尔兰地图顶部的更大的都柏林区域内展示都柏林的兴趣点 在都柏林城外,这个扩大的都柏林地区现在缩小到原来的规模 我的问题: 我如何实现都柏林 要求: 1) 扩展的都柏林地区应该是不可点击的,它应该是黑色背景上

Macromedia Flash 8问题:

我有一张爱尔兰地图,只有一张gif,还有几个小按钮代表爱尔兰各地的不同兴趣点,它们分散在地图上。 这部分很好用

问题是: 都柏林太小,无法容纳所有的兴趣点(约20个)

解决方案 在都柏林上空,我希望都柏林能够扩大到原来的5到6倍,我希望能够在这个位于爱尔兰地图顶部的更大的都柏林区域内展示都柏林的兴趣点

在都柏林城外,这个扩大的都柏林地区现在缩小到原来的规模

我的问题: 我如何实现都柏林

要求: 1) 扩展的都柏林地区应该是不可点击的,它应该是黑色背景上的都柏林图像

2) 必须能够在扩展的都柏林地区内添加其他按钮


非常感谢您的任何帮助或帮助……

您可以将该地图用于缩放:

假设您放大的都柏林地图是一个包含所有按钮等的电影剪辑,您可以捕获剪辑的
onRollOver
事件以开始缩放,如下所示:

// d is an object containing all the variables we need for where to start & finish
var d:Object = { 
 start_x:dublin._x, 
 start_y:dublin._y, 
 start_xscale:dublin._xscale,
 start_yscale:dublin._yscale, 
 end_x:0.5*Stage.width,// change end_x and end_y...
 end_y:0.5*Stage.height,//... to suit your layout
 end_xscale:100,
 end_yscale:100,
 totalSteps:10,// zoom in 10 steps (more steps = slower)
 currentStep:0
 };

//dublin is set to be invisible (but rollOver-able) to start with
dublin._alpha = 0;

//the doStep function does a single stage of the zoom (once per frame)
function doStep(clip):Void {
    var fraction=d.currentStep/d.totalSteps;
    clip._x = d.start_x+(d.end_x-d.start_x)*fraction;
    clip._y = d.start_y+(d.end_y-d.start_y)*fraction;
    clip._xscale = d.start_xscale+(d.end_xscale-d.start_xscale)*fraction;
    clip._yscale = d.start_yscale+(d.end_yscale-d.start_yscale)*fraction;
};

//catch rollOver and rollOut events for the dublin clip:
dublin.onRollOver = function() {
    if (d.currentStep<d.totalSteps) {
        //start growing
        this._alpha=100;
        this.onEnterFrame = function() {
            d.currentStep++;
            doStep(this);
            if (d.currentStep>=d.totalSteps) {
                delete this.onEnterFrame;
            }
        };
    }
};

dublin.onRollOut = function() {
    if (d.currentStep>0) {
        //start shrinking
        this.onEnterFrame = function() {
            d.currentStep--;
            doStep(this);
            if (d.currentStep<=0) {
                delete this.onEnterFrame;
                this._alpha=0;
            }
        };
    }
};
//d是一个对象,包含我们在何处开始和结束所需的所有变量
变量d:Object={
开始:都柏林,
开始:都柏林,
开始:都柏林,
开始:都柏林,
end\u x:0.5*Stage.width,//更改end\u x和end\u y。。。
结束y:0.5*舞台高度,//…以适合您的布局
结束xsu刻度:100,
完刻度:100,
totalSteps:10,//放大10步(更多步=更慢)
当前步骤:0
};
//都柏林从一开始就被设置为不可见(但可以滚动)
都柏林。_α=0;
//doStep函数只执行一个阶段的缩放(每帧一次)
函数doStep(clip):无效{
var分数=d.currentStep/d.totalSteps;
剪辑。x=d.start_x+(d.end_x-d.start_x)*分数;
剪辑。_y=d.start_y+(d.end_y-d.start_y)*分数;
clip.xscale=d.startxscale+(d.endxscale-d.startxscale)*分数;
clip._yscale=d.start_yscale+(d.end_yscale-d.start_yscale)*分数;
};
//捕捉都柏林剪辑的滚动和滚动事件:
dublin.onRollOver=函数(){
如果(d.currentStep=d.totalSteps){
删除此.onEnterFrame;
}
};
}
};
dublin.onRollOut=函数(){
如果(d.currentStep>0){
//开始缩小
this.onEnterFrame=函数(){
d、 当前步骤--;
多步骤(本);

if(都柏林问题的d.currentStep+1:)一些好主意的家伙,多亏了洛蒂,他们最终使用了._invisible=true;为都柏林的所有兴趣点加载。在都柏林上空,每个都柏林兴趣点都会得到._invisible=false;。在这些兴趣点的后面还有一幅都柏林的大图,它变得清晰可见。这是解决问题的一个非常简单的方法,但它可以非常好,重量非常轻。感谢所有的帮助!正如你所说,如果你不需要缩放动画,它会简单得多!是的-都柏林的这些兴趣点是地图的焦点,并且必须对鼠标器等做出响应。好主意,我最初测试过。非常感谢。伙计:-我认为它可以修复…th这里有一些解决方案: