Adjust print statements
This commit is contained in:
@@ -34,6 +34,8 @@ public void update() {
|
||||
return;
|
||||
}
|
||||
|
||||
System.out.println("receive notification:" + n.getClass().getName());
|
||||
|
||||
timer.reset();
|
||||
delay = 0;
|
||||
|
||||
|
||||
@@ -205,7 +205,7 @@ public void messageReceived(HostedConnection source, Message message) {
|
||||
* @param message as the received message as a Message object.
|
||||
*/
|
||||
private void messageReceived(HostedConnection source, ClientMessage message) {
|
||||
System.out.println(message.getClass().getName());
|
||||
System.out.println("server received from: " + source.getId() + " " + message.getClass().getName());
|
||||
pendingMessages.add(new ReceivedMessage(message, source.getId()));
|
||||
}
|
||||
|
||||
@@ -281,7 +281,7 @@ public void send(int id, ServerMessage message) {
|
||||
}
|
||||
final HostedConnection connection = myServer.getConnection(id);
|
||||
if (connection != null){
|
||||
System.out.println(message.getClass().getName());
|
||||
System.out.println("server sends to: " + id + " " + message.getClass().getName());
|
||||
connection.send(message);
|
||||
}
|
||||
else LOGGER.log(Level.ERROR, "there is no connection with id={0}", id); //NON-NLS
|
||||
|
||||
@@ -71,7 +71,7 @@ public void received(MoveMessage msg) {
|
||||
//set new node
|
||||
logic.getGame().getBoard().getInfield()[msg.getTargetIndex()].setOccupant(piece);
|
||||
}
|
||||
|
||||
|
||||
parent.getParent().setState(parent.getParent().getMovePiece());
|
||||
}
|
||||
}
|
||||
|
||||
@@ -78,9 +78,7 @@ private StartNode createStartNode(int i) {
|
||||
* @return the index of the piece
|
||||
*/
|
||||
public int getInfieldIndexOfPiece(Piece piece) {
|
||||
System.out.println("Get uuid of: "+ piece.getUuid());
|
||||
for (int i = 0; i < infield.length; i++) {
|
||||
System.out.println(infield[i].getOccupant());
|
||||
if(infield[i].isOccupied()) {
|
||||
if (infield[i].getOccupant().equals(piece)) {
|
||||
return i;
|
||||
|
||||
Reference in New Issue
Block a user