Added code for game mechanics and alpha-beta