Negative custom font numbers in scorekeeping
Hi
I have followed Tshirtbooth's scorekeeping with custom font numbers and have got I working fine. My problem is that my game requires that it displays both positive and negative as a running total. Is this possible using this technique?
Thanks in advance
Chris
I have followed Tshirtbooth's scorekeeping with custom font numbers and have got I working fine. My problem is that my game requires that it displays both positive and negative as a running total. Is this possible using this technique?
Thanks in advance
Chris
Comments
If score < 0, change attribute self.color.alpha to 1
Otherwise, change attribute self.color.alpha to 0
That way, the minus sign would only show up when the score went below 0. This is assuming Tshirtbooth's scorekeeping with custom font numbers tutorial works on negative numbers like it does on positive numbers. I've never had to use negative scores in any of my games so I'm not sure if it does or not.
- Jeff
That sounds like a good idea to get a negative symbol to pop up. Unfortunately the problem is that if I have three digits ie 002 as a score, then if 3 is subtracted the score will goes to 999, so in this instance a negative symbol alone wouldn't work
Chris
Edit.... I am wrong ..... You will have to add a negative set of rule for display that invert the counting system I think... It's been long day....
Hope that sorts it. Kipper
Thanks
Chris
The simplest solution was posted above, just have a "-" image which is turned on when score < 0