Hello,
I had a function that was working fine...then I tried the next step of adding an interval...now I am getting undefined from my target.
Is there a way to trace for the data type so I can see if it is passing a number or a string?
Here is the code...
Not sure why my target is now showing up as undefined.
"Credit belongs to the man who is actually in the arena - T.Roosevelt
I had a function that was working fine...then I tried the next step of adding an interval...now I am getting undefined from my target.
Is there a way to trace for the data type so I can see if it is passing a number or a string?
Here is the code...
Code:
function revealNotes (min, max){
var number:Number = max;
if (number == 8){
var target = this.onStage.allNotesOnStage.easyArray
var randomNum:Number = Math.floor(Math.random() * (max - min + 1)) + min;
var showNote = target[randomNum];
trace (target)
if (showNote._visible == false){
showNote._visible = true;
}
}
}
Code:
btnEasy.onRelease = function(){
this._parent.myInterval = setInterval(revealNotes,1000,0,8);
}
Not sure why my target is now showing up as undefined.
"Credit belongs to the man who is actually in the arena - T.Roosevelt