Faizan and Pages fun little game
Dependencies: 4DGL-uLCD-SE mbed SDFileSystem wave_player
Diff: stack.cpp
- Revision:
- 4:c00da0b158c4
- Parent:
- 3:058e10b8ecf6
- Child:
- 7:7cbff8cf583b
- Child:
- 8:b2df3588d8e0
diff -r 058e10b8ecf6 -r c00da0b158c4 stack.cpp --- a/stack.cpp Mon Oct 31 02:53:59 2016 +0000 +++ b/stack.cpp Mon Oct 31 02:58:10 2016 +0000 @@ -14,7 +14,7 @@ #define BADTOMATO 7 #define MAX(i) std::max(i,0) -#define MIN(i) std::min(i,128) +#define MIN(i) std::min(i,107) Stack::Stack(int location, uLCD_4DGL * uLCD) { @@ -27,8 +27,10 @@ void Stack::move(int dx) { // constrain + erase(); if (dx < 0) x = MAX(x + dx); else x = MIN(x + dx); + draw(); } int Stack::size() {