-
I am trying to play a different frame in a target depending on what pic is already loaded.
on (press) {
if (_level0.back.backpic1._visible) {
tellTarget ("back") {
gotoAndPlay (7);
if (_level0.back.backpic2._visible) {
tellTarget ("back") {
gotoAndPlay (18);
}
}
}
}
}
Can anyone see what I am doing wrong here. I put the path "(_level0.back" after looking at the movie in movie explorer figuring that might help me.
-
Looks like your second if-statement is located inside the tell-target statement. Try this:
on (press) {
if (_level0.back.backpic1._visible) {
tellTarget ("back") {
gotoAndPlay (7);
}
}
if (_level0.back.backpic2._visible) {
tellTarget ("back") {
gotoAndPlay (18);
}
}
}
Think this should work,
HC
-
re
(_level0.back.backpic1._visible) is giving me trouble when i specify the movieclip "back" the the script works. I don't think it can tell if backpic1 (which is an instance graphic is visible ??????? needless to say it doesn't work but thankyou for your speedy reply!!
-
The _visible property only applies to movieclips, if you want to check this you need to make your graphic a movieclip instance, and make sure the instance is named 'backpic1'. Then your script should work.
regards,
HC
-
movie clip instance
It did work however, for some reason when i debug i see _level0.back.instance2 instead of _level0.back.backpic1
I am not sure why it is not showing the name of the movie clip I did specify it on the toolbar under instance.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|