| |||||||
Du magst keine Werbung? Wir auch nicht!
Einfach registrieren und die Werbung ist weg. Diese Nachricht sehen nur nicht registrierte Nutzer.
![]() |
| | LinkBack | Themen-Optionen | Ansicht |
| | #1 (permalink) |
| Ein Reisender... Registriert seit: May 2004
Beiträge: 105
| Dynamisches Fenster
Nachdem ich etliche Beiträge gelesen habe die nichts mit meinem Anliegen zu tun haben, nun doch der Post, weil ich fast sicher bin, dass da schon etwas existiert... Ich werde ein Menu bauen, bei dem es auf der Hauptsite diverse Fenster gibt (siehe Anlage). Klickt man auf eines, verändern sich die Fenster dynamisch in ihrer Grösse zu einer neuen Anordnung. Genau heisst das: Das Fenster wird grösser oder kleiner je nach MovieClip Inhalt der reingeladen wird (sowas gibts!) und ändert die Position... Damit ich nicht völlig das Rad neu erfinden muss, wollte ich fragen, ob jemand dazu schon eine Lösung gefunden hat oder ob ähnliche Themen schon besprochen wurden. Links oder Tips wären absolut das Grösste ![]() zum Thema: - dynamische Fenster - Schatten und Fenster - Tween-Fenster Ich denke der Thread könnte vielen anderen mit ähnlichen Problemen auch helfen... Liebe Grüsse, Syracus Geändert von Syracus (26-11-2005 um 11:55 Uhr) |
| | |
| | #3 (permalink) |
| Ein Reisender... Registriert seit: May 2004
Beiträge: 105
| Du sagst es...aber... Sehr genial, gibts dazu denn auch Codematerial oder Scripthilfen?Eigentlich geht mein Anliegen aber noch etwas weiter, denn ich möchte das dynamische Fenster auch noch etwas komplexer bauen (siehe meine Anlage oben) und nun wäre ich froh um eine Empfehlung. Denn ich nehme an, dass das Script schlicht eine Box als Fensterrahmen zeichnet. Was ich aber möchte, ist das Fenster als eine Art Komponente hinzubekommen. D.h man müsste Ecken und auch Rahmen des Fensters als Teile definieren. Da wird dann eine Dynamik schwerer oder nicht? Anders gesagt man macht 4 Ecken und lässt nur die Verbindungsbalken sich wie Gummi aus und eindehnen: der Effekt ist aber wie in Deinem Beispiel, nur das Fenster wäre schöner. Zum ganzen noch Schatten dazu wär die Endidee, allerdings hab ich dazu ne Ahnung... Hmm schwer und etwas komplex. Kennt jemand dazu etwas?Gruss Syra Geändert von Syracus (17-08-2005 um 12:27 Uhr) |
| | |
| | #4 (permalink) | |
| Nix Wisser Registriert seit: May 2003 Ort: Würzburg, Kleinstadt
Beiträge: 3.510
|
ist mit Swishmax gemacht, aber such doch mal nach "Kurt Noble" problem mit stage, align, listener und konsorten stage objekt http://www.after-hours.org/blog/comosehizo/KNImenu/ Zitat:
__________________ nullidee Abakus GT 10² Kugeln - 80"Leinwand - CARAN D´ACHE SUPRACOLOR® | |
| | |
| | #5 (permalink) |
| Nix Wisser Registriert seit: May 2003 Ort: Würzburg, Kleinstadt
Beiträge: 3.510
|
einfach auf die Hauptzeitleiste und auf die Bühne ein MC "out" darin ein Textfeld mit Bezeichner "out" Code: //onLoad () { braucht Flash nicht
_root.old_wm = 100;
_root.old_hm = 100;
film = [250,400,500,200,225,300,500,500,220,220];
titel = ["News","Work","Info","Pic1","Example"];
lmovie = ["news1.swf","work.swf","film3.swf","pics.swf","morph2.swf"];
MovieClip.prototype.drawR = function (x,y,w,h,farbe,trans) {
with(this){
// lineStyle(0,0x444444,50);
beginFill(farbe,trans);
moveTo(x,y);
lineTo(w,y);
lineTo(w,h);
lineTo(x,h);
lineTo(x,y);
endFill();
}
};
_root.createEmptyMovieClip("shadow",100);
shadow.drawR(0,0,100,100,0x000000,20);
_root.createEmptyMovieClip("whiteBox",110);
whiteBox.drawR(0,0,100,100,0xFFFFFF,100);
_root.createEmptyMovieClip("blankColor",120);
blankColor.drawR(0,0,100,100,0xFFFFE1,100);
_root.createEmptyMovieClip("logo",130);
logo.drawR(0,0,50,20,0xCC0000,100);
_root.createEmptyMovieClip("menu",140);
menu.drawR(0,0,250,16,0xFFFFFF,100);
_root.menu.createEmptyMovieClip("btn1",141);
_root.menu.createEmptyMovieClip("btn2",142);
_root.menu.createEmptyMovieClip("btn3",143);
_root.menu.createEmptyMovieClip("btn4",144);
_root.menu.createEmptyMovieClip("btn5",145);
menu.btn1.drawR(0,0,50,16,0xFFFF00,100);
menu.btn2.drawR(0,0,50,16,0xFFFF00,100);
menu.btn3.drawR(0,0,50,16,0xFFFF00,100);
menu.btn4.drawR(0,0,50,16,0xFFFF00,100);
menu.btn5.drawR(0,0,50,16,0xFFFF00,100);
menu.btn1._x = menu._x;
menu.btn2._x = menu._x + menu.btn1._width;
menu.btn3._x = menu._x + menu.btn1._width*2;
menu.btn4._x = menu._x + menu.btn1._width*3;
menu.btn5._x = menu._x + menu.btn1._width*4;
menu.btn1.onPress = function() {
_root.movie.holder.loadMovie(lmovie[0]);
_root.wmodifier = _root.film[0];
_root.hmodifier = _root.film[1];
};
menu.btn2.onPress = function() {
_root.movie.holder.loadMovie(lmovie[1]);
_root.wmodifier = _root.film[2];
_root.hmodifier = _root.film[3];
};
menu.btn3.onPress = function() {
_root.movie.holder.loadMovie(lmovie[2]);
_root.wmodifier = _root.film[4];
_root.hmodifier = _root.film[5];
};
menu.btn4.onPress = function() {
_root.movie.holder.loadMovie(lmovie[3]);
_root.wmodifier = _root.film[6];
_root.hmodifier = _root.film[7];
};
menu.btn5.onPress = function() {
_root.movie.holder.loadMovie(lmovie[4]);
_root.wmodifier = _root.film[8];
_root.hmodifier = _root.film[9];
};
out.duplicateSprite("out1",200);
out.duplicateSprite("out2",201);
out.duplicateSprite("out3",202);
out.duplicateSprite("out4",203);
out.duplicateSprite("out5",204);
out1._x = menu._x;
out1._y = out2._y = out3._y = out4._y = out5._y = menu._y;
out2._x = menu._x + menu.btn1._width;
out3._x = menu._x + menu.btn1._width*2;
out4._x = menu._x + menu.btn1._width*3;
out5._x = menu._x + menu.btn1._width*4;
out1.out.text = titel[0];
out2.out.text = titel[1];
out3.out.text = titel[2];
out4.out.text = titel[3];
out5.out.text = titel[4];
_root.createEmptyMovieClip("movie",250);
movie.drawR(0,0,100,100,0xFFFFE1,100);
_root.createEmptyMovieClip("movieMask",252);
movieMask.drawR(0,0,100,100,0xFFFFE1,100);
_root.movie.createEmptyMovieClip("holder",255);
_root.movie.setMask(movieMask);
wmodifier = 250;//329;
hmodifier = 400;//425;
bouncefactor = 0.7;
speedfactor = 8;
movie.holder.loadMovie(lmovie[0]);
expand = function (id) {
var _l1 = this;
var _l2 = id;
_l1.destwidth = wmodifier;
_l1.poswidth = _l2._width;
_l1.velwidth = _l1.velwidth * bouncefactor + (_l1.destwidth - _l1.poswidth) / speedfactor;
_l2._width = _l2._width + Math.round(_l1.velwidth);
_l1.destheight = hmodifier;
_l1.posheight = _l2._height;
_l1.velheight = _l1.velheight * bouncefactor + (_l1.destheight - _l1.posheight) / speedfactor;
_l2._height = _l2._height + Math.round(_l1.velheight);
_l1.destx = (Stage.width - wmodifier) / 2;
_l1.posx = _l2._x;
_l1.velx = _l1.velx * bouncefactor + (_l1.destx - _l1.posx) / speedfactor;
_l2._x = _l2._x + Math.round(_l1.velx);
_l1.desty = ((Stage.height - hmodifier) / 2);
_l1.posy = _l2._y;
_l1.vely = _l1.vely * bouncefactor + (_l1.desty - _l1.posy) / speedfactor;
_l2._y = _l2._y + Math.round(_l1.vely);
logo._x = blankColor._x - 10;
logo._y = blankColor._y + blankColor._height + 20;
whiteBox._width = blankColor._width + 20;
whiteBox._x = blankColor._x - 10;
whiteBox._height = blankColor._height + 20;
whiteBox._y = blankColor._y - 10;
shadow._width = whiteBox._width + 20;
shadow._x = whiteBox._x - 10;
shadow._height = whiteBox._height + 20;
shadow._y = whiteBox._y - 10;
menu._x = blankColor._x + (blankColor._width - Math.floor(menu._width)) + 10;
menu._y = shadow._y - 16;
out1._x = menu._x;
out2._x = menu._x + menu.btn1._width;
out3._x = menu._x + menu.btn1._width*2;
out4._x = menu._x + menu.btn1._width*3;
out5._x = menu._x + menu.btn1._width*4;
out1._y = out2._y = out3._y = out4._y = out5._y = menu._y;
movie._x = blankColor._x;
movie._y = blankColor._y;
movieMask._x = blankColor._x;
movieMask._y = blankColor._y;
movieMask._width = blankColor._width;
movieMask._height = blankColor._height;
loader._x = blankColor._x + 20;
loader._y = blankColor._y + blankColor._height - 20;
closeBut._x = blankColor._x + blankColor._width - 62;
closeBut._y = blankColor._y - 40;
};
blankColor.onEnterFrame = function () {
expand(this);
};
//} braucht Flash nicht
__________________ nullidee Abakus GT 10² Kugeln - 80"Leinwand - CARAN D´ACHE SUPRACOLOR® |
| | |
| | #7 (permalink) |
| Ein Reisender... Registriert seit: May 2004
Beiträge: 105
| Noch weitere Fenster - Bounce Lösungen...?
Ich habe mich mal mit dem obigem Script beschäftigt, bin mir aber nicht sicher, ob es nicht bessere Lösungen mit anderen Ansätzen gibt, die mir noch im dunkeln liegen. Die Forumsuche gab nach Selektion einen Thread zu dem Thema ab, der allerdings etwas abdriftet: Bounce und Kannengiesser Ok, man kann mc's bouncen. Aber wie ist das mit mehreren externen swfs die man reinlädt und ohne SwiftMax. Die zusätzliche Frage die ich habe: Ist für eine solche Lösung das Pack von Noble nicht ein zu grosses Kaliber? Der Thread hier scheint der zweite seiner Art zu sein, wäre also vielleicht noch praktisch auch für andere eure Ansätze und Meinungen kund zu tun. Obiges Script scheint eine Lösung zu sein, mit der ich mich noch etwas beschäftige. Beste Grüsse, Syra
__________________ Handle so, dass die Maxime Deines Willens als Gesetzgebung gilt :o) Geändert von Syracus (24-08-2005 um 11:11 Uhr) |
| | |
| | #8 (permalink) |
| Ein Reisender... Registriert seit: May 2004
Beiträge: 105
| dynamisches Fenster
Weiterführend zum Thema: Ich habe ein dynamisches Fenster mit mx.transitions erstellt: Bouncing Window Gruss, Syra
__________________ Handle so, dass die Maxime Deines Willens als Gesetzgebung gilt :o) |
| | |
![]() |
| Lesezeichen |
| Themen-Optionen | |
| Ansicht | |
| |