Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

scrolling buttons

Status
Not open for further replies.

wakkoguy

Technical User
Oct 30, 2001
84
0
0
US
Hey,
I want to be able to do what they have at this website
and then click on tshirts, you see how they have it when you do a mouse over on an arrow the thing moves to the appropriate way. how do you do that? thanx
 
The easiest way to get this effect is to have the pictures of the shirts contained in a movieclip - a very long one ;-)

Select the shirts movieclip on the stage and put this code in the actions panel:

onClipEvent(load){
_root.move=0;
}
onClipEvent(enterFrame){
this._x+=_root.move;
}

The arrows are buttons with a little bit of code - if it points left have this:

on(rollOver){
_root.move=-2;
}
on(rollOut){
_root.move=0;
}

If it points right have this:

on(rollOver){
_root.move=2;
}
on(rollOut){
_root.move=0;
}

For the different sized arrows increase or decrease the value of _root.move accordingly.

That will give you the basic effect without "wrapping around" although what they're doing is quite a bit more complicated... Slainte

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top