AirsoftTimer software based on mbed
Dependencies: mbed TextLCD keypad
WaitForKeyObjective.cpp
00001 00002 #include "WaitForKeyObjective.h" 00003 #include "../games/Game.h" 00004 00005 WaitForKeyObjective::WaitForKeyObjective(Game* game) : Objective(game){ 00006 //keyboard->attach(this, &WaitForKeyObjective::buttonEvent); 00007 } 00008 00009 void WaitForKeyObjective::run(){ 00010 00011 00012 //wait until completed 00013 while(getStatus() != COMPLETED){} 00014 } 00015 00016 void WaitForKeyObjective::buttonEvent(char c){ 00017 // complete objective if a button is pressed 00018 complete(); 00019 }
Generated on Tue Jul 12 2022 21:04:09 by 1.7.2