Flasher Archive
[Previous] [Next] - [Index] [Thread Index] - [Previous in Thread] [Next in Thread]
Subject: | FLASH: trouble with variables between movies (long) |
From: | Jay K |
Date: | Thu, 21 Sep 2000 01:09:41 +0100 |
I've got a confusing one here.....
I have a main interface movie that uses two separate other movies that need
to be kept in context of one another (a text movie and a graphics movie,
mainly controlled through the interface movie).
Set up like:
|-------------------------------------------------|
| interface movie swf |
| |----------------| |---------------------| |
| | text swf | | graphics swf | |
| |----------------| |---------------------| |
| |
| |
|-------------------------------------------------|
The each frame in the text movie has a default label reference associated
with it that the graphics movie should use. The text movie needs buttons
that should act as triggers to make the graphics movie go to a different
frame. A button in the text movie should behave as an on/off type, you click
it and it tells the graphics movie to switch from the "default" frame and
show the frame with the "other" label. (am I losing anybody yet ;-)
I've set it so that when a frame in the graphics movie is loaded, it tells
the main level to set a variable called imageFrame = "name of a frame
label". So, as the user steps through the text frames of the text movie by
using the main interface movie, the graphics movie shows whatever frame
contains that graphic associated with the text in the text movie. The
buttons in the text movie are over words to act as triggers (sort of like
html links but this is running stand alone and not in a browser so I can't
really use linked text - I think) and tell graphics movie to show a frame
with a graphic pertaining to the linked text.
So far it works properly but only once. Eg. I click through the text,
everything updates on screen as it should. I then click on the "linked" text
(via the invisible button over top of it), it switches the graphics movie to
the "other" frame, I click it again and the graphics movie switches back to
the "default" frame. Here's where the problem is, If I click a third time,
nothing happens. The graphics movie doesn't go to the "other" frame, it just
sits there.
>From the button in the text movie I have:
on (release) {
if (imageFrame =="other") {
tellTarget ("../image_window") {
gotoAndStop ("default");
imageFrame = "default";
}
}else{
tellTarget ("../image_window") {
gotoAndStop ("other");
imageFrame = "other";
}
}
}
>From the frame action in the graphics movie (when it enters the "other"
frame):
tellTarget ("../text_window") {
imageFrame = "other";
}
It appears as though there is a third condition that is not checked because
it seems as though both conditions are ignored on the third press so that
imageFrame doesn't equal "default" or "other".
Clear as mud, I know. I have this nagging feeling that there's a real easy
way to do this that I'm not aware of yet and that I've made everything over
complicated.
Any ideas?
Jay K
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
NudeGuru.com is proud to sponsor the Flasher list
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
IT'S THE ART OF MONEY, HONEY!
Tips and Advice from some of the most popular Flash
artists + industry power-brokers on how to hold onto
your rights, negotiate contracts and get full value
for your work.http://www.nudeguru.com from Franke James
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
To unsubscribe or change your list settings go to
http://www.chinwag.com/flasher or email helpchinwag [dot] com
Replies
FLASH: window controls, Carl Edwards
[Previous] [Next] - [Index] [Thread Index] - [Next in Thread] [Previous in Thread]