A retro gaming programme, designed for use on a portable embedded system. Incorporates power saving techniques.
Dependencies: ConfigFile N5110 PowerControl beep mbed
Diff: tower.h
- Revision:
- 37:eda13afa2923
- Parent:
- 36:b02b7935475a
- Child:
- 38:2006c99bb1fc
--- a/tower.h Tue Apr 21 21:32:27 2015 +0000 +++ b/tower.h Tue Apr 21 21:45:09 2015 +0000 @@ -897,10 +897,9 @@ } //if any of the high scores are beaten, they are replaced. -//player enters initials using struct +//player enters initials using structs outputs void newScore() { - char x,y,z; if(score >= highScore3) {//entry condition buttonFlagA = 0;//reset flags buttonFlagB = 0; @@ -911,6 +910,15 @@ int n;//local variable used for storing temporary global variable int initial = 0;//used for isolating which initial is being selected + char x,y,z; + + //print initial characters + x=fsm[state1].output1; + lcd.printChar(x,25,26); + y=fsm[state2].output2; + lcd.printChar(y,37,26); + z=fsm[state3].output3; + lcd.printChar(z,49,26); while(1) { @@ -1060,9 +1068,6 @@ a8 = a8+=2; ninjaBoundaries(); } - - /////////////////////readWrite(); - if (joystick.direction == CENTRE) serial.printf(" CENTRE\n"); if (joystick.direction == UNKNOWN)