public static Tetromino generatePiece() {
		Random r = new Random();
		Tetromino t;
		switch (r.nextInt(7)) {
		case 0:
			t = TypeI;
			break;
		case 1:
			t = TypeL;
			break;
		case 2:
			t = TypeJ;
			break;
		case 3:
			t = TypeO;
			break;
		case 4:
			t = TypeT;
			break;
		case 5:
			t = TypeZ;
			break;
		case 6:
			t = TypeS;
			break;
		default:
			t = null;
		}
		return t;
	}