changed from state interface to subclasses
added client class, socket doesn't work