mallgi01
12-06-2005, 04:54 AM
Hello everyone,
I have a attached a file with this post that contains the problem that I would like to address. Consider the following code:
for (i=0; i<5; i++) {
_root["rock"+i+"_mc"+row].input_txt.selectable = false;
_root["rock"+i+"_mc"+row].rock_mc._visible = true;
_root["rock"+i+"_mc"+row].rock_mc.gotoAndStop(8);
//addition
_root["rock"+i+"_mc"+row].rock_mc.onPress = function () {
_root["rock"+i+"_mc"+row].rock_mc.gotoAndStop(4);
}();
}
The problem is such that, I want to be able to click on the little rocks that appear at the top left corner of each box when th done button is pressed first. (These rocks are the part of the "square" movie clip and are named rock_mc. Here I have duplicated the squares at runtime. ) But the movie clip is not responding to my onPress command as I have shown above. I am really confused why this is not working. Can someone help me?
many thanks,
m
I have included my file with this post. Please refer to it if necessary.
I have a attached a file with this post that contains the problem that I would like to address. Consider the following code:
for (i=0; i<5; i++) {
_root["rock"+i+"_mc"+row].input_txt.selectable = false;
_root["rock"+i+"_mc"+row].rock_mc._visible = true;
_root["rock"+i+"_mc"+row].rock_mc.gotoAndStop(8);
//addition
_root["rock"+i+"_mc"+row].rock_mc.onPress = function () {
_root["rock"+i+"_mc"+row].rock_mc.gotoAndStop(4);
}();
}
The problem is such that, I want to be able to click on the little rocks that appear at the top left corner of each box when th done button is pressed first. (These rocks are the part of the "square" movie clip and are named rock_mc. Here I have duplicated the squares at runtime. ) But the movie clip is not responding to my onPress command as I have shown above. I am really confused why this is not working. Can someone help me?
many thanks,
m
I have included my file with this post. Please refer to it if necessary.