Adding & Subtracting Variables
I tried to create a calorie meter : http://crisptalks.com/story_html5.html
Here are few problems that I am facing:
- The variable "cal" is increasing its value even if I am moving the item inside the hotspot. For ex: if the burger is inside hotspot and value of cal is 200 then if I am moving the burger inside the hotspot then again it is adding the value 200 to the variable "cal".
- I am not able to subtract the variable "cal" when I am dropping incorrect or bringing it back to its usual place.