added end of game check and getWinner() (not working yet)
merge