Fixed most sockets.c errors on Linux/OSX

also fixed CPU vs Player in HTML (if cpu was starting the move wasn't on
the screen).