This commit is contained in:
@@ -21,7 +21,6 @@ import sudoku.io.SudokuSerializer;
|
||||
public class ClientConnexion extends Connexion {
|
||||
|
||||
private final Client client;
|
||||
private Player player = null;
|
||||
|
||||
public ClientConnexion(String address, short port, Client client) throws UnknownHostException, IOException {
|
||||
super(new Socket(address, port));
|
||||
@@ -38,7 +37,7 @@ public class ClientConnexion extends Connexion {
|
||||
|
||||
@Override
|
||||
public void visitPacket(ConnexionInfoPacket packet) {
|
||||
this.player = this.client.getGame().getPlayerById(packet.getConnectionId());
|
||||
this.client.player = this.client.getGame().getPlayerById(packet.getConnectionId());
|
||||
client.onConnect.emit();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user