Error 1151
I am using as3 on flash cs6 and I have been trying to create a scene where the button to move onto the next scene is only available when all other interactivies have been clicked at least once. This is my coding that I am using:
backyard_door.visible = false;
var btnB:Array = ["door_1","door_2","door_3","f_book","on_light"];
for (var i:uint=0; i<btnB.length; i++)
{
getChildByName(btnB).addEventListener(MouseEvent.CLICK,g);
}
function g(e:MouseEvent)
{
n = Math.max(n,n ^ (1 << (1 + btnA.indexOf(e.currentTarget.name))));
if (n==Math.pow(2,btnB.length+1)-2)
{
backyard_door.visible = true;
}
}
Error 1151 says that in this line :
for (var i:uint=0; i<btnB.length; i++)
that 'A conflict exsists with definition i in namespace internal'
can someone please suggest a way to solve this problem or link me to a source that may be able to help? Thankyou
Also I am an as3 newbie so please be gentle with me ![]()
