/ Forside / Teknologi / Multimedie & design / Flash / Nyhedsindlæg
Login
Glemt dit kodeord?
Brugernavn

Kodeord


Reklame
Top 10 brugere
Flash
#NavnPoint
bentjuul 4251
molokyle 1978
Klaudi 1488
jhvp 1265
pallenoc 1160
katekismus 1020
Fnollerpi.. 790
slander 510
Dr.Disco 500
10  Flash77 500
playing forward and backward by mouseposit~
Fra : philippe


Dato : 05-05-04 16:42

hi,

want to control the timeline dynamically by the position of the mouse.
that means when you move your cursor to the right, the movie plays
forward, when you move to the left backwards.

any ideas?


download the .fla here >>
http://www.philippe.networkartists.com/reversenavigation00.zip



thanks, philippe


 
 
philippe (06-05-2004)
Kommentar
Fra : philippe


Dato : 06-05-04 17:48

wow, thank you guys!

even have to decide between two solutions:

>> http://www.philippe.networkartists.com/reversenavigation01.swf

where the movement follows the differerence of the mouse position

[ var animationDirection:Boolean = false;
var prevMousePosition:Boolean = false;

var mouseListener = new Object();
mouseListener.onMouseMove = function () {
   var curMousePosition = _xmouse;
   if(curMousePosition < prevMousePosition) {
      animationDirection = false;
   }else if(curMousePosition > prevMousePosition) {
      animationDirection = true;
   }
   prevMousePosition = curMousePosition;
}
Mouse.addListener(mouseListener);


function onEnterFrame() {
   if(animationDirection && _currentframe < _totalframes) {
      nextFrame();
   }else if(!animationDirection && _currentframe > 1) {
      prevFrame();
   }
}
] by danny patterson


or

http://www.philippe.networkartists.com/reversenavigation02.swf

where the movement depends on the position right or left of the middle

[1. Create a new movie clip.
2. Drag it onto the stage
3. Click on the new movie clip to highlight it, and put this in the
actions
panel:

onClipEvent(enterFrame) {
   
   positionM = _root._xmouse;
   if (positionM < 400) {
      this._parent.prevFrame();
      trace(positionM);
   }else{
      this._parent.play();
   
   }}

] by rhythmikone

the only problem is to make the movie loop, also when going backwards
.... but that should be easy solvable ...

thanks, philippe

philippe wrote:

> hi,
>
> want to control the timeline dynamically by the position of the mouse.
> that means when you move your cursor to the right, the movie plays
> forward, when you move to the left backwards.
>
> any ideas?
>
>
> download the .fla here >>
> http://www.philippe.networkartists.com/reversenavigation00.zip
>
>
>
> thanks, philippe
>


Søg
Reklame
Statistik
Spørgsmål : 177558
Tips : 31968
Nyheder : 719565
Indlæg : 6408920
Brugere : 218888

Månedens bedste
Årets bedste
Sidste års bedste