word guessing game Flash Develop as3
I am coding a word guessing game for primary level age 5/6. They have to guess a five letter word by looking at the image. I want to provide a clue button, which when clicked will give the user one correct letter. There are five words contained in an array. I want to give one letter as a clue. Here is my current code (not completed). If anyone has any ideas, they would be greatly appreciated as havn't done this before!!
}
public function clue(event:MouseEvent):void {
for (var i : uint = 0; i < 5; i++)
{
if (this["text" + i].text != currentWord.charAt(i))
{
//changing colour to red
trace ("checking if equal");
this ["button" + i] = setImage("../images/red2.png", 405 + (40 * i), 600);
this["button" + i].visible = true;
//need to give the user one correct letter
["Text"+i] == currentWord.charAt(i)
}
