Help With No Repeat From Random Xml Load
I have a script I've been using on many sites that randomly loads an image from an xml file, and it works great. It loads an image, the image plays for 90 frames, goes back to frame one and repeats.
Now I'd like to enhance it so it doesn't repeat the last image, and I can't seem to get it to work. Any help would be great! Here's my original scritpt:
Code: imgXML = new XML(); imgXML.ignoreWhite = true; imgXML.onLoad = function(succes){ if (succes){ images = imgXML.firstChild.firstChild.childNodes; imageIndex = Math.round(Math.random()*(images.length-1)); imageSRC = images[imageIndex].firstChild.nodeValue; imageURL = images[imageIndex].attributes.url; imageTARGET = images[imageIndex].attributes.target;
doMenu(this); trace(imageSRC + " (" + imageURL + ")" + " (" + imageTARGET + ")");
} } imgXML.load("/images/top_banner/top_banner.xml"); function doMenu(xml:XML) { empty_mc.loadMovie(imageSRC); main_button.onRelease = function () { getURL (imageURL, imageTARGET); } };
FlashKit > Flash Help > Flash ActionScript
Posted on: 07-22-2008, 04:54 PM
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
- Another Random Swf Load Without Repeat
- Help With No Repeat From Random Xml Load
- Load Random Movie (no Repeat)
- Load Img Via XML Scale Random Img Up/down, Repeat
- How Do I Load Random Script With No Repeat Instances?
- Actionscript To Load Random External Movie, Fade In, Wait, Fade Out, Repeat
- Random Repeat
- Random Repeat Help
- Random No Repeat
- [F8] Random - No Repeat...
- Random Int W/out Repeat
- Random - No Repeat...
- Random Function With No Repeat
- Random Frame No Repeat
- Random Choice, With No Repeat...
- Random Quotes With No Repeat
- No Repeat With Random Photos
- Random Quotes Without Repeat
- Random Play But Not Repeat
- Random Frames, No Repeat
- Repeat After Random Delay?
- Random Frames With No Repeat
- Random Images From Xml With No Repeat
- Need To Create 12 Random Non-repeat Variables?
- Attach 5 Random Movies Without Repeat
- Flash Quiz Random? Repeat?
- Random Frame Prevent Repeat
- Repeat Random Numbers Problem
- Repeat Random Numbers Problem
- Repeat Sounds With Random Delay
- Help With Random Images So None Repeat Untill All Have Shown
- Flash MX: How To Create An Array So That The Random Imports Don't Repeat?
- Thai-English Audio Quiz, Random-no Repeat, ?
- Drag+drop; 1 Element At A Time, Random Order, No Repeat
- Load Randon Movie Once (no Repeat)
- Load Movie Randomly No Repeat
- Load External SWF's Randomly With No Repeat - Problem
- LONG VIDEO LOAD ON REPEAT VISIT
- Load Image In Separate Movie Clips And Repeat?
- Asp For No Repeat Flash For Repeat Visitors?
- PLEASE HELP - URGENT Load Random Swfs From Individual Random Sets
- Load Random Swfs From Two Differnet Random Sources
- Start Non-repeat And Then Repeat?
- Load A Flash Movie To A Random Frame Each Load
- Load A Flash Movie To Specified Random Frames Each Load
- Load Random Mc.. Wait.. Then Load Following Mc
- Random Load
- Load Random SWF
- Load Random Mc ( HELP PLEASE)
Another Random Swf Load Without Repeat
Hi All,
I'm not great at AS and this problem is driving me nuts so I was wondering if any of you wizards could help me out. I've seen lots of threads on this subject but I can't find a definitive solution...
Here goes...
I've got 5 movies so far called image0.swf, image1.swf etc. I'd like to load any of them randomly at the beginning of a parent movie. The time line of each movie matches that of the parent movie so when the parent movie gets to the end and goes back to the beginning, the code in frame 1 will randomly load one of the imageX.swf movies again. The code I have works but it sometimes repeats the same movie 2,3 or 4 times before loading another. How can I stop this repeat from happening?
the code is...
filename = ["image0.swf", "image1.swf", "image2.swf", "image3.swf"];
path = "images/";
i = filename.length;
k = Math.floor(Math.random()*i);
loadMovie(path+filename[k], movieTarget);
PS - there's any empty movie clip with the instance name movie target
- my imageX.swf files are in a folder images/ as shown in the path above
Example page http://www.g3m.info/arccreative/ddl/...randomload.htm
Many Thanks,
Leeg
Help With No Repeat From Random Xml Load
I have a script I've been using on many sites that randomly loads an image from an xml file, and it works great. It loads an image, the image plays for 90 frames, goes back to frame one and repeats.
Now I'd like to enhance it so it doesn't repeat the last image, and I can't seem to get it to work. Any help would be great! Here's my original scritpt:
Code:
imgXML = new XML();
imgXML.ignoreWhite = true;
imgXML.onLoad = function(succes){
if (succes){
images = imgXML.firstChild.firstChild.childNodes;
imageIndex = Math.round(Math.random()*(images.length-1));
imageSRC = images[imageIndex].firstChild.nodeValue;
imageURL = images[imageIndex].attributes.url;
imageTARGET = images[imageIndex].attributes.target;
doMenu(this);
trace(imageSRC + " (" + imageURL + ")" + " (" + imageTARGET + ")");
}
}
imgXML.load("/images/top_banner/top_banner.xml");
function doMenu(xml:XML) {
empty_mc.loadMovie(imageSRC);
main_button.onRelease = function () {
getURL (imageURL, imageTARGET);
}
};
Load Random Movie (no Repeat)
Does anyone know how load non repetative random movies (swf). I want to load ten of them. Please let me know how to do this. Thanks a lot!
Load Img Via XML Scale Random Img Up/down, Repeat
Hello guru's and Flash gods. I have a different type of slideshow that I'd like to get finished by tomorrow. Yeah, I know, no time but I've got to do what I can.
Here's the desired effect:
-the movie loads all the images via XML and displays them in a grid of squares
-a random images is chosen and scales up to full size
-pause
-the large images scales back down to its original position and size
-another random image is chosen and the scaling process is repeated indefinitely.
Any ideas? My client is looking to use this for a tradeshow.
How Do I Load Random Script With No Repeat Instances?
Hello,
I'm not sure how to go about this since I'm fairly new to ActionScript, but I have this script which displays random image and quote. It works fine as is, but how do I make it not repeat any of the items untill it has gone through all of them?
I really appreciate any help you can provide.
Here is the script I'm using now:
choice = Math.round(Math.random()*19);
switch (choice) {
case 0 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb1.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona1.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text1.txt", "_root.firstquote");
break;
case 1 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb2.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona2.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text2.txt", "_root.firstquote");
break;
case 2 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb3.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona3.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text3.txt", "_root.firstquote");
break;
case 3 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb4.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona4.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text4.txt", "_root.firstquote");
break;
case 4 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb5.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona5.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text5.txt", "_root.firstquote");
break;
case 5 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb6.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona6.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text6.txt", "_root.firstquote");
break;
case 6 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb7.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona7.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text7.txt", "_root.firstquote");
break;
case 7 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb8.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona8.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text8.txt", "_root.firstquote");
break;
case 8 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb9.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona9.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text9.txt", "_root.firstquote");
break;
case 9 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb10.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona10.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text10.txt", "_root.firstquote");
break;
case 10 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb11.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona11.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text11.txt", "_root.firstquote");
break;
case 11 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb12.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona12.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text12.txt", "_root.firstquote");
break;
case 12 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb13.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona13.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text13.txt", "_root.firstquote");
break;
case 13 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb14.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona14.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text14.txt", "_root.firstquote");
break;
case 14 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb15.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona15.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text15.txt", "_root.firstquote");
break;
case 15 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb16.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona16.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text16.txt", "_root.firstquote");
break;
case 16 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb17.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona17.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text17.txt", "_root.firstquote");
break;
case 17 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb18.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona18.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text18.txt", "_root.firstquote");
break;
case 18 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb19.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona19.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text19.txt", "_root.firstquote");
break;
case 19 :
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/personb20.jpg", "_root.personb");
loadMovie("http://www.beachbody.com/images/us/local/v3/homepage/flash01/persona20.jpg", "_root.persona");
loadVariables("http://www.beachbody.com/images/us/local/v3/homepage/flash01/text20.txt", "_root.firstquote");
break;
}
Actionscript To Load Random External Movie, Fade In, Wait, Fade Out, Repeat
Hello,
I'm trying to construct some AS3 that will load a random one of several external swf files, fade the instance in, wait 5 seconds, fade the instance out, and load a new random movie (it can be the same one; I don't want to get too complicated at this point).
I could do this with no problem using older methods, but the client insists this is written in 3.
Please help; I'm at my wits end!
Random Repeat
I've got the code for this random banner in my movie. problem is that every so often, the random number generated will be the same number twice in a row, thus getting the same banner, twice in a row.
Could one of you actionscripting wizzards please annotate my code to prevent a number from repeating itself twice in a row?
banners = new Array("1.swf", "2.swf","4.swf","5.swf","6.swf","7.swf","8.swf","9 .swf","10.swf","11.swf","12.swf","13.swf","14.swf" ,"15.swf");
function randomBanner() {
randomNumber = random(banners.length);
loadMovie(banners[randomNumber], "_root.slideshow");
}
randomBanner();
Thank You in advance
Random Repeat Help
Hi there,
I'm trying to repeat a randomly apearing mc. So far I have the mc duplicated 3 times, simple enough;
Code:
for (i=1;i<3;i++){
effect_mc.duplicateMovieClip("effect_mc"+i,i);
}
As for my mc I've added this to it;
Code:
onClipEvent (load) {
_x = Math.random()*750;
_y = Math.random() *460;
}
But I want the mc which contains a short animation to repeat itself in a random position and then looped continously, any help would be appreciated.
thanks - itchyjam
Random No Repeat
Hi
I am in the process of designing a photographers site with a page that randomly displays 10 images from an XML file containg about 100 images the problem is that it can occaisionaly have identical images on the same page. Is there a way of loading the ten images so that they are all different. I have included the code I am using.
Code:
function loadXML(loaded) {
if (loaded) {
xmlNode = this.firstChild;
thumb1 = [];
thumb2 = [];
thumb3 = [];
thumb4 = [];
thumb5 = [];
thumb6 = [];
thumb7 = [];
thumb8 = [];
thumb9 = [];
thumb10 = [];
logo = [];
caption = [];
email = [];
menu = [];
next = [];
total = xmlNode.childNodes.length;
for (i=0; i<total; i++) {
thumb1[i] = xmlNode.childNodes[i].childNodes[0].firstChild.nodeValue;
thumb2[i] = xmlNode.childNodes[i].childNodes[1].firstChild.nodeValue;
thumb3[i] = xmlNode.childNodes[i].childNodes[2].firstChild.nodeValue;
thumb4[i] = xmlNode.childNodes[i].childNodes[3].firstChild.nodeValue;
thumb5[i] = xmlNode.childNodes[i].childNodes[4].firstChild.nodeValue;
thumb6[i] = xmlNode.childNodes[i].childNodes[5].firstChild.nodeValue;
thumb7[i] = xmlNode.childNodes[i].childNodes[6].firstChild.nodeValue;
thumb8[i] = xmlNode.childNodes[i].childNodes[7].firstChild.nodeValue;
thumb9[i] = xmlNode.childNodes[i].childNodes[8].firstChild.nodeValue;
thumb10[i] = xmlNode.childNodes[i].childNodes[9].firstChild.nodeValue;
logo[i] = xmlNode.childNodes[i].childNodes[10].firstChild.nodeValue;
caption[i] = xmlNode.childNodes[i].childNodes[11].firstChild.nodeValue;
email[i] = xmlNode.childNodes[i].childNodes[12].firstChild.nodeValue;
menu[i] = xmlNode.childNodes[i].childNodes[13].firstChild.nodeValue;
next[i] = xmlNode.childNodes[i].childNodes[14].firstChild.nodeValue;
}
firstImage();
} else {
content = "file not loaded!";
}
}
xmlData = new XML();
xmlData.ignoreWhite = true;
xmlData.onLoad = loadXML;
xmlData.load("../tx/wedding.xml");
listen = new Object();
listen.onKeyDown = function() {
if (Key.getCode() == Key.LEFT) {
prevImage();
} else if (Key.getCode() == Key.RIGHT) {
nextImage();
}
};
Key.addListener(listen);
previous_btn.onRelease = function() {
prevImage();
};
next_btn.onRelease = function() {
nextImage();
};
p = 0;
this.onEnterFrame = function() {
filesize = picture.getBytesTotal();
loaded = picture.getBytesLoaded();
preloader._visible = true;
if (loaded != filesize) {
preloader.preload_bar._xscale = 100*loaded/filesize;
} else {
preloader._visible = false;
if (picture._alpha<100) {
picture._alpha += 10;
}
}
};
function firstImage() {
if (loaded == filesize) {
picture._alpha = 0;
picture.loadMovie(image[0], 1);
thm1.loadMovie(thumb1[Math.floor(Math.random()*total)], 1);
thm1._rotation = -14;
thm2.loadMovie(thumb2[Math.floor(Math.random()*total)], 1);
thm2._rotation = 0;
thm3.loadMovie(thumb3[Math.floor(Math.random()*total)], 1);
thm3._rotation = 18;
thm4.loadMovie(thumb4[Math.floor(Math.random()*total)], 1);
thm4._rotation = -15;
thm5.loadMovie(thumb5[Math.floor(Math.random()*total)], 1);
thm5._rotation = 0;
thm6.loadMovie(thumb6[Math.floor(Math.random()*total)], 1);
thm6._rotation = 17;
thm7.loadMovie(thumb7[Math.floor(Math.random()*total)], 1);
thm7._rotation = 10;
thm8.loadMovie(thumb8[Math.floor(Math.random()*total)], 1);
thm8._rotation = 0;
thm9.loadMovie(thumb9[Math.floor(Math.random()*total)], 1);
thm9._rotation = -22;
thm10.loadMovie(thumb10[Math.floor(Math.random()*total)], 1);
thm10._rotation = 12;
logo_txt.text = logo[0];
caption_txt.text = caption[0];
email_txt.text = email[0];
menu_txt.text = menu[0];
next_txt.text = next[0];
}
}
Regards Barry
[F8] Random - No Repeat...
I need to get a set of random numbers into an array, but I can't have any numbers repeat. So, as a practical example I will need, say, 10 numbers that all fall between, say, 1 and 50, but I need ALL 10 numbers to be different. Order is not important (lowest to highest, highest to lowest, mixed-up, whatever - as long as there's no duplicates). Does that make sense?...
I currently can get the numbers into the array, but I can't figure out what I need to change to get them to not duplicate. Here's what I currently have:
Code:
var random_arr:Array = new Array();
function randRange(min:Number, max:Number):Number {
var randomNum:Number = Math.floor(Math.random() * (max - min + 1)) + min;
return randomNum;
}
for (var i = 0; i < 10; i++) {
var n:Number = randRange(1, 50);
random_arr.push(n);
trace(random_arr);
}
Random Int W/out Repeat
hi there,
can someone tell me how i should go about making a function that returns a random int w/out repeating?
i was thinking:
ActionScript Code:
function rand_norep(prev:uint):uint
{
var pickint:uint = Math.floor(Math.random()*4);
while(1)
{
if(prev!=pickint)
{
break;
}
else
{
pickint = Math.floor(Math.random()*4);
}
}
return pickint;
}
would this be sufficient?
i'm tracing my output and sometimes i don't see anything...
is this because it could take a while to iterate through w/out a repetition and that may cause the variable to be undefined during that call of the function?
thanks,
f_y
Random - No Repeat...
I need to get a set of random numbers into an array, but I can't have any numbers repeat. So, as a practical example I will need, say, 10 numbers that all fall between, say, 1 and 50, but I need ALL 10 numbers to be different. Order is not important (lowest to highest, highest to lowest, mixed-up, whatever - as long as there's no duplicates). Does that make sense?...
I currently can get the numbers into the array, but I can't figure out what I need to change to get them to not duplicate. Here's what I currently have:
Attach Code
var random_arr:Array = new Array();
function randRange(min:Number, max:Number):Number {
var randomNum:Number = Math.floor(Math.random() * (max - min + 1)) + min;
return randomNum;
}
for (var i = 0; i < 10; i++) {
var n:Number = randRange(1, 50);
random_arr.push(n);
trace(random_arr);
}
Edited: 11/14/2006 at 11:52:56 AM by DIY_Lobotomy
Random Function With No Repeat
Guys, I have a big problem
It is to do with randomising which one of 4 frames the movie goes to.
I have a script which randomly selects 1 of four frames.
frames = 4;
frameno = Math.ceil(Math.random()*frames);
gotoAndStop (frameno+1);
But i want it so that it only selects each frame once
If anyone has any idea on how to do this i would be so graftul.
Matt
Random Frame No Repeat
hello all.
how i would write a frame action that tells my movie to goto a random frame on the root timeline but not to be the one it's on at present. please help as i have NO IDEA! how to do this
thanks alot.
Random Choice, With No Repeat...
I am using Flash MX to create a script that randomly chooses a side of a cube, but has checking to prevent a repeated choice... I am having a heck of a time getting this checking to work... see the code below, maybe someone has some ideas on why it isn't working?
// choose a random cube
function uniqueRandomCube() {
while (randyCube == randyOldCube) {
randyCube = Math.ceil(Math.random()*6);
trace("this is the randycube: " + randyCube);
return randyCube;
}
}
randyOldCube = randyCube;
trace("this is the randyOldCube: " + randyOldCube);
Random Quotes With No Repeat
I have a basic dynamic text box importing random quotes from an external .txt file. How can I get the quotes to display without repeating until all of the quotes have been viewed?
Thanks in advance.
No Repeat With Random Photos
How do I create the prevents from repeating random photos? I have scripts that is working well but needs to stop the repeating...
Here's the XML code:
<!--
'timer' :: number of seconds between each image transition
'order' :: how you want your images displayed. choose either 'sequential' or 'random'
'looping' :: if the slide show is in sequential mode, this stops the show at the last image (use 'yes' for looping, 'no' for not)
'fadeTime' :: velocity of image crossfade. Increment for faster fades, decrement for slower. Approximately equal to seconds.
'xpos' :: _x position of all loaded clips (0 is default)
'ypos' :: _y position of all loaded clips (0 is default)
-->
<gallery timer="5" order="random" fadetime="2" looping="yes" xpos="0" ypos="0">
<image path="images/1.swf" />
<image path="images/2.swf" />
<image path="images/3.swf" />
<image path="images/4.swf" />
<image path="images/5.swf" />
<image path="images/6.swf" />
<image path="images/7.swf" />
<image path="images/8.swf" />
<image path="images/9.swf" />
<image path="images/10.swf" />
<image path="images/11.swf" />
<image path="images/12.swf" />
<image path="images/13.swf" />
<image path="images/14.swf" />
<image path="images/15.swf" />
<image path="images/16.swf" />
<image path="images/17.swf" />
<image path="images/18.swf" />
<image path="images/19.swf" />
<image path="images/20.swf" />
<image path="images/21.swf" />
<image path="images/22.swf" />
<image path="images/23.swf" />
<image path="images/24.swf" />
<image path="images/25.swf" />
<image path="images/26.swf" />
<image path="images/27.swf" />
</gallery>
ACTION SCRIPT:::::
// set random # variables - each must be 0 for first 'while' loop below
var randomNum = 0;
var randomNumLast = 0;
// parent container
var container_mc = this.createEmptyMovieClip("container",0);
// movie clip containers
container_mc.createEmptyMovieClip("loader1_mc",2);
container_mc.createEmptyMovieClip("loader2_mc",1);
// preload watcher
this.createEmptyMovieClip("watcher_mc",100);
// load xml
images_xml = new XML();
images_xml.ignoreWhite=true;
images_xml.onLoad = parse;
images_xml.load("images.xml");
function parse(success) {
if (success) {
imageArray = new Array();
var root = this.firstChild;
_global.numPause = Number(this.firstChild.attributes.timer * 1000);
_global.order = this.firstChild.attributes.order;
_global.looping = this.firstChild.attributes.looping;
_global.fadetime = Number(this.firstChild.attributes.fadetime);
_global.xpos = Number(this.firstChild.attributes.xpos);
_global.ypos = Number(this.firstChild.attributes.ypos);
var imageNode = root.lastChild;
var s=0;
while (imageNode.nodeName != null) {
imageData = new Object;
imageData.path = imageNode.attributes.path;
imageArray[s]=imageData;
imageNode = imageNode.previousSibling;
s++;
}
// place parent container
container_mc._x = _global.xpos;
container_mc._y = _global.ypos;
// parse array
imageArray.reverse();
imageGen(imageArray);
} else {
trace('problem');
}
}
// depth swapping
function swapPlace(clip,num) {
eval(clip).swapDepths(eval("container_mc.loader"+n um+"_mc"));
}
function loadImages(data,num) {
if (i==undefined || i == 2) {
i=2;
createLoader(i,data,num);
i=1;
} else if (i==1) {
createLoader(i,data,num);
i=2;
}
}
function createLoader(i,data,num) {
thisLoader=eval("container_mc.loader"+i+"_mc");
thisLoader._alpha=0;
thisLoader.loadMovie(data[num].path);
watcher_mc.onEnterFrame=function () {
var picLoaded = thisLoader.getBytesLoaded();
var picBytes = thisLoader.getBytesTotal();
if (isNaN(picBytes) || picBytes < 4) {
return;
}
if (picLoaded / picBytes >= 1) {
swapPlace("container_mc.loader2_mc",1);
alphaTween = new mx.transitions.Tween(thisLoader, "_alpha", mx.transitions.easing.Regular.easeOut,0,100,_globa l.fadetime,true);
timerInterval = setInterval(imageGen,_global.numPause,data);
delete this.onEnterFrame;
}
}
}
function imageGen(data) {
// random, or sequential?
if (_global.order=="random") {
// choose random # between 0 and total number of images
while (randomNum == randomNumLast) {
randomNum = Math.floor(Math.random() * data.length);
trace(randomNum);
}
loadImages(data,randomNum);
randomNumLast = randomNum;
} else if (_global.order=="sequential") {
// start at 0, increment to total number of images, then drop back to zero when done
if (p==undefined || p==data.length && _global.looping=="yes") { p=0; } else { break; }
loadImages(data,p);
p++;
} else {
trace ("order attribute in xml isn't correct - must specify either 'random' or 'sequential'");
}
clearInterval(timerInterval);
}
stop();
Random Quotes Without Repeat
I have a basic dynamic text box importing random quotes from an external .txt file. How can I get the quotes to display without repeating until all of the quotes have been viewed?
Thanks in advance.
Random Play But Not Repeat
I have a looping function that loads a random sound each time it plays. But how do I prevent a sound from playing two times in a row? I have struggled with my own solutions to this for months and never arrived at a satisfactory answer.
Here's the basic script I'm trying to modify (it's for an obnoxious soft porn e-card). Works fine (the Sound objects are defined elsewhere in the file). But I don't want the same moan to repeat twice in a row, which often occurs.
ActionScript Code:
oohBabe = function () {
clearInterval(oohBabeID);
ooh.attachSound("moan"+Math.ceil(Math.random()*6));
ooh.start(0, 1);
oohBabeID = setInterval(oohBabe, Math.random()*3000+2000);
};
oohBabe();
Random Frames, No Repeat
I have a quiz that starts on frame 5 and ends on frame 14.
I'm trying to get it so when you click the next button it randomly selects a frame between 5 and 14 without repeating. Once the frames have all been done, it goes to frame 15.
I have this code below, but when I click next, the trace currentFrame selects 3 frames at a time. Example: click next button, trace output (5), hit next again,
trace output(5 8 12), hit it again, trace output (5 8 12 14 8 3). So I've only hit the next button 3 times, but it's randomly seleced 6 or more frames.(it changes every time)
Code:
var myarr=[0,1,2,3,4,5,6,7,8,9];
function findNewFrame() {
var num=Math.floor(Math.random()*myarr.length);
gotoAndStop(num+5);
myarr.splice(num,1);
if(num<=1)gotoAndStop(15);
trace(currentFrame);
}
Help anyone?
Thanks
Repeat After Random Delay?
Hello,
I have this movie clip here, except it just loops when it reaches the end of the timeline (as they normaly do :p) Anywho, I'd like it to loop after a random delay.... Between 0, and 3 seconds. I know it has somthing to do with the math.Random() function, but Im a noob to the world of actionscript.
Thanks!!
Hey, just an afterthought here, would it be possible to decrease the time it takes to loop, as it loops more and more.... Like after 10 loops, it randomly selects a number between 0, and 2.5... and after 20 loops; between 0, and 2, and so on, until it loops like a normal movie clip?
Thanks again!
Random Frames With No Repeat
Hey guys!
This time I'm trying to access random frames between 1 and 10. That bit's easy, yay for help files.
function randRange(min:Number, max:Number):Number {
var randomNum:Number = Math.floor(Math.random() * (max - min + 1)) + min;
return randomNum;
}
btn.onPress = function() {
n = randRange(1,10);
gotoAndStop(n);
}
Now the problem is that I want it to visit each frame only once. So, to check this, I've popped a simple Boolean at the top of each frame called f1, f2, etc, but only for frames 1-5 for checking purposes. Whether it's frames 1-5 or 1-10 doesn't really matter at this point.
My problem is that I need to check that n against the number in my f variables. It's easy to make a string, but how do I check that against a boolean?
frameCheck = "f"+n;
trace(frameCheck);
I keep feeling like I've almost got it, and then the whole concept eludes me. My immediate problem is the checking, but if anyone knows a better way to do the checking, I'd be grateful (that's the only reason I popped it up there).
Thanks heaps!
Random Images From Xml With No Repeat
I've a client using the code from source from dominey, but the images sometimes overlap/repeat - so one image may load first several times, and some images may never get to the top position. How can I have this not repeat until all have been viewed.
Here's the AS - I'm still on MX since I do almost no Flash work.
CODE// set random # variables - each must be 0 for first 'while' loop below
var randomNum = 0;
var randomNumLast = 0;
// parent container
var container_mc = this.createEmptyMovieClip("container",0);
// movie clip containers
container_mc.createEmptyMovieClip("loader1_mc",2);
container_mc.createEmptyMovieClip("loader2_mc",1);
// preload watcher
this.createEmptyMovieClip("watcher_mc",100);
// load xml
images_xml = new XML();
images_xml.ignoreWhite=true;
images_xml.onLoad = parse;
images_xml.load("http://capegazette.com/showcaseNew/showcaseImages.xml");
function parse(success) {
if (success) {
imageArray = new Array();
var root = this.firstChild;
_global.numPause = Number(this.firstChild.attributes.timer * 1000);
_global.order = this.firstChild.attributes.order;
_global.looping = this.firstChild.attributes.looping;
_global.fadetime = Number(this.firstChild.attributes.fadetime);
_global.xpos = Number(this.firstChild.attributes.xpos);
_global.ypos = Number(this.firstChild.attributes.ypos);
var imageNode = root.lastChild;
var s=0;
while (imageNode.nodeName != null) {
imageData = new Object;
imageData.path = imageNode.attributes.path;
imageArray[s]=imageData;
imageNode = imageNode.previousSibling;
s++;
}
// place parent container
container_mc._x = _global.xpos;
container_mc._y = _global.ypos;
// parse array
imageArray.reverse();
imageGen(imageArray);
} else {
trace('problem');
}
}
// depth swapping
function swapPlace(clip,num) {
eval(clip).swapDepths(eval("container_mc.loader"+num+"_mc"));
}
function loadImages(data,num) {
if (i==undefined || i == 2) {
i=2;
createLoader(i,data,num);
i=1;
} else if (i==1) {
createLoader(i,data,num);
i=2;
}
}
function createLoader(i,data,num) {
thisLoader=eval("container_mc.loader"+i+"_mc");
thisLoader._alpha=0;
thisLoader.loadMovie(data[num].path);
watcher_mc.onEnterFrame=function () {
var picLoaded = thisLoader.getBytesLoaded();
var picBytes = thisLoader.getBytesTotal();
if (isNaN(picBytes) || picBytes < 4) {
return;
}
if (picLoaded / picBytes >= 1) {
swapPlace("container_mc.loader2_mc",1);
thisLoader.alpha(_global.fadeTime,100);
timerInterval = setInterval(imageGen,_global.numPause,data);
delete this.onEnterFrame;
}
}
}
function imageGen(data) {
// random, or sequential?
if (_global.order=="random") {
// choose random # between 0 and total number of images
while (randomNum == randomNumLast) {
randomNum = Math.floor(Math.random() * data.length);
trace(randomNum);
}
loadImages(data,randomNum);
randomNumLast = randomNum;
} else if (_global.order=="sequential") {
// start at 0, increment to total number of images, then drop back to zero when done
if (p==undefined || p==data.length && _global.looping=="yes") { p=0; } else { break; }
loadImages(data,p);
p++;
} else {
trace ("order attribute in xml isn't correct - must specify either 'random' or 'sequential'");
}
clearInterval(timerInterval);
}
container_mc.onPress = function(){
getURL("http://capegazette.powweb.com/listings.php", "_top");
}
stop();
Need To Create 12 Random Non-repeat Variables?
I need to create 12 random numbers (non-repeating) that I can call on one at a time as variables. (Ex. variables a1 thru a12 would be random numbers 1 thru 12). I want to use these later to tell an 12 MC instances to go to one of 12 frame labels and non of them be on the same label.
I've tried it a couple different ways and have come very close but each method has a different bug in it. Can anyone help?
Neo
Attach 5 Random Movies Without Repeat
Hei I have this card game where want to attach 5 random MC from library in diffrent positions without repeating the same MC twice.
Having problems with attatching more then one MC. Please help me!
This is what I got:
onClipEvent (load) {
Deck = new Array();
Cards = new Array();
for (i=0; i<52; i++) {
Deck[i] = ""+(i+1);
}
for (i=0; i<5; i++) {
randomNum = Math.floor(Math.random()*Deck.length);
Cards[i] = Deck[randomNum];
Deck.splice(randomNum, 1);
this.attachMovie(Cards[i], "cards"+i, i);
this._x = 100;
}
}
Thanks a lot!!
Flash Quiz Random? Repeat?
Hi,
I am building a flash test using one of the built-in flash quiz templates.
I have 15 question from which 10 are randomly asked, but the problem I have is that the built in random question function seems to be repeating questions?
This is driving me mad? Anyone ever had this problem?
Stephen
Random Frame Prevent Repeat
obj.gotoAndStop(random(8));
this goes to a frame number. eg. on first load, obj frame jumps to 5, next load ,another frame number but sometimes back to 5. because 5 is still within the random condition of 8. how to I prevent a repete?
Repeat Random Numbers Problem
Is there any way of preventing repeat numbers in random number generation?
I’ve tried using the pop function and the delete function on elements in an array which are randomly selected, but can’t get the effect I want. I’ve even tried making two variable values equivalent to each other to try and constrict repetition –but no joy.
Can anyone give me any more ideas? Many thanks.
meandmymachine
Repeat Random Numbers Problem
Is there any way of preventing repeat numbers in random number generation?
I’ve tried using the pop function and the delete function on elements in an array which are randomly selected, but can’t get the effect I want. I’ve even tried making two variable values equivalent to each other to try and constrict repetition –but no joy.
Can anyone give me any more ideas? Many thanks.
meandmymachine
Repeat Sounds With Random Delay
hello,
i'm new here, and not really good, and excuse me for my poor english.
I've a little probleme :
I have to repeat 4 sound with a random delay for each sound.
And those sound can play in the same time.
The movie just do that (it will be put in an HTML pages)
and a "for" bug the flashplayer
Can anyone help me?
Thank you
Help With Random Images So None Repeat Untill All Have Shown
Hi, I was wondering if anyone can help me with this problem.
I using the following script to randomly attach Movie clips to a empty mc;
//
clipNum = Math.floor((Math.random()*99)+1);
//
name = "img"+clipNum;
//
imageholder.attachMovie("img"+clipNum, name, 1);
I'd like to show all the photos before any of them repeat, (in other words all the photos play only once and only get repeat once all of the 99 fotos have been seen).
I've seen the script using the 'splice' method but I can't get it to work;
nums = new Array();
for (i=0;i<5 - 1;i++) {
nums[i] = i;
} //make an array we'll use for our random numbers
rand = nums.splice(random(nums.length),1)[0]; // gets a random number
//but splice also erases that number from the array so it can't be used again
//then attach that movie
_root.attachMovie("img" + rand, "img1" + rand, rand + 100);
Does anyone have any ideas?
Thanks,
Lenny.
Flash MX: How To Create An Array So That The Random Imports Don't Repeat?
Hi,
I have a slideshow movie that attaches, (randomly),
photo MC's at 1 second intervals.
I use the following code on the first frame,
then on the second is a timer and on the fourth
is a loop back to the first.
clipNum = Math.floor((Math.random()*199)+1);
name = "img"+clipNum;
imageholder.attachMovie("img"+clipNum, name, 1);
I would like to be able to create an array or a 'shuffle'
so that none of the images repeat until they have
all been shown, (then it goes and plays from the
start again).
Can anyone please help me do this as I cannot figure
out how to programme it.
(There are 199 images all together)
Thanks for any help.
Thai-English Audio Quiz, Random-no Repeat, ?
first time posting....tried the search box twice but it didn't work properly. (mac os x, safari?)
I already read about the mx 2004 pro quiz templates, but didn't find an answer there. Hopefully someone can point me in the right direction.
I'm creating a Thai-English instruction course. Each 'page' (which i guess will be a MC since i don't want to use 'screens') will have 4 to 8 photographs along with English and phonetic text for the Thai. (ie. 'Hello' = 'Sa-waht-dee')
When the learner clicks an image, the corresponding audio clip will play....that's the easy part I can do.
But I want to have a 'test me' button which will hide the Thai phonetic text fields (which i hope i can figure out) and randomly play from the audio clips for that page.....without repeating.....ie. choosing 1 of 4, then 1 of 3, then 1 of 2, and then playing the last audio clip, so the test gets easier as a process of elimination, but that's ok. When the learner makes a right choice, I want basic feedback ('good job') and then it plays the next random clip.....and if they make a wrong answer, i want it to repeat the audio clip until they click the right answer........
It seems like it will require actionscript unique for each page, since the number of photos and audio clips will vary somewhat,...but perhaps not....I'm a neophyte.
Any help appreciated. thanks
Mike
Drag+drop; 1 Element At A Time, Random Order, No Repeat
I am producing a drag and drop exercise, where the user drags a description of a word, and has to match it with the correct word.
The 7 descriptions appear at random, one at a time, each time the user clicks on the 'generate description' button.
*The problem I am having is that I only need each phrase to appear once and once it has appeared, it cannot be generated again. Instead flash should know this and instantly generate an unused number.
I have been looking at making 2 arrays, one with unused numbers and one with used numbers. However I have never created arrays before and I am stuggling with that.
I can attach the .fla as it will be easier for you to see what I am trying to do, but I am not sure if this is allowed. please advise on this, guys.
Thanks in advance if you can help,
Mark
Load Randon Movie Once (no Repeat)
Does anyone know how load non repetative random movies (swf). I want to load ten of them. Please let me know how to do this. Thanks a lot!
Load Movie Randomly No Repeat
I have 3 swf's. I want to call them randomly from a main movie but no swf sould repeat. i can call the movies randomly with following script but it repeats. i want to make it no repeat.
on (release) {
RN = random(3);
name = "intro0"+[RN]+".swf";
'intro03.swf'
loadMovieNum(name, 1);
}
Load External SWF's Randomly With No Repeat - Problem
Hi All,
I'm not great at AS and this problem is driving me nuts so I was wondering if any of you wizards could help me out. I've seen lots of threads on this subject but I can't find a definitive solution...
Here goes...
I've got 5 movies so far called image0.swf, image1.swf etc. I'd like to load any of them randomly at the beginning of a parent movie. The time line of each movie matches that of the parent movie so when the parent movie gets to the end and goes back to the beginning, the code in frame 1 will randomly load one of the imageX.swf movies again. The code I have works but it sometimes repeats the same movie 2,3 or 4 times before loading another. How can I stop this repeat from happening?
the code is...
filename = ["image0.swf", "image1.swf", "image2.swf", "image3.swf"];
path = "images/";
i = filename.length;
k = Math.floor(Math.random()*i);
loadMovie(path+filename[k], movieTarget);
PS - there's any empty movie clip with the instance name movie target
- my imageX.swf files are in a folder images/ as shown in the path above
Example page
http://www.g3m.info/arccreative/ddl/...randomload.htm
Many Thanks,
Leeg
LONG VIDEO LOAD ON REPEAT VISIT
I have a site using labels for navigation. One label contains a basic flv component that immediately plays (progressive) when the nav button is clicked. The other buttons go to static frames, i.e. contact, resume, etc. The problem is if I go back to the page with the flv it takes forever to start. Why? This happens in both Firefox & IE, pc & mac. Do I need something in my button code to stop the stream when I leave that page? Perhaps something needs to be cleared? My existing button code is attached. FYI One page has a photogallery and the remove child code clears the stage. Help is appreciated . I'm using AS3. Thanks.
Attach Code
home_btn.addEventListener(MouseEvent.CLICK,onHomeClick);
function onHomeClick(event:MouseEvent):void {
this.gotoAndPlay("home");
SoundMixer.stopAll();
if (thumbsHolder !=null) {
//trace("hello from the first conditional");
sprite.removeChild(thumbsHolder);
thumbsHolder=null;
}
if (loaderHolder!= null) {
//trace("hello from the second conditional");
sprite.removeChild(loaderHolder);
loaderHolder=null;
}
}
audioVideo_btn.addEventListener(MouseEvent.CLICK,onAudioVideoClick);
function onAudioVideoClick(event:MouseEvent):void {
this.gotoAndStop("audioVideo");
SoundMixer.stopAll();
if (thumbsHolder !=null) {
//trace("hello from the first conditional");
sprite.removeChild(thumbsHolder);
thumbsHolder=null;
}
if (loaderHolder!= null) {
//trace("hello from the second conditional");
sprite.removeChild(loaderHolder);
loaderHolder=null;
}
resume_btn.addEventListener(MouseEvent.CLICK,onResumeClick);
function onResumeClick(event:MouseEvent):void {
this.gotoAndStop("resume");
SoundMixer.stopAll();
if (thumbsHolder !=null) {
//trace("hello from the first conditional");
sprite.removeChild(thumbsHolder);
thumbsHolder=null;
}
if (loaderHolder!= null) {
//trace("hello from the second conditional");
sprite.removeChild(loaderHolder);
loaderHolder=null;
}
}
Load Image In Separate Movie Clips And Repeat?
Hey guys,
I need help with actionscript.
I'm trying create a button(s) that loads 1 image in multiple (3) movie clips (SG1, SG2, SG3), one button loads one image (SG1), same button loads it in the next clip (SG2), another button loads it in last clip (SG3) and then repeats (eg. it loads it in SG1, SG2, SG3, SG1, etc..). I'm not sure how to go about this, if any one could help or give some guidance.. it'll be much appreciated!
Thanks
Asp For No Repeat Flash For Repeat Visitors?
Hi,
I have a flash animation that I want to execute in full only for first time visitors. I would like it to jump to the end of the animation for return visitors. I think this is easiest to do with an asp cookie by sending a parameter such as "recent_visit=yes" to the flash tag. However, I have no experience with cookies or vbscript. Any help is much appreciated!
Here's what's in my object tag ...
<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
codebase="http://active.macromedia.com/flash2/cabs/swflash.cab#version=4,0,0,0"
ID=blue_arrow
WIDTH=552
HEIGHT=70>
<PARAM NAME=movie VALUE="blue_arrow.swf?recent_visit=yes">
<PARAM NAME=quality VALUE=high>
<PARAM NAME=bgcolor VALUE=#FFFFFF>
<EMBED
src="blue_arrow.swf?recent_visit=yes"
quality=high
bgcolor=#FFFFFF
WIDTH=552
HEIGHT=70
TYPE="application/x-shockwave-flash"
PLUGINSPAGE="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash">
</EMBED></OBJECT>
Thanks!
Cheers,
Jeff
PLEASE HELP - URGENT Load Random Swfs From Individual Random Sets
I have two target mcs I would like to load different random swfs into
I have eight folders (a-h), each with 12 swfs (001-012)
I need to load a random swf (001-012) from a random folder (a-h) into the "card1" mc
I have figured out how to specify which one I want:
loadMovie("a/a001.swf","card1")
stop();
however, I need it randomized....
then, I need to load another random swf into my "card2" mc (001-012) from another random folder (a-h, ...except for the folder from which the first swf was loaded)
can somebody please help??????
Load Random Swfs From Two Differnet Random Sources
I am in the process of creating a VS Card game in Flash. It is basically a game where you can choose either one card or another, each randomly pulled from one of the eight different sets. The first card (or swf) can be pulled from any of the 8 sets (out of a total of 12 cards in each set))..and will load into a targetMC, and the second must be pulled randomly from any of the 8 sets except from the folder where the first card was chosen and load onto the second targetMC.
after the winning card is chosen, it will display winning animation (and send data off to a dynamic bargraph program), and then the main movie will reload two random cards from differnt sets.
can anybody help me on how to set this up??
Start Non-repeat And Then Repeat?
Hey, i would like to make an image fade into appearance and then after that do a repeat of some kind of animation...
In other words have a character appear on screen, and then have his eyes change from red to black in a repeat.
How would i accomplish this? .
Load A Flash Movie To A Random Frame Each Load
I have created a flash file that fades from one picture to the next. However, I would like to find an actionscipt that will allow the flash movie to load to different each time the page is visited/refreshed. That way visitors don't have to see the same image each time the visit the my page, but can still sit and watch all of them if they want. Also I would want to be able to specify which frames are available for load. That way the page will always load at the begining of each image animation... not right in the middle of it switching to the next image.
Any help is greatly appreciated!
Load A Flash Movie To Specified Random Frames Each Load
Group:
I am trying to find a Actionscript where I can specify random frames and have the movie randomly load to the specified frames each time the page is viewed. The below scrip was given last time I posted this question, but it doesn't seem to load at the specified frames. Sometimes it does, sometimes it load right in the middle of an animation. You can see in the code below I would like the movie to load at frames 1, 116, 231, 346. Any suggestions?
_____________________________________________________
Array.prototype.shuffle = function() {
for (var ivar = this.length-1; ivar>=0; ivar--) {
var p = random(ivar+1);
var t = this[ivar];
this[ivar] = this[p];
this[p] = t;
}
};
ASSetPropFlags(Array.prototype, ["shuffle"], 1, 1);
var Array_ar:Array = new Array(1, 116, 231, 346);
Array_ar.shuffle();
index = 0;
function load_random() {
gotoAndPlay(Array_ar[index++]);
if (index == Array_ar.length) {
(index=0);
}
}
load_random();
Load Random Mc.. Wait.. Then Load Following Mc
Last edited by [X]Silver : 2005-03-30 at 00:50.
Is this possible?
I'm doing a flash site, that loads a random movie at startup;
ActionScript Code:
filename = ["test_0.swf", "test_1.swf",
"test_2.swf", "test_3.swf", "test_4.swf"];
path = "mc/";
i = filename.length;
k = Math.floor(Math.random()*i);
loadMovie(path+filename[k], movieTarget);
Is it then possible to assign a linked movie to each of the randomly loaded movies, and have it load after a 4 second wait?
Page loads -> random movie -> 4 sec wait -> Random movie unloads and is replaced by the movie in same category (linked)
Does this make sense?
Hope someone can help me...
thanks
Random Load
I'm building my first all Flash site for myself.
The background is an image/.swf.
When someone hits the page, I want a unique and random image/.swf to pop into the background.
I've built the whole site off of an 'empy' base movie. Everything else loads into various layers or MCs of those layers.
My base image movie is layer 1. What would be the random script needed to have layer 1 rotate randomly through 5 or 6 different images/movies on load?
Any guidance, to tutorials or suggested scripting, would be greatly appreciated.
Thanks in advance.
Load Random SWF
I would like to randomly load a series of external images into my Flash file. Since Flash 5 does not support external linking to image files, I have to place images into a SWF movie, and then randomly load the external movies.
If anyone knows a script for this, or could tell me where to find it, I would appreciate it.
Thanks
Load Random Mc ( HELP PLEASE)
HI.....
I have exernal (mc.swf)
when i update it....
the old mc still in the cash ..
any action script code for it ?
I don't want meta html code... only action script!!
Thanks...
|