answer = new Array();
answer[0] = "1997";
answer[1] = "1941";
question = new Array();
question[0] = "What ...?";
question[1] = "Why ...?";
question_txt.text = question;
enter1.onRelease = function()
{
if (answer_input.text == answer)
{
answer++;
question++;
question_txt.text = question;
}
else
{
answer_input.text = "Incorrect";
}
};
有 2 个文本框和一个按钮 TextBox1 = question_txt - 用于显示问题,类型为[Dynamic]
textBox2 = answer_input - 允许用户尝试回答问题
答案和问题的价值只是虚构的,不要介意。
那么为什么它不起作用呢?