Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed
Fork of el17ajf by
Tetromino/Tetromino.h
- Committer:
- el17ajf
- Date:
- 2019-03-14
- Revision:
- 6:a54df561f442
- Parent:
- 5:3efbdcb3efaf
- Child:
- 7:2e37bad816cb
File content as of revision 6:a54df561f442:
#include "Block.h" class Tetromino { public: enum Type { I, O, T, J, L, S, Z }; static Tetromino getTetrominoOfType(Type type); Tetromino movedLeft(); Tetromino movedRight(); Tetromino movedDown(); void draw(); static Type getRandomTetrominoType(); private: Tetromino translated(int dx, int dy); Tetromino(Block a, Block b, Block c, Block d); static Tetromino getTetrominoFromString(const char * str); ~Tetromino(); };