Java tetris game with use of patterns