Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Please help! 2 problems... 1

Status
Not open for further replies.

gromitboy

Technical User
Jun 13, 2002
3
GB
Hi...I'm an experienced flash user who has just discovered the wonders of director...but I've run into a couple of problems that are driving me crazy!

1. I have a flash button in my cast...unfortunately the button tweens in a circular motion so the swf covers most of the stage in director (I wanted just to recreate the circular motion in director, but the process is way too laborious and time consuming so I opted for a flash tween) I want to code it in director so that when you rollover the button at any point in its circular path it triggers something else to happen somewhere else on the stage. The problem I'm having is that to get director to recognise the flash button which is tweening I have to use the "Set Click Modes" behaviour. This works perfectly for a mouse click action...but there does not appear to be a mouseover option anywhere that I can use. Do I have to write this in lingo? If so can anyone out there point me in the right direction please?

2. Secondly, and I think that this MUST be easier...I have a flash intro that I wish to play to its full, stop at the end and then move onto my menu. How do I get the flash intro to play in full and then carry on? Surely I don't have to fill my score with the correct amount of frames for the intro to play itself out?

Please help if you can...I'm really enjoying getting to grips with director...its just the little things like this that put me off.

Thanks.
 
Answer for#1:
Yes, you need to write this handler in a script of a bhavoir you put on your flash button:

on beginSprite me
set the clickMode of sprite (1)= #object
end if

This set the clickMode for the sprite to the flash object itself. If the background is not fill it treats that as not being part of the object.

Answer for #2:
Use this code for the frame script where your flash intro plays:

on exitFrame me
if sprite(1).frame<sprite(1).member.FrameCount then play the frame
end if
end

This is where sprite 1 is your flash swf. It should play the flash intro until its end and then go to the next frame.
 
Thankyou!

That was incredibly helpful and solved both problems completely! I really appreciate your help with it.

Just as a final question though...I noticed that (referring to your solution to my 2nd question) when the flash intro reaches its end and your script directs the score to play on, there is a tiny pause...is there anyway of eliminating this so it is seamless?

Thanks again.
 
I never noticed a tiny pause when I implemented that script with a flash intro. So I do not know of any specific solution to that tiny pause that you mention. You could try preloading all of the casts in the main menu frame. Maybe by the time the flash intro finishes the main menu is loaded, ready to go, and there is no pause.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top