PDA

View Full Version : random loading problem plz help



sundeep_02tv26
02-08-2007, 06:51 AM
hai to all

i did 5 swf's and one main movie. i had loaded the small swf's into main movie. everthing is right and loading.

what i want is -> assume no 4th swf is loaded in main swf again when random the same 4th one should not load which is the previously loaded. it should again do ranod and load the corresponding swf

here is the code which i did here it is again loading the previous one plz help
var x:Number = random(5);
swf = "swf/" add "main" add x add ".swf";
_roothold_mc.loadMovie(swf, 1);
var secs = 3;
var id = setInterval(function () {
clearInterval(id);
play();
}, secs*1000);
stop();

BLiZZaRD
02-08-2007, 01:23 PM
var x:Number = random(5);
swf = "swf/" + "main" + x + ".swf";
_root.hold_mc.loadMovie(swf, 1);
var secs:Number = 3;
var id = setInterval(function () {
clearInterval(id);
play();
}, secs*1000);
stop();

Untested, just correcting some mistakes, still not sure this will work. I don't quite understand exactly what you are trying to do... :confused: