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 Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how on earth is that scrolling effect done i neen help w/ that 2

Status
Not open for further replies.

Guest_imported

New member
Jan 1, 1970
0
hey guys please take a look at this site <A HREF=" TARGET="_new"> Now how is that scrolling effect don and notice that when you press men it scrolls forward and women backwards ...hmmm this one's got me ne suggestion ne one pleae.
 
This is an awesome website created by Koiken Inc. from New York, <A HREF=" TARGET="_new"> is actually a combination of 8 movies (swf). The main one is a background movie at _level0 which contains all the look of the &quot;frontpages&quot; for each section without animation. <br>The scroll is simply a Set Property on the main movie. When the main movie centers on the correspondant frontpage of the section, then it loads the movie for the section (you notice when the transparent rectangles start loading. This movie doesn't load over _level0. HOME loads at _level1, WOMEN loads at -level2, and so on. The movies load one over the other but in the right position. This is done by creating a sub movie with the same size as the background but using only the section that you want to show when it loads on top of the other movies. All the movies are the same size, but they use different spaces. When you move to a different section, the other sections stop but don't unload. That is why you keep seeing them afterwards. The small menus are inside each movie loaded, movieclips and that is why you can drag them around but they disappear when you change the section. Most backgrounds in the submovies are low resolution and the main images are high quality which makes the movie a bit faster.<br>The designer used a lot of actionscripting and variables. It is a complicated effect and if you are very familiar with actionscript I can give you more details. <p>Fernando Regueiro<br><a href=mailto:ferhelping@yahoo.com>ferhelping@yahoo.com</a><br><a href= > </a><br>
 
sure I'm quite familiar w/actionscripting so please with no further delay plse explain more on thses actins using variables<br><br>Tino
 
If you just want the scrolling effect there's a really cheap and quick way to get it...


... if that's all you want, here's how it's done:

The scrolling graphic is one long symbol (about 1000 pixels), the five buttons each set a variable called &quot;target&quot; to a value (obviously a different value per button. Each of these values is a point that the main graphic should scroll to - an &quot;x&quot; value on the screen.

Looking after the scrolling is an empty &quot;dummy&quot; or &quot;control&quot; clip with these actions attached:

onClipEvent (load) {
speed = 20;
}
onClipEvent (enterFrame) {
clip = _parent.scroller;
difference = (_parent.target-clip._x);
increment = difference/speed;
clip._x += increment;
}


This checks on which value has been set by a button then compares the clip's current position with the desired target. It moves the clip towards that target frame by frame until the difference is zero.

A high frame rate keeps things smooth.

Pretty easy. The real Barney's effect is much more complex obviously (using separate movieclips on the scroller not just one basic graphic) but this gives you some of the functionality with no headaches.
 
It already was!

Regards,
wink4.gif
ldnewbie
 
Solution to what?
BTW, site is down at the moment!

Regards,
wink4.gif
ldnewbie
 
A solution as to how the y-a site was done - I've got one if anyone needs it. It seems to be one of the perennial questions in Flash forums is all...
 
wangbar , can post the .fla for you scroller as it's kool. Regards

Big Dave

davidbyng@hotmail.com


** If I am wrong I am sorry, but i'm only trying to help!! **

 
Thanx! Regards

Big Dave

davidbyng@hotmail.com


** If I am wrong I am sorry, but i'm only trying to help!! **

 
Sorry, renamed it at the last minute so as not to overwrite a <div> tag that I added to the html page.
 
Check this :

faq250-1433 Regards

Big Bad Dave

davidbyng@hotmail.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top