Skip to main content
Participant
June 8, 2024
Question

Scene 1, Layer 'actionscript', Frame 1, Line 19, Column 6 1120: Access of undefined property counter

  • June 8, 2024
  • 1 reply
  • 211 views
All my codes works except for 1 for actioscript 3 in animate. i get an error Scene 1, Layer 'actionscript', Frame 1, Line 19, Column 6 1120: Access of undefined property counter. I am not too sure what to replac counter with. Here is my code
 
import flash.utils.Timer;
import flash.events.TimerEvent;
import fl.transitions.Tween;
import fl.transitions.easing.*;
 
mc1.alpha = 0;
mc2.alpha = 0;
mc3.alpha = 0;
 
 
var timer:Timer = new Timer(500,27);
timer.addEventListener(TimerEvent.TIMER,timerListener);
timer.start();
 
function timerListener(event:TimerEvent):void
{
if(timer.currentCount == 1)
{
if(counter==1)
{
var tween6:Tween = new Tween(mc3,"alhpa",Strong.easeOut,1,0,1,true);
}
var tween1:Tween = new Tween(mc1,"alpha",Strong.easeOut,0,1,2,true);
}
 
if(timer.currentCount ==10)
{
var tween2:Tween = new Tween(mc1,"alpha",Strong.easeOut,1,0,1,true);
var tween3:Tween = new Tween(mc2,"alpha",Strong.easeOut,0,1,2,true);
}
 
if(timer.currentCount == 19)
{
var tween4:Tween = new Tween(mc2,"alpha",Strong.easeOut,1,0,1,true);
var tween5:Tween = new Tween(mc3,"alpha",Strong.easeOut,0,1,2,true);
}
 
if(timer.currentCount == 27)
{
timer.reset();
timer.start();
var count = 1;
}
}
    This topic has been closed for replies.

    1 reply

    kglad
    Community Expert
    Community Expert
    June 8, 2024

    what's counter?

    GeorgeousAuthor
    Participant
    June 9, 2024

    I've bben following a tutorial and the tutorial shows counter

    kglad
    Community Expert
    Community Expert
    June 9, 2024

    is there an instance of "counter" on the stage?