Markus Watko
/
GoToBeeper2
GoToBeeper
Fork of GoToBeeper by
Revision 1:0f309ef92d1e, committed 2015-04-23
- Comitter:
- Markus_Watko
- Date:
- Thu Apr 23 12:29:16 2015 +0000
- Parent:
- 0:6e9ea56b10d9
- Commit message:
- GoToBeeper;
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
diff -r 6e9ea56b10d9 -r 0f309ef92d1e main.cpp --- a/main.cpp Thu Apr 23 12:03:31 2015 +0000 +++ b/main.cpp Thu Apr 23 12:29:16 2015 +0000 @@ -6,31 +6,18 @@ { ur_Bertl karel; - /* if(!karel.NextToABeeper()) - { - karel.Move(); - } - - if(!karel.NextToABeeper()) - { - karel.Move(); - } - - if(!karel.NextToABeeper()) + + for(int i = 0; i > 5; i++) { - karel.Move(); - } - - karel.PickBeeper(); - */ - - while(!karel.NextToABeeper()) - { - karel.Move(); - } - - if(karel.NextToABeeper()) - { - karel.PickBeeper(); + while(!karel.NextToABeeper()) + { + karel.Move(); + } + + if(karel.NextToABeeper()) + { + karel.PickBeeper(); + karel.NibbleLeds(karel.AnyBeeperInBag()); + } } } \ No newline at end of file