Currently, both the Client and Server nodes are run by threads, that listen for incoming messages. When a message is received, this same thread, executes the received message's method.
While this may not be a big problem server-side, due to the lack of user input, this is a big issue on the client side.
For example, when the client-side listener thread waiting for incoming messages in the receiveFromServer method of the SKClientNode receives a PlayerTurnMessage, it will call the uploadPlayerTurn method itself, preventing the client from receiving any more messages, until the thread terminates its method call.
Currently, both the Client and Server nodes are run by threads, that listen for incoming messages. When a message is received, this same thread, executes the received message's method.
While this may not be a big problem server-side, due to the lack of user input, this is a big issue on the client side.
For example, when the client-side listener thread waiting for incoming messages in the receiveFromServer method of the SKClientNode receives a PlayerTurnMessage, it will call the uploadPlayerTurn method itself, preventing the client from receiving any more messages, until the thread terminates its method call.