hi guys well again im stuck bin searching a few forums and tutorial site to find something simular to this but still nothing found…
i like to us/creat a menu simular to this menu (www.showlogic.com). my gess is its a soort of streging thingy but how?.. anyone know how or have a tutorial where i can learn to use this type of navigation?
ya that would help me out a lot also, what about the entire movie finding new postitons? moving up/apart room for the sub menus? any idea besides goto and play frames
flashnick, if you want to play particular frames of a a movie clip on release, you’ll first have to put frame labels in that clip, then put those labels in an array, and eventually make the clip play:
// This goes on the first frame of your movie
myLabels = ["About me", "bla", "blo", "bli"] ;
size = 5;
p._visible = false;
cellsize = p._width ;
topscale = cellsize + 90;
lowscale = (size*cellsize-topscale)/(size-1);
i = 1;
but_pressed = 0 ;
while (i <= size) {
var _mc = p.duplicateMovieClip("p_" + i , 100+Number(i*size));
new Color (_mc).setRGB (0xffffff*i/size) ;
_mc.i = i;
_mc.xscale = cellsize ;
_mc.onRollOver = _mc.onDragOver = function () {
but_pressed = this.i ;
} ;
_mc.onRollOut = _mc.onDragOut = function () {
but_pressed = 0 ;
} ;
**_mc.onPress = function () {
yourClip.gotoAndPlay (myLabels[this.i]) ;
} ;**
_mc.onEnterFrame = function () {
var newxscale ;
if (but_pressed != 0) {
if (but_pressed == this.i) {
newxscale = topscale;
} else {
newxscale = lowscale;
}
} else {
newxscale = cellsize;
}
var xstep = (newxscale-this.xscale)/2;
if (this.xscale != newxscale) {
this.xscale += xstep;
} else {
xstep = 0 ;
}
this._xscale = this.xscale;
}
i ++ ;
} ;
this.onEnterFrame = function () {
i = 1;
ypos = 28;
xpos = 68;
while (i <= size) {
var mc = this["p_" + i] ;
mc._x = xpos;
mc._y = ypos;
xpos = xpos + mc._width ;
i ++ ;
}
} ;
You’d have to put the menu inside a container clip, and make that container clip move. Let’s say that the clip we’re duplicating (‘p’) is inside a clip called ‘container’:
size = 5;
p._visible = false;
cellsize = p._width ;
topscale = cellsize + 90;
lowscale = (size*cellsize-topscale)/(size-1);
i = 1;
but_pressed = 0 ;
while (i <= size) {
var _mc = **container.**p.duplicateMovieClip("p_" + i , 100+Number(i*size));
new Color (_mc).setRGB (0xffffff*i/size) ;
_mc.i = i;
_mc.xscale = cellsize ;
_mc.onRollOver = _mc.onDragOver = function () {
but_pressed = this.i ;
} ;
_mc.onRollOut = _mc.onDragOut = function () {
but_pressed = 0 ;
} ;
** _mc.onPress = function () {
this._parent.easeTo (20, 50) ;
} ;**
_mc.onEnterFrame = function () {
var newxscale ;
if (but_pressed != 0) {
if (but_pressed == this.i) {
newxscale = topscale;
} else {
newxscale = lowscale;
}
} else {
newxscale = cellsize;
}
var xstep = (newxscale-this.xscale)/2;
if (this.xscale != newxscale) {
this.xscale += xstep;
} else {
xstep = 0 ;
}
this._xscale = this.xscale;
}
i ++ ;
} ;
this.onEnterFrame = function () {
i = 1;
ypos = 28;
xpos = 68;
while (i <= size) {
var mc = **container**["p_" + i] ;
mc._x = xpos;
mc._y = ypos;
xpos = xpos + mc._width ;
i ++ ;
}
} ;
**function easeTo (x, y) {
this.onEnterFrame = function () {
var dx = x - this._x ;
var dy = y - this._y ;
if (Math.abs (dx) > 1 || Math.abs (dy) > 1) {
this._x += dx / 5 ;
this._y += dy / 5 ;
}
else {
this._x = x ;
this._y = y ;
delete this.onEnterFrame ;
}
} ;
} ;**
I really just want to know how to create hyperlinks to the main sections from generated dynamic menu items.
In the original web site (showlogic) the menu options (about us / services / work / contact us et.) load their respective movies into 2 places. How are those movies referenced via the generated menu tabs.
I’m probably making this a lot harder than it is, so please forgive me if i’m being a prat.
I’ve found lots of examples of these types of menus, but cant find the code to actually produce hyperlinks.
Thanks for all your help.
flashnick
Creating engaging and entertaining content for designers and developers since 1998.