| |||||||
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) |
| Neuer User Registriert seit: Jul 2005
Beiträge: 26
| panorama nicht nur mit halfwidth
Hallo, kurze frage. Ich hab hier ein panororama mit untenstehendem script. schönes teil, aber wenn ich dem panorama ein größere länge gebe scrollt es trotzdem nur bis zur doppelten länge der bühne. Das liegt am halfwidth und den zahlen bei x. wie kann ich was verändern um z.B. die 3 fache länge der bühne (stage) reingescrollt zu bekommen? danke!!! stop(); var dist; var fraction; var decel; var halfWidth = (Stage.width/2); var newposx = halfWidth; var range = (_root.panorama_mc._width-Stage.width)/2; var currtime; var now; _root.panorama_but.onRollOver = function() { _root.onEnterFrame = function() { distancex = _root.panorama_mc._x-newposx; _root.panorama_mc._x = _root.panorama_mc._x-(distancex/decel); }; _root.onMouseMove = function() { currtime = getTimer(); dist = _root._xmouse-halfWidth; fraction = Math.abs(dist/halfWidth); decel = (fraction)*15+5; if (dist<0) { newposx = halfWidth+(fraction*range); } else { newposx = halfWidth-(fraction*range); } }; }; _root.panorama_but.onRollOut = function() { delete _root.onMouseMove; _root.onEnterframe = function() { now = getTimer(); var delay = 15; // in seconds decel = 35; if (now>currtime+(delay*1000)) { // trace("now=" +now+ " last time=" +currtime); distancex = _root.panorama_mc._x-halfWidth; _root.panorama_mc._x = _root.panorama_mc._x-(distancex/decel); } }; }; This; |
| | |
| | #2 (permalink) |
| tracer Registriert seit: Jun 2004
Beiträge: 4.415
|
aloha! kannst du eventuell mal eine auf das problem reduzierte fla anhängen? wenn du code im forum postest, dann verwende das "php"-icon rechts über dem texteingabefeld, dann wird der as-code formatiert und bei weitem leserlicher;
__________________ Viola per Sempre Alle Angaben ohne Gewehr! trace your open mind in variables ! andretti ActionScript Dictionary |
| | |
![]() |
| Lesezeichen |
| Themen-Optionen | |
| Ansicht | |
| |