Featured FLA
» Author: Bugra Ozden
» Title: Skatalog v9 - product catalog
» Description: Create your product catalog easly and publish on your website or Create your image gallery, documents list, portfolio. Fully XML Driven
» More by Bugra Ozden
Featured Site
» Posted in the Flash Kit Links section
» Title: Creative DW Image Show PRO
» Description: Creative DW Image Show PRO is a Dreamweaver extension which enables the user to create multimedia presentations. It combines the features of the popular Creative DW Image Show with the ability to add professional text effects to slides (similar to After Effects). The product is very customizable: the user can choose the duration of the transition effects, the slide motion start and end position, zoom and panning type for both images and texts.
To make movement along the y axis possible we basically just have to copy the script we just wrote, insert it just behind and change all x to y. mx has to be changed to my, _root._xmouse to _root._ymouse, _x to _y and so on. The script remains the same because there is not really a difference between up-down movement and left-right movement.
The complete script should now look something like this:
onClipEvent (enterFrame) {
//x movement
mx=_root._xmouse;
if (mx<_x) {
dx=_x-mx;
}
else {
dx=mx-_x;
}
moveSpeedx=dx/10;
if (mx<_x) {
_x=_x-moveSpeedx;
}
else {
_x=_x+moveSpeedx;
}
//y movement
my=_root._ymouse;
if (my<_y) {
dy=_y-my;
}
else {
dy=my-_y;
}
moveSpeedy=dy/10;
if (my<_y) {
_y=_y-moveSpeedy;
}
else {
_y=_y+moveSpeedy;
}
}
Home in: Erkrath, Germany
Born in: Bayonne, France 21.05.1982
Hobbies: Gliding, Computer
Flashing since: Jan 2001
Languages: German, Dutch, English French
Founded webdesign company May 2001 but still going to school
What else do you want to know?? :-)