21 Replies Latest reply on Nov 17, 2012 3:20 PM by lcg_2012

    Syntax to keep adding 1 to a Variable

    lcg_2012 Level 1

      This is driving me nuts. I am trying to add 1 to my variable everytime it is moused over. I had the syntax correct at one point, but now I cannot for the life of me get it right.


      So on frame 0 of my animation I have:


      sym.setVariable("myVar", 0);//Sets Variable myVar to 0


      On my mouseOver I am trying to get that value to be a ++ but my syntax is off.


      I have tried this:

      sym.setVariable("myVar" ++);//Adds 1 to the value of Variable myVar


      Doesn't seem to work. I've tried it with a comma without quotes you name it. Wish I could find some documentation beyond this page for syntax: