monkey-island/src/fr/eseo/game/network/MonkeyIsland.java
private void onConnection() {
            System.out.println(this + "Connected");
            coms.put(this.com.getPort(), this.com);

            this.com.sendMessage(ISLAND, island.toString());
            this.com.sendMessage(PIRATES, island.getPirates().values());
            this.com.sendMessage(CRAZY_MONKEYS, island.getCrazyMonkeys());
            this.com.sendMessage(HUNTER_MONKEYS, island.getHunterMonkeys());
            this.com.sendMessage(RHUMS, island.getRhums());
        }
/**
         * On the connection of the new client.
         * Add the com's client to the map.
         * Send a message to notify the shape of the island.
         */
On the connection of the new client.
Add the com's client to the map.
Send a message to notify the shape of the island.
On the connection of the new client . Add the com ' s client to the map . Send a message to notify the shape of the island .
private void onConnection() {
            System.out.println(this + "Connected");
            coms.put(this.com.getPort(), this.com);
            this.com.sendMessage(ISLAND, island.toString());
            this.com.sendMessage(PIRATES, island.getPirates().values());
            this.com.sendMessage(CRAZY_MONKEYS, island.getCrazyMonkeys());
            this.com.sendMessage(HUNTER_MONKEYS, island.getHunterMonkeys());
            this.com.sendMessage(RHUMS, island.getRhums());
        }
private void onConnection ( ) { System . out . println ( this + "Connected" ) ; coms . put ( this . com . getPort ( ) , this . com ) ; this . com . sendMessage ( ISLAND , island . toString ( ) ) ; this . com . sendMessage ( PIRATES , island . getPirates ( ) . values ( ) ) ; this . com . sendMessage ( CRAZY_MONKEYS , island . getCrazyMonkeys ( ) ) ; this . com . sendMessage ( HUNTER_MONKEYS , island . getHunterMonkeys ( ) ) ; this . com . sendMessage ( RHUMS , island . getRhums ( ) ) ; }
On the connection of the new client.
On the connection of the new client .