I followed the hover caption tutorial here on kirupa, and it seems that i can’t have more than 1 mc act as a caption.
So far i got 2 mc’s, caption1, and caption 2.
caption1 has the following Actionscript on it:
onClipEvent (enterFrame) {
if (_root.x==1) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
caption2 has:
onClipEvent (enterFrame) {
if (_root.x==2) {
this._alpha = 100;
} else {
this._alpha = 0;
}
}
The Actionscript i have on the root timeline is:
startDrag(_root.caption1, true);
startDrag(_root.caption2, true);
Then on the Movieclips that i want the captions to appear, on the first one corresponding to caption1 i got:
on (rollOver) {
gotoAndPlay(2);
_root.x = 1;
}
on (rollOut) {
gotoAndPlay(42);
_root.x = 0;
}
And caption2:
on (rollOver) {
gotoAndPlay(2);
_root.x = 2;
}
on (rollOut) {
gotoAndPlay(42);
_root.x = 0;
}
Only the second caption (caption2) appears, but if i remove the actionscript for it on the timeline, the first one appears ?
Thanks,
Karl