[F8] a simple one... if mc._x<-200, how to stop the mc moving?
this is simple and reveals my non existent ac skills:
i have a simple sideways scrolling menu. it functions ok, but i don't manage to stop the scroll when the menu_mc has reached it's end, that it, when menu_mc._x < -200. i've tried different if-statements without success. here's the part that does work all right:
hmm. *scratches head* ralgoth, it works, but not quite as it should. now, when the menu_mc reaches the limit point (the limit point, geedubb, is what i mean with -200: at that x value the right end of the menu has reached the main movie's right side limit) the menu_mc just gets stuck there and won't scroll back any more. i need it to scroll within the given limits. i tried this already, btw. any other ideas...?
Here.. this may be a bit more simple than you're looking for, but it works. It basically will detect if the mouse is to the left or right of the center stage, and then scroll the menu accordingly.
I've never tried to put together a smooth scrolling menu, so the math I'm sure could be adjusted. If you want to make it a little less choppy, rather than having the menu scroll if it's past the center, you could make it scroll if it's near the edges. something like...
hi there, ralgoth!
so many curvy roads all lead to rome, don't they i modified your first code a bit, and it's close to perfect ( i just changed the pointer_mc bits so it follows the mouse better, and as i use fixed screen size, will also change the Stage.width's into numbers)
this one works almost ok, but the thing often pauses to think for a good few secs until it moves again, i suppose because there's a lot of stuff for flash to chew upon. or...? it's not a catastrophy, but sometimes the pauses seem reeeeally long. anyway, ralgoth, the result sure looks better than all my efforts so far, so thanks for the tips already!
but, as the code i started with, was a lot simpler, i suppose there has to be an easier way to do this. it'd sure be nice to see that, wouldn't it! so, anyone, please come to our rescue..?
addition to the previous: i noticed that once the menu has reached its given limits, you actually have to click the swf for it to scroll again. is there any way to fix this..?
---nnnnaaaah, correction, u don't have to click it, i was just too hasty. but it does pause often. wonder why...
Last edited by mrk13; 09-11-2006 at 11:07 AM.
Reason: too busy me.
you should check out Lee Brimlow's "Creating 3D carousels" tutorial at http://www.gotoandlearn.com. It might not be exactly what you're trying to do, but it'll probably give you a few good ideas.