3 Replies Latest reply on Sep 11, 2010 10:10 AM by kglad

    Not a Number


      When the enemy reaches the player, the health should go down, but it says NaN(Not a Number).


      The instance name of the Health text is Life, it's dynamic text and the variable is Health.


      Frame 1(Menu):

      Health = 0


      Frame 2(Level):

      Life.text = "Health: " + Health;


      if (this.hitTest(_root.enemy))
        _root.Health -= 1;