Need help with my actionscript 2.0 script its working but var is messed
//so guys this is my script what happens is everything works fine and all but when i collect the object my bar goes up, ie first coin i collect bar goes to 1 then the second coin i collect, it goes to 11, then 111 and soforth. my question is.. how can i make it go from 1 2 3 4 5 ect
onClipEvent(enterFrame) {
if(_root.char.hitTest(this)) {
_root.money =1
unloadMovie(this);
}
}
Related posts:
- Working Towards a Future Without Breast Cancer Working Towards a Future Without Breast Cancer Chances are someone close to you such as your friend, mother, wife, sister or even yourself has been touched by breast cancer in...
I don’t program using this language but I think what you’re looking for is instead of making "_root.money" equals to "1", you suppose to increments by 1.
Example (using a different language);
$money = 1
$money = $money + 1
Try this:
onClipEvent(enterFrame) {
if(_root.char.hitTest(this)) {
_root.money +=1
unloadMovie(this);
}
}