...

View Full Version : Image swapping



cyrus709
04-15-2009, 10:11 PM
I am trying to make an image that when you click in a specific spot of it, it changes the image.
An example would be i have a brown image, and when you click on it the image turns into another image, such as a green image, then it keeps going until the last one you cant click on it, and it says "the end".

Right now my thought is that i should use a button? I made it so that you can click in a specific spot (say the middle) and it changes the image, but when i let the mouse button up, the image returns to how it was. I want the image to take the place, or to be a new image where i can continue clicking? does this make since?
Im new to flash and action script, and am used to php. If anyone could help me i would appreciate it. or at least lead me in the right direction? I have flash cs4

cyrus709
04-16-2009, 11:05 PM
Sorry but im 100% new to Flash, the scripting i could get by with, its learning how to use flash that im still grasping.

This is exactly what im trying to do. http://www.albinoblacksheep.com/flash/basicinteractive, They have it so that you can click on a button ( or a link) and it continues to another page? That is what i would like to be able to do! IF anyone could help me, or even redirect me i would be very great full.

All i need is for it to go from one page to the next, like where in that tutorial where you hit the link, or triangular button

gnomeontherun
04-19-2009, 08:39 PM
Well there are different techniques, and I really only know the Actionscript 2 versions well enough. However you may consider version 3 if you are going to do serious flash work.

So I would suggest that you take a look at this for one method.

http://www.kirupa.com/developer/mx2004/jump_frames.htm

Another method would be to swap the source of the image itself, rather than just moving frames. This is preferred when you want other elements on the stage to stay put.

You would need to use the mouse event handlers to detect a mouse click, and then use the loader to change the source of the movieClip. Many of these elements are covered here.

http://www.kirupa.com/developer/mx2004/xml_slideshow.htm



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum