Version of Robotron arcade game using LPC1768, a Gameduino shield, a serial EEPROM (for high scores), two microswitch joysticks and two buttons plus a box to put it in. 20 levels of mayhem.
Dependencies: 25LCxxx_SPI CommonTypes Gameduino mbed
CharFrame.h@18:70190f956a24, 2013-06-17 (annotated)
- Committer:
- RichardE
- Date:
- Mon Jun 17 15:10:43 2013 +0000
- Revision:
- 18:70190f956a24
- Parent:
- 16:d0b142ba4362
Improved response to button 1 when entering high scores (HighScoreEntry.cpp).
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
RichardE | 2:bb0f631a6068 | 1 | /* |
RichardE | 2:bb0f631a6068 | 2 | * SOURCE FILE : CharFrame.h |
RichardE | 2:bb0f631a6068 | 3 | * |
RichardE | 2:bb0f631a6068 | 4 | * For drawing rectangular frames using characters. |
RichardE | 2:bb0f631a6068 | 5 | * |
RichardE | 2:bb0f631a6068 | 6 | */ |
RichardE | 2:bb0f631a6068 | 7 | |
RichardE | 2:bb0f631a6068 | 8 | #ifndef CharFrameIncluded |
RichardE | 2:bb0f631a6068 | 9 | |
RichardE | 2:bb0f631a6068 | 10 | #define CharFrameIncluded |
RichardE | 2:bb0f631a6068 | 11 | |
RichardE | 2:bb0f631a6068 | 12 | #include "Types.h" // various types |
RichardE | 2:bb0f631a6068 | 13 | #include "Gameduino.h" // Gameduino stuff |
RichardE | 2:bb0f631a6068 | 14 | |
RichardE | 2:bb0f631a6068 | 15 | class CharFrame { |
RichardE | 2:bb0f631a6068 | 16 | |
RichardE | 2:bb0f631a6068 | 17 | public : |
RichardE | 2:bb0f631a6068 | 18 | |
RichardE | 2:bb0f631a6068 | 19 | /****************/ |
RichardE | 2:bb0f631a6068 | 20 | /* DRAW A FRAME */ |
RichardE | 2:bb0f631a6068 | 21 | /****************/ |
RichardE | 2:bb0f631a6068 | 22 | // Pass Gameduino to draw on in gd. |
RichardE | 2:bb0f631a6068 | 23 | // Pass x coordinate of top left in x. |
RichardE | 2:bb0f631a6068 | 24 | // Pass y coordinate of top left in y. |
RichardE | 2:bb0f631a6068 | 25 | // Pass width in w. |
RichardE | 2:bb0f631a6068 | 26 | // Pass height in h. |
RichardE | 2:bb0f631a6068 | 27 | static void Draw( Gameduino *gd, UInt8 x, UInt8 y, UInt8 w, UInt8 h ); |
RichardE | 2:bb0f631a6068 | 28 | |
RichardE | 16:d0b142ba4362 | 29 | /****************/ |
RichardE | 16:d0b142ba4362 | 30 | /* WIPE A FRAME */ |
RichardE | 16:d0b142ba4362 | 31 | /****************/ |
RichardE | 16:d0b142ba4362 | 32 | // Pass Gameduino to draw on in gd. |
RichardE | 16:d0b142ba4362 | 33 | // Pass x coordinate of top left in x. |
RichardE | 16:d0b142ba4362 | 34 | // Pass y coordinate of top left in y. |
RichardE | 16:d0b142ba4362 | 35 | // Pass width in w. |
RichardE | 16:d0b142ba4362 | 36 | // Pass height in h. |
RichardE | 16:d0b142ba4362 | 37 | static void Wipe( Gameduino *gd, UInt8 x, UInt8 y, UInt8 w, UInt8 h ); |
RichardE | 16:d0b142ba4362 | 38 | |
RichardE | 2:bb0f631a6068 | 39 | }; |
RichardE | 2:bb0f631a6068 | 40 | |
RichardE | 2:bb0f631a6068 | 41 | #endif |
RichardE | 2:bb0f631a6068 | 42 | |
RichardE | 2:bb0f631a6068 | 43 | /* END of CharFrame.h */ |
RichardE | 2:bb0f631a6068 | 44 |