PDA

View Full Version : A problem with links.


Pingvin
12-11-2002, 06:00 AM
Hello,

My name is Antti Karttunen, this is the first time I write here.. :D
I've started to make my first Flash animation. You can take a look at it here: http://193.166.93.108/airplane/pd6.html. What I want to do, is when I put my mouse on the text-links near the airplane, a part of the plane changes colour. For example, if I put the cursor on TUOTTEET, the engines should go red. The layers wich contain the coloured parts of the plane were easy to make... But what I didn't get to work, is the changing of the colors.. I've tried to do it with on(rollover/rollout) and swapDepths, but I just can't get it working.. If I didn't have the animated background, I could just jump to the frame, where the coloured part is.. But not in this case. Please help me :confused:

Antti Karttunen

farafiro
12-11-2002, 06:20 AM
Antti Karttunen, welcome here
this should be easey to tell but u should do sme more tuts for getting the idea of how h=doing such a things//first I will guide you to the engine color
// we should make the enging a movieclip, and give it a name of
//"enginMc" so we can call it
//now code for the TUOTTEET button
on(rollOver){
//instaniating a new color
engineColor = new Color(enginMc)
enginolor.setRGB(0x336699)
}
on(rollOut){
enginolor.setRGB(0xFF0000)
}

Pingvin
12-11-2002, 06:32 AM
I forgot to say in my last post, the plane is a picture from photoshop, and the color is on a diffirent layer, covering the engines, as a partly transparet layer. How can I swap the layers, airplane and engines? There are also coloured layers for the cocpit and passengers, all on diffirent layers. I succeeded in swapping one layer to another, but when I have four different layers, I didn't get it to work.

Antti Karttunen

farafiro
12-11-2002, 06:50 AM
u can make the color over the plane and invisivle, when u rollOver, it becomes visible

Pingvin
12-11-2002, 07:12 AM
Thanks for your help!

Got it workíng, after studying more tutorials.. It was this easy:

on (rollOver) {
_root.engines._visible=true;
}
on (rollOut) {
_root.engines._visible=false;
}

I love Flash!

Antti Karttunen

farafiro
12-11-2002, 07:18 AM
Glad to here so