Moved server into its own class and fixed GUI bug of sending extra bits