Jump to content
Search Community

fades

litterach test
Moderator Tag

Recommended Posts

Hi

 

I searched the forums but couldn't find quite what I was looking for; however, I may have missed it!

I'm very new to ActionScript, and found TweenLite. Looks absolutely awesome. I've downloaded it, but not sure if it could help me with what I want to do. I've attached a demo fla file so you can see what I mean.. here it goes:

 

I have made a horizontal navigation bar that contains several menu items. One of them is labeled "cakes". When the mouse hovers over "cakes" a submenu pops up that contains several buttons such as "raspberry" "peach" and "cherry". Can TweenLite help me to make the appearance of the submenu a little more graceful? I would like the flavors submenu to fade in when one hovers over "cakes". Then the submenu stays visible as you are either on "cakes" or on one of the submenu buttons. When one moves the mouse off either "cakes" "raspberry" "peach" or "cherry", I would like the submenu to fade gracefully away into alpha 0 land. I've tried doing this without TweenLite and not quite sure how to tell AS that a certain event (fade) will happen to object B (submenu) when another event (hover) happens to object A (frame around "cake" and cake's submenus)

 

Can anyone help out this new kid on the block?

 

Thanks!

Link to comment
Share on other sites

i could not open your file as it is saved as Flash CS5.5

 

To answer your question, yes TweenLite would be phenomenal at enhancing something like this.

 

There is a fair amount of ActionScript code and concepts that you will need to know before getting it to work properly.

 

For a project like this 90% of what you need is basic flash and actionscript. the remaining 10% would be very basic TweenLite to "make it look nice".

 

You will get the most value out of the forums if you post something that has shown that you made some effort with TweenLite and you need a little extra help implementing it properly.

 

It would be a bit much for someone here to walk you through all the basic mechanics of ActionScript to get your menu buttons to communicate effectively with each other.

 

Perhaps once you post an earlier version of your file the solution may not be so elaborate.

 

this might help as well:

http://www.tutvid.com/tutorials/flash/t ... nMenus.php

Link to comment
Share on other sites

Hi There,

 

Thanks for your post.

 

Believe it or not, I have watched that tutvid tutorial and have used it and some others to build the "cake" example nav bar I attached... I'm going to reattach it is as both a cs5 and cs4 file. I'm also going to mess around with Tweenlite or TweenMax right after I write this.

 

I guess my question could be summarized in this: can you direct me to a forum or example where tweens are used in an event listener?

 

Thanks so much for bearing with me.

 

Rach

Link to comment
Share on other sites

Hi Carl...

 

If you are around, I have one quick question!

 

In the attached file, when I hover over the submenu items, they fade away. I would like them to be able to stay when they themselves are hovered over. I know this is an actionscript thang, and I don't mean to bug you with this type of question... but I figured I'd ask!

 

Thanks so much,

 

Rachel

Link to comment
Share on other sites

the reason your menu is disappearing is because when you ROLL_OVER sub (which is on a layer on top of projects frame) you are technically doing a ROLL_OUT of projectsframe. projectsframe ROLL_OUT tells sub to set its alpha to 0.

 

drop down menus are much easier to activate with a click.

when you activate them on rollover, chances are you are going to rollout of the thing you were previously over i order to get to the sub menu. furthermore if your submenu buttons have rollover effects you wind up with lots of "buttons in buttons" and a bunch of different events fighting with each other.

 

in short they never have been easy to do in flash. back in the old'n days people would do all sorts of whacky things like put an invisible button around or behind the sub-menu so that when you rolled off the sub menu and on to this invisible button it would close the menu. yeah its confusing.

 

I really don't have the time to fix your file. but i provided an example of a menu that opens and closes nicely when it should.

The way it works may not be the easiest thing to figure out.

 

http://www.snorkl.tv/dev/dropdown/dropdown.html (source attached)

 

Carl

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...