Html5 canvas variable in different frames
My question is regarding actionscript/javascript in an adobe animate canvas/html5 project.
I have the following code:
Main timeline, Frame 0:
var tempArray = [1,2,3,4,5];
alert(tempArray[2]); // alert shows 3
Main timeline, Frame 50:
tempArray[2] = 3;
alert(tempArray[2]); // alert is ignored and doesnt print anything
WHY?
