Help…
I have lost enough hair over this site to make a replica chia pet of myself.
In a scene I have 8 MC’s each MC has a stop() on frame one and frame ten.
on click the MC plays till frame ten ( moving into the scene ) then waits for
another click to return to its original location.
Here is a visual,
[CENTER]
[/CENTER]
Right now I am using this script.
import flash.display.MovieClip;
import flash.events.MouseEvent;
sign1movie.addEventListener(MouseEvent.CLICK, onClickHandler11);
sign1movie.buttonMode = true;
sign1movie.useHandCursor = true;
sign1button.addEventListener(MouseEvent.CLICK, onClickHandler11);
sign1button.buttonMode = true;
sign1button.useHandCursor = true;
function onClickHandler11(myEvent:MouseEvent){
sign1movie.play();
}
it’s pretty simple I have hit points (sign1button) due to the overlapping of images,
Problem is I need to have the MC play so that only one MC is on the stage at a time,
right now they over lap in their respective layer.
I tried… and failed…
var signstate:String = "empty";
import flash.display.MovieClip;
import flash.events.MouseEvent;
sign1movie.addEventListener(MouseEvent.CLICK, onClickHandler11);
sign1movie.buttonMode = true;
sign1movie.useHandCursor = true;
sign1button.addEventListener(MouseEvent.CLICK, onClickHandler11);
sign1button.buttonMode = true;
sign1button.useHandCursor = true;
function onClickHandler11(myEvent:MouseEvent){
if (signstate==empty) {
sign1movie.play();
}
else {
signstate.play() //I want it to goto and play which mc changed the variable.
}
and in the MC (sign1movie) @ frame ten I have
stop()
var signstate:String = "sign1movie";
But all I get is errors, is their a simpler way? what am I doing wrong.
I know signstate.play() won’t work. I wish it did…
When I set all my Mc’s to have
var signstate:String = “sign1movie”; // in sign1movie
var signstate:String = “sign2movie”; // in sign2movie
var signstate:String = “sign3movie”; // in sign3movie
flash freaks out or can’t find the variable, is this because it’s in a movie clip?
I worked so hard on all the other AS3 coding for the site but this seems soo simple
I just can’t figure it out…
Any help would be greatly appreciated.