hello,
I’m trying to build a simple image gallery. I found other
tutorials, but I’m just a beginner and those tutorials are
still to higjt for me.
I have just one problem, I have these two arrays:
var thumbnails:Array = ["p1.jpg", "p2.jpg", "p3.jpg"];
var img:Array = ["p1_l.jpg", "p2_l.jpg", "p3_l.jpg"];
then, I have this code:
var loadListener = new Object();
MCL.onLoadComplete = function(targetMC) {
trace(targetMC); //will trace tmb4, tmb5 or tmb6
targetMC.onRelease = function() {
//here I need to get the array number of the content in the
//targetMC, so I would say gal.M_img.loadClip(img[the same
//number as in the thumbnails array]);
};
};
ran = random(2);
with (MCL) {
loadClip(img[ran], "gal.M_img"); //this is the main clip
//where I want to load the big images
loadClip(thumbnails[0], "gal.tmbnail_bar.tmb4");
loadClip(thumbnails[1], "gal.tmbnail_bar.tmb5");
loadClip(thumbnails[2], "gal.tmbnail_bar.tmb6");
}
MCL.addListener(loadListener);
i found a website http://www.5nak.com/ (go to 2.graphics)
it has the same thing, thumbnail and then the big image; just I red
the tutorial, and it’s too new for me. as I’m doing this for 3 months
now, I’m trying to find a more figurative way
if anybody can help, thank’s a lot