Updating client and server. Server passing states, client passing actions
cleaning