Groups | Blog | Home
all groups > flash actionscript > august 2004 >

flash actionscript : help with springy buttons


nekkochan
8/22/2004 6:40:27 PM
i have downloaded these springy buttons, which look great:


http://www.flashkit.com/movies/Interfaces/Buttons/Springy_-Darby_Sa-3900/index.p
hp

but I can't figure out how to attach an actual outgoing link to the buttons!!
(what good is a button if it doesn't take you anywhere?)

adding

on (press) getUrl("http://www.thislink.org");
}

to the buttons didn't work...
any help with this greatly appreaciated
(or link to other tutorial or download for springy buttons I can use as
website navigation)

thanks!!
Jack.
8/22/2004 7:07:36 PM
doubleclick on any of the buttonClips to open it, you will
be on the button. you will see the rollOver/ Out scripts.
add a release script to the button -
on(release){
_parent.actions(this);
}
come out of the button and back to scene1 frame3,
add this script to frame3 to control your navigation,

stop();

aUrls = ["","www.blue.org","www.google.com",
"www.egg.com","www.red.com"];

function actions(clip){
bVar = clip._name.split("button").join("");
trace(bVar);
getUrl( "http://" + aUrls[bVar],"_blank" );
};

add links to the array to match your button count,
note the buttons are duplicated from index 1 and
arrays start with index 0 so the array starts with blank ("")

hth
nekkochan
8/24/2004 9:20:25 PM
AddThis Social Bookmark Button