Fixes to lua socket and some more work on client/server script.