I have a game that I'm working on and it sometimes acts screwy. It works 90% of the time but I would like it better if it worked all of the time. It's a question/answer game. There is a movie clip that contains the questions. Frame 1 is nothing more than a "stop" frameand the other 29 frames are the questions. The following is the code used to set the questions and tell Flash what the answer should be:
Stop
Set Variable: "/:Answer" = 1
Set Variable: "/:AnswerA" = "Rabbit"
Set Variable: "/:AnswerB" = "Dog"
Set Variable: "/:AnswerC" = "Goat"
Set Variable: "/:AnswerD" = "Elephant"
Set Variable: "/:Screen" = "What animal's foot is said to be a good luck charm?"
The variables "AnswerA" - "AnswerD" are nothing more than text variables that sit on top of the buttons to give 4 possible answers. If variable "Answer" is set to 1, the right answer will be "AnswerA". If "Answer is set to 2, the right answer will be "AnswerB" and so on.
On the main stage, there are commands that tell the movie clip to go to the frames with the question. Here is the code used:
Set Variable: "Pickframe" = Random (29)+2
Begin Tell Target ("/Q1")
Go to and Stop (/:Pickframe)
End Tell Target
The problem is that sometimes the variable "Pickframe" will be set but nothing ever appears from the movie clip. I've set up a text variable to display "Pickframe and a number does appear there but it's like it misses the Tell Target command completely. Like I said, it works most of the time, it's just every now and then it will blank out like that for seemingly no reason. If anyone knows why this might be occuring your input will be much appreciated.
Thanks in advance,
Bookmarks