Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion GroupsGeneralPHPASPPerlColdFusionFlashHTML, CSS, ScriptsBrowsers

Webmaster Forum / Flash / Flash Actionscript / July 2005



Tip: Looking for answers? Try searching our database.

scripted MC misplaced or not showing up

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
dontwriteme - 30 Jul 2005 21:33 GMT
Hey,
    Trying to get a picture gallery to show up right

should be duplicating ...

header_mc
pic_mc pic_mc pic_mc pic_mc ...

for each set of images
Comes in the form of an array structure (aHeader, aTracks) //tracks are split
to get names of each image file
Wen published the headers show up correctly but the image slots are not
showing up until the last 3 array items
Traces show everything should be at the right coords and on the right layer
with the approprate amount of images

Thanks for any help
Kent

var sTracks;
mgPic._visible = false;
mgHeader._visible = false;
var evalMgHeader;
var evalMgPic;
var xPic:Number, xyPic:Number, xHead:Number, yPos:Number, xTop:Number,
xRowLoc:Number, xRows:Number;
xPic = 60;
xyPic = 40;
xHead = 20;
yPos = 0;
xTop = 50;
xRowLoc = 0;
function pPrinter() {
    //move originals
    mgPic._y = -xyPic;
    mgHeader._y = -xHead;
    //for each catagory set dividers and start loading
    for (var i = 0; i<aArray.length; i++) {
        //dup the header bar for this catagory
        duplicateMovieClip(mgHeader, "mgHeader"+i, xTop);
        xTop++;
        evalMgHeader = eval("mgHeader"+i);
        evalMgHeader._y = yPos;
        trace("evalMgHeader._y = "+evalMgHeader._y);
        yPos += xHead;
        //set content var
        evalMgHeader.aHeader = aArray[i].aHeader;
        //split tracks
        sTracks = aArray[i].aTracks.split(",");
        ///for each track dup pic slotv
        xRowLoc = 0;
        for (var j = 0; j<sTracks.length; j++) {
            xTop++;
            duplicateMovieClip(mgPic, "mgPic"+j, xTop);
            evalMgPic = eval("mgPic"+j);
            xRowLoc++;
            if (xRowLoc>=8) {
                xRowLoc = 0;
                yPos += xyPic;
            }
            evalMgPic._y = yPos;
            evalMgPic._x = xRowLoc*xPic;
            //set slot to propper position
            //_parent.picClipA.loadClip("images/gallery/"+sTracks[j]+".jpg",
evalMgPic.ceeImage);
        }
        yPos += xyPic;
        //load first image
    }
}
function aStruct(aHeader, aTracks) {
    this.aHeader = aHeader;
    this.aTracks = aTracks;
}
kf_w-l-media - 30 Jul 2005 21:58 GMT
yea im out of it

duplicateMovieClip(mgPic, "mgPic"+j, xTop);
evalMgPic = eval("mgPic"+j);

should have included the i var of the category along with the j var for each
dup mc name

duplicateMovieClip(mgPic, "mgPic"+i+j, xTop);
evalMgPic = eval("mgPic"+i+j);
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.