public void messageReceived(HostedConnection source, Message m) {

            if (m instanceof PositionMessage) {
                PositionMessage pm = (PositionMessage) m;
                
                if (pm.subject != null) {
                    server.broadcast(pm);
                }

            } else if (m instanceof ChatMessage) {
                ChatMessage cm = (ChatMessage) m;

                if (cm.message.startsWith("/")) {
                    System.out.println("Server Command: " + cm.message);
                } else {
                    cm.timestamp = System.currentTimeMillis();
                    cm.player = dataHandler.getPlayerID(source);

                    server.broadcast(cm);
                }
            } else if (m instanceof ActionMessage) {
                
                ActionMessage am = (ActionMessage) m;
                System.out.println("SERVER: AM: "+ am.action);
                server.broadcast(am);
            } 

        }