merge dev into test #30

Merged
j23f0712 merged 45 commits from development into dev/test 2024-12-02 01:29:40 +01:00
Showing only changes of commit 8f53b76a3e - Show all commits

View File

@@ -1,17 +1,33 @@
package pp.mdga.message.server; package pp.mdga.message.server;
import com.jme3.network.serializing.Serializable; import com.jme3.network.serializing.Serializable;
import pp.mdga.game.Board;
/** /**
* A message indicating that the game shall start. * A message indicating that the game shall start.
*/ */
@Serializable @Serializable
public class ServerStartGameMessage extends ServerMessage { public class ServerStartGameMessage extends ServerMessage {
/**
* Create ServerStartGameMessage attributes.
*/
private final Board board;
/** /**
* Constructs a new ServerStartGame instance. * Constructs a new ServerStartGame instance.
*/ */
public ServerStartGameMessage() { public ServerStartGameMessage() {
super(); super();
this.board = null;
}
/**
* Constructor.
*
* @param board as the complete board of this game as a Board object.
*/
public ServerStartGameMessage(Board board) {
this.board = board;
} }
/** /**
@@ -24,6 +40,15 @@ public void accept(ServerInterpreter interpreter) {
interpreter.received(this); interpreter.received(this);
} }
/**
* This method will be used to return board attribute of ServerStartGameMessage class.
*
* @return board as a Board object.
*/
public Board getBoard() {
return this.board;
}
/** /**
* Returns a string representation of this message. * Returns a string representation of this message.
* *