Made random less random (or more random)
moved rand() to main function
tried to fix checkmate logic, to no end