Yes i used the search feature and found a topic for it, but the link they said the help was on, did not work…
How can i create random pictures?
Yes i used the search feature and found a topic for it, but the link they said the help was on, did not work…
How can i create random pictures?
SBV -
by “random pictures” do you mean displaying a random image or creating a random composition out of various movie clips?
let me know and i’ll help you out.
Displaying a random image.
Well i think there is a way to do this using arrays, but i dont’ know how…so an idea would be to create a random number and a picture loads up depending on the number…
damm i wanted to see how to do it too but hte second page link don’t work :-\
just make sure that all your pics are in MCs. delete all the pics off the main timeline and hit F11. right click each MC and hit linkage. you should see some check boxes. hit export for actionscript and name each MC the same except for a different number at the end ie: pic1, pic2 etc… make sure the numbers are consecutive. then in the main timeline put
[AS]numPics = 5 //the number of the last pic ie pic5
picIndex = Math.floor(Math.random() *numPics)
_root.attachMovie(“pic” + picIndex, “whatEverYouWantTheNewPicNamed”,100/the new depth/ )
_root[“whatEverYouWantTheNewPicNamed”]._x = 200 //where ever you want the new pic to be placed…
_root[“whatEverYouWantTheNewPicNamed”]._y = 234
[/AS]
that should work… haven’t tested it though
zylum, excuse me I’m still learning (with quite a bit of hewlp from this place, actually:thumb: )…
The AS above implies an x and y position of the images to be 200 and 234, right ? That can be changed for any project, right?
Thanks!
Mars
edit: read the comments, Mars…:trout:
yes it should planet
:: Copyright KIRUPA 2024 //--