added logger
This commit is contained in:
@@ -706,11 +706,13 @@ public void clearSelectable(){
|
|||||||
p.unSelect();
|
p.unSelect();
|
||||||
p.unHighlight();
|
p.unHighlight();
|
||||||
p.setSelectable(false);
|
p.setSelectable(false);
|
||||||
|
p.setHoverable(false);
|
||||||
}
|
}
|
||||||
for(PieceControl p : selectableOwnPieces) {
|
for(PieceControl p : selectableOwnPieces) {
|
||||||
p.unSelect();
|
p.unSelect();
|
||||||
p.unHighlight();
|
p.unHighlight();
|
||||||
p.setSelectable(false);
|
p.setSelectable(false);
|
||||||
|
p.setHoverable(false);
|
||||||
}
|
}
|
||||||
for(NodeControl n : outlineNodes){
|
for(NodeControl n : outlineNodes){
|
||||||
n.deOutline();
|
n.deOutline();
|
||||||
|
|||||||
@@ -204,7 +204,7 @@ public void messageReceived(HostedConnection source, Message message) {
|
|||||||
* @param message as the received message as a Message object.
|
* @param message as the received message as a Message object.
|
||||||
*/
|
*/
|
||||||
private void messageReceived(HostedConnection source, ClientMessage message) {
|
private void messageReceived(HostedConnection source, ClientMessage message) {
|
||||||
LOGGER.log(Level.INFO, "message received from {0}: {1}", source.getId(), message); //NON-NLS
|
System.out.println(message.getClass().getName());
|
||||||
pendingMessages.add(new ReceivedMessage(message, source.getId()));
|
pendingMessages.add(new ReceivedMessage(message, source.getId()));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -279,10 +279,11 @@ public void send(int id, ServerMessage message) {
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
final HostedConnection connection = myServer.getConnection(id);
|
final HostedConnection connection = myServer.getConnection(id);
|
||||||
if (connection != null)
|
if (connection != null){
|
||||||
|
System.out.println(message.getClass().getName());
|
||||||
connection.send(message);
|
connection.send(message);
|
||||||
else
|
}
|
||||||
LOGGER.log(Level.ERROR, "there is no connection with id={0}", id); //NON-NLS
|
else LOGGER.log(Level.ERROR, "there is no connection with id={0}", id); //NON-NLS
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -85,7 +85,6 @@ public void received(MoveMessage msg) {
|
|||||||
logic.getGame().getPlayerByColor(occ.getColor()).addWaitingPiece(occ);
|
logic.getGame().getPlayerByColor(occ.getColor()).addWaitingPiece(occ);
|
||||||
}
|
}
|
||||||
logic.addNotification(new MovePieceNotification(msg.getPiece().getUuid(), oldIndex, msg.getTargetIndex()));
|
logic.addNotification(new MovePieceNotification(msg.getPiece().getUuid(), oldIndex, msg.getTargetIndex()));
|
||||||
|
|
||||||
//clear old node
|
//clear old node
|
||||||
logic.getGame().getBoard().getInfield()[logic.getGame().getBoard().getInfieldIndexOfPiece(piece)].clearOccupant();
|
logic.getGame().getBoard().getInfield()[logic.getGame().getBoard().getInfieldIndexOfPiece(piece)].clearOccupant();
|
||||||
//set new node
|
//set new node
|
||||||
|
|||||||
Reference in New Issue
Block a user