mirror of
https://github.com/inf112-v20/Fiasko.git
synced 2025-01-31 23:29:36 +01:00
Legger til manglende kommentar for RoboRallyClientListener konstruktør
This commit is contained in:
parent
f6aaf9c08a
commit
696cf54aaf
@ -47,10 +47,15 @@ public class RoboRallyClient {
|
|||||||
class RoboRallyClientListener extends Listener {
|
class RoboRallyClientListener extends Listener {
|
||||||
private final RoboRallyWrapper wrapper;
|
private final RoboRallyWrapper wrapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Instantiates a new Robo Rally client listener
|
||||||
|
* @param wrapper The Robo Rally wrapper to interact with
|
||||||
|
*/
|
||||||
RoboRallyClientListener(RoboRallyWrapper wrapper) {
|
RoboRallyClientListener(RoboRallyWrapper wrapper) {
|
||||||
super();
|
super();
|
||||||
this.wrapper = wrapper;
|
this.wrapper = wrapper;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void received (Connection connection, Object object) {
|
public void received (Connection connection, Object object) {
|
||||||
if (object instanceof ErrorResponse) {
|
if (object instanceof ErrorResponse) {
|
||||||
@ -58,7 +63,7 @@ class RoboRallyClientListener extends Listener {
|
|||||||
System.out.println(errorResponse.getErrorMessage());
|
System.out.println(errorResponse.getErrorMessage());
|
||||||
} else if (object instanceof GameStartInfo) {
|
} else if (object instanceof GameStartInfo) {
|
||||||
GameStartInfo info = (GameStartInfo) object;
|
GameStartInfo info = (GameStartInfo) object;
|
||||||
wrapper.roboRallyGame = new RoboRallyGame(info.getPlayerlist(), info.getBoardname(),
|
wrapper.roboRallyGame = new RoboRallyGame(info.getPlayerList(), info.getBoardName(),
|
||||||
wrapper.server != null);
|
wrapper.server != null);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user