Doxygen comments added
Dependencies: mbed Gamepad N5110
Pipes/Pipes.cpp
- Committer:
- rafeh
- Date:
- 2019-05-06
- Revision:
- 7:05f433e196d6
- Parent:
- 6:bc580b480ac8
- Child:
- 10:75de0f4da176
File content as of revision 7:05f433e196d6:
#include "Pipes.h" void Pipes::init(int x, int height) { _x = x; _height = height; } void Pipes::draw(N5110 &lcd) { lcd.drawRect(_x,0,6,_height,FILL_BLACK); lcd.drawRect((_x-1),_height,8,3,FILL_BLACK); lcd.drawRect((_x-1),(_height+23),8,3,FILL_BLACK); lcd.drawRect(_x,(_height+26),6,(84-(_height+26)),FILL_BLACK); } //if(_x<1) { //_height = rand() % (20 + 1 - 2) + 2; //_x=84; //} //} int Pipes::generate_height() { int _random_height=rand() % (25 + 1 - 0) + 0; return _random_height; }