MAP ausblenden wenn neues Panorama betreten wird

  • Hallo,


    ich mal wieder ;)


    Aktuell hab ich ja schon so einiges hier aus dem Forum gelernt und konnte es auch häufig ohne weiteres umsetzen, wenn ich mir die Threads durchlies, auch Klaus half mir bislang immer wieder sehr, danke dafür !


    Meine aktuelles Problem ist bei einer virtuellen Tour, es geht mir darum, das ich gern jedes mal wenn ein neues Panorama via Hotspot oder Spot vom MAP geladen wird das offene MAP klein wird oder aber beim betreten klein bleibt, leider bekomme ich es nicht ohne weiteres hin, daher würde ich mich über Hilfe freuen, es treibt mich quasi in den Wahnsinn :)


    Mittels Closemap am Anfang habe ich es versucht, geht nicht, weil die Spots stehen bleiben, Hidespots funktioniert, aber die Spots verschwinden immer erst dann, wenn das Panorama und das Lookto durch sind, alpha wars auch nicht, vielleicht gibt es ja dafür eine ganz einfache Lösung, aber inzwischen habe ich irgendwie bei diesem Prob. nen Brett vorm Kopf :)


    Wenn ich ein Panorama mittels html aufrufe, dann wird die Karte klein, aber wenn ich dann von einem Pano ins andere blende, dann bleibt das MAP stehen bei keepall, und bei Merge wird sie jedes mal wieder groß eingeblendet, egal wierum ich es versuche, es funtzt net :(


    Viele Grüße, Eric

  • so:

    so mach ich das:
    <plugin name="map" url="map.jpg" keep="true"
    align="leftbottom" x="30" y="15" alpha="0.90" handcursor="false"
    scalechildren="true"
    width="160"
    height="114"
    zorder="2"
    onhover="showtext(maximieren);"
    onclick="action(openmap);"
    onout="action(closemap);"
    />

  • ok, je nachdem, wie es passt. in meinem fall soll der plan nur offen sein, wenn ich mich darauf bewege.

    und da mein plan fast den ganzen bildschirm ausfüllt hab ich dieses problem nicht.

    vg

    sascha

  • Hi,


    also ich habe bis hier hin schon "fast" den gewünschten Effekt, ich schreibe bei jeder Aufrufaction nun:


    <action name="moveto01">
    action(closemap);action(startloading);
    lookto(433.00,5.00);
    action(load01);
    wait(blend);
    oninterrupt(action(lookinterrupt));
    lookto(443,9,120,smooth(50,25,100));
    action(loadingdone);
    </action>


    und bei dem Map gebe ich an:


    <plugin name="map" url="map.png" zorder="1" align="righttop" edge="righttop" x="10" y="10" alpha="0.95" handcursor="false"
    width="20"
    height="20"
    onhover="showtext(Karte öffnen,smalltext);"
    onclick="action(openmap);"
    />


    Somit ist es ja dann immer klein,

    nun habe ich das Problem, das alle Spots die bei geöffneter Karte sichtbar sind auch da sind, wenn die Karte automatisch geschlossen wird, um die unsichtbar zu machen, kann ich zwar jedem Spot alpha 0 zuweisen, aber dann bleibt immer noch der Showtext sichtbar wenn man mit der Maus drauf kommt, was gibt es denn nun dafür, das die Spots gar nicht erst da sind, solange die Karte nicht geöffnet wird ??? Die Spots sind übrigens auch da, wenn ich vor der Closemap action auch noch Hiedespots angebe, die schweine wollen einfach nich verschwinden :)


    Grüße, Eric

  • Wenn ich nun am Anfang noch:


    <events onloadcomplete="action(hidespots)" />

    <action name="hidespots">
    set(plugin[spot1].visible,false);
    set(plugin[spot2].visible,false);
    set(plugin[spot3].visible,false);
    set(plugin[spot4].visible,false);
    set(plugin[spot5].visible,false);
    set(plugin[spot6].visible,false);
    set(plugin[spot7].visible,false);
    set(plugin[spot8].visible,false);
    set(plugin[spot9].visible,false);
    set(plugin[spot10].visible,false);
    set(plugin[spotx].visible,false);
    </action>


    angebe, dann verschwinden sie zwar, aber erst, nach dem alle drehungen ect. beendet sind... Ich werd da langsam nich mehr schlau draus, bitte um eure Hilfe.

  • hi,

    wenn ich das so mache, ist die karte beim start klein und beim drüber fahren groß, wird die karte verlassen, wird sie wieder klein.

    showtext und hotspots sind dann auch weg.

    sasch


    <plugin name="map" url="map.jpg" keep="true"
    align="leftbottom" x="30" y="15" alpha="0.90" handcursor="false"
    scalechildren="true"
    width="160"
    height="114"
    zorder="2"
    onclick="action(openmap);"
    onout="action(closemap);"
    onover="action(openmap);"
    />


    <!-- actions -->
    <action name="closemap">
    set(onclick,action(openmap););
    set( plugin[map].onout, action(openmap) );
    tween(width,160,distance(320,0.5),easeoutquad);
    tween(height,114,distance(227,0.5),easeoutquad);
    </action>


    <action name="openmap">
    set(onclick,action(closemap););
    set( plugin[map].onout, action(closemap) );
    tween(width,800,distance(320,0.5),easeoutquad);
    tween(height,570,distance(227,0.5),easeoutquad);
    </action>

  • Das mit dem schliessen der Karte geht ja, nur bleiben immer und immer wieder die Spots stehen, sprich die Karte schliesst, aber die Spots sind da und erst wenn ich die Karte einmal öffne und wieder schliesse sind die auch weg...


    So siehts aus im Moment, vielleicht habe ich da ja noch nen Denkfehler drin den jemand sieht?


    <plugin name="map" url="map.png" zorder="1" align="righttop" edge="righttop" x="10" y="10" alpha="0.95" handcursor="false"
    scalechildren="true"

    width="20"
    height="20"
    onhover="showtext(Karte öffnen,smalltext);"
    onclick="action(openmap);"
    />

    <plugin name="spot1" url="mappoint.png" zorder="2" align="righttop" edge="center" x="200" y="170" onhover="showtext(1,default);" onclick="action(load01);" />
    <plugin name="spot2" url="mappoint.png" zorder="2" align="righttop" edge="center" x="110"y="170" onhover="showtext(2 ,default);" onclick="action(load02);" />
    <plugin name="spot3" url="mappoint.png" zorder="2" align="righttop" edge="center" x="50" y="260" onhover="showtext(3,default);"onclick="action(load09);" />
    <plugin name="spot4" url="mappoint.png" zorder="2" align="righttop" edge="center" x="130" y="220" onhover="showtext(4);" onclick="action(load04);" />
    <plugin name="spot5" url="mappoint.png" zorder="2" align="righttop" edge="center" x="173" y="220" onhover="showtext(5,default);" onclick="action(load16);" />
    <plugin name="spot6" url="mappoint.png" zorder="2" align="righttop" edge="center" x="147" y="115" onhover="showtext(6,default);" onclick="action(load07);" />
    <plugin name="spot7" url="mappoint.png" zorder="2" align="righttop" edge="center" x="147" y="55" onhover="showtext(7,default);" onclick="action(load08);" />
    <plugin name="spot8" url="mappoint.png" zorder="2" align="righttop" edge="center" x="75" y="100" onhover="showtext(8,default);" onclick="action(load12);" />
    <plugin name="spot10" url="info.png" zorder="2" align="righttop" edge="center" x="140" y="130" onhover="showtext(9);" onclick="action(load07);" />
    <plugin name="spot9" url="mappoint2.png" zorder="2" align="righttop" edge="center" x="235" y="170" onhover="showtext(10,default);" onclick="openurl(21.html,_self);"/>
    <!-- first hotpot -->
    <plugin name="spotx" url="mappointactive.png" zorder="4" align="righttop" edge="center" x="200" y="170" />


    <action name="startloading">
    set(hotspot.visible,false);
    push(view.fovmin);
    set(view.fovmin,1);
    </action>

    <action name="loadingdone">
    pop(view.fovmin);
    set(hotspot.visible,true);
    </action>

    <action name="lookinterrupt">
    action(loadingdone);
    breakall();
    </action>


    <action name="load01">
    set(plugin[spotx].x,200);
    set(plugin[spotx].y,170);
    loadpano(01.xml,null,MERGE,BLEND(2));
    wait(blend);
    oninterrupt(action(lookinterrupt));
    lookto(611,11,320,smooth(50,25,100));
    action(loadingdone);
    </action>


    <action name="load02">
    set(plugin[spotx].x,110);
    set(plugin[spotx].y,170);
    loadpano(02.xml,null,MERGE,BLEND(2));
    wait(blend);
    oninterrupt(action(lookinterrupt));
    lookto(443,12,320,smooth(50,25,100));
    action(loadingdone);
    </action>

    <action name="load09">
    set(plugin[spotx].x,50);
    set(plugin[spotx].y,260);
    loadpano(09.xml,null,MERGE,BLEND(2));
    wait(blend);
    oninterrupt(action(lookinterrupt));
    lookto(699,8,320,smooth(50,25,100));
    action(loadingdone);
    </action>

    <action name="load04">
    set(plugin[spotx].x,130);
    set(plugin[spotx].y,220);
    loadpano(04.xml,null,MERGE,BLEND(2));
    wait(blend);
    oninterrupt(action(lookinterrupt));
    lookto(439,17,320,smooth(50,25,100));
    action(loadingdone);
    </action>

    <action name="load16">
    set(plugin[spotx].x,173);
    set(plugin[spotx].y,220);
    loadpano(16.xml,null,MERGE,BLEND(2));
    wait(blend);
    oninterrupt(action(lookinterrupt));
    lookto(805,40,320,smooth(50,25,100));
    action(loadingdone);
    </action>


    <action name="load07">
    set(plugin[spotx].x,147);
    set(plugin[spotx].y,115);
    loadpano(07.xml,null,MERGE,BLEND(2));
    wait(blend);
    oninterrupt(action(lookinterrupt));
    lookto(383,9,320,smooth(50,25,100));
    action(loadingdone);
    </action>


    <action name="load08">
    set(plugin[spotx].x,147);
    set(plugin[spotx].y,55);
    loadpano(08.xml,null,MERGE,BLEND(2));
    wait(blend);
    oninterrupt(action(lookinterrupt));
    lookto(893,4,320,smooth(50,25,100));
    action(loadingdone);
    </action>
    <action name="load12">
    set(plugin[spotx].x,75);
    set(plugin[spotx].y,100);
    loadpano(12.xml,null,MERGE,BLEND(2));
    wait(blend);
    oninterrupt(action(lookinterrupt));
    lookto(387,-6,320,smooth(50,25,100));
    action(loadingdone);
    </action>

    <action name="showspots">
    set(plugin[spot1].alpha,0);
    set(plugin[spot2].alpha,0);
    set(plugin[spot3].alpha,0);
    set(plugin[spot4].alpha,0);
    set(plugin[spot5].alpha,0);
    set(plugin[spot6].alpha,0);
    set(plugin[spot7].alpha,0);
    set(plugin[spot8].alpha,0);
    set(plugin[spot9].alpha,0);
    set(plugin[spot10].alpha,0);
    set(plugin[spotx].alpha,0);

    set(plugin[spot1].visible,true);
    set(plugin[spot1].visible,true);
    set(plugin[spot2].visible,true);
    set(plugin[spot3].visible,true);
    set(plugin[spot4].visible,true);
    set(plugin[spot5].visible,true);
    set(plugin[spot6].visible,true);
    set(plugin[spot7].visible,true);
    set(plugin[spot8].visible,true);
    set(plugin[spot9].visible,true);
    set(plugin[spot10].visible,true);
    set(plugin[spotx].visible,true);


    tween(plugin[spot1].alpha,1);
    tween(plugin[spot2].alpha,1);
    tween(plugin[spot3].alpha,1);
    tween(plugin[spot4].alpha,1);
    tween(plugin[spot5].alpha,1);
    tween(plugin[spot6].alpha,1);
    tween(plugin[spot7].alpha,1);
    tween(plugin[spot8].alpha,1);
    tween(plugin[spot9].alpha,1);
    tween(plugin[spot10].alpha,1);
    tween(plugin[spotx].alpha,1);
    </action>

    <action name="hidespots">
    set(plugin[spot1].visible,false);
    set(plugin[spot2].visible,false);
    set(plugin[spot3].visible,false);
    set(plugin[spot4].visible,false);
    set(plugin[spot5].visible,false);
    set(plugin[spot6].visible,false);
    set(plugin[spot7].visible,false);
    set(plugin[spot8].visible,false);
    set(plugin[spot9].visible,false);
    set(plugin[spot10].visible,false);
    set(plugin[spotx].visible,false);
    </action>


    <action name="closemap">
    action(hidespots);
    set(plugin[map].onhover,showtext(Karte öffnen,smalltext););
    set(plugin[map].onclick,action(openmap););
    tween(plugin[map].width,20,distance(500,0.5),easeoutquad);
    tween(plugin[map].height,20,distance(505,0.5),easeoutquad);
    </action>

    <action name="openmap">
    set(plugin[map].onhover,showtext(Karte schließen,smalltext););
    set(plugin[map].onclick,action(closemap););
    tween(plugin[map].width,243,distance(500,0.5),easeoutquad);
    tween(plugin[map].height,400,distance(505,0.5),easeoutquad,action(showspots););
    </action>

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!