Action Script 3.0
I have a very Stupid Question,
how can i get 2 digit number
here is my code-
stop();
var total:int = 00;
totaltext.text = total.toString();
opt01.addEventListener(MouseEvent.CLICK, fl_MouseClickHandler);
function fl_MouseClickHandler(event:MouseEvent):void
{
total = total +10;
totaltext.text=total.toString();
opt01.removeEventListener(MouseEvent.CLICK, fl_MouseClickHandler);
}
opt0203.addEventListener(MouseEvent.CLICK, fl_MouseClickHandler_2);
function fl_MouseClickHandler_2(event:MouseEvent):void
{
total = total +10;
totaltext.text=total.toString();
opt0203.removeEventListener(MouseEvent.CLICK, fl_MouseClickHandler_2);
}
next.addEventListener(MouseEvent.CLICK, fl_MouseClickHandler_3);
function fl_MouseClickHandler_3(event:MouseEvent):void
{
if(total == 20)
{
gotoAndStop(2);
}
else
{
trace("RETRY")
}
}
