public static void main(String[] args) {

        //<editor-fold defaultstate="collapsed" desc="Graphical User Interface">
        try {
            // Try to set operating systems default look (I.E. Windows or Mac theme).
            UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
        } catch (Exception ex) {
            JOptionPane.showMessageDialog(null, "Error: " + ex.getMessage(), "Alert", JOptionPane.ERROR_MESSAGE);
        }

        // Get the external IP & port.
        ip = getServerIP(port);

        // Set up button that disconnects selected players.
        btn_disconnect = new JButton();
        btn_disconnect.setText(Config.DISCONNECT_BUTTON_TEXT);
        btn_disconnect.addActionListener(new ActionListener() {
            @Override
            public void actionPerformed(ActionEvent e) {
                int selected = clientList.getSelectedIndex();
                if (selected != -1) {
                    String username = clientListModel.getElementAt(selected).toString().split(" ")[0];
                    removeConnection(username, 1);
                }
            }
        });

        // Set up lists to store and display Player names.
        clientListModel = new DefaultListModel();
        clientList = new JList(clientListModel);
        clientList.addListSelectionListener(new ListSelectionListener() {
            @Override
            public void valueChanged(ListSelectionEvent e) {
                if (e.getValueIsAdjusting())
                    System.out.println(clientList.getSelectedIndex());
            }
        });

        frame = new JFrame();
        frame.setTitle(Config.SERVER_NAME);
        frame.addWindowListener(new WindowListener() {
            public void windowOpened(WindowEvent e) {
            }

            @Override
            public void windowClosing(WindowEvent e) {

                List<Client> list = new ArrayList<>(getConnections());

                // Disconnect all clients.
                for (Client client : list) {
                    removeConnection(client.getUsername(), 2);
                }

                System.exit(0);
            }

            public void windowClosed(WindowEvent e) {
            }

            public void windowIconified(WindowEvent e) {
            }

            public void windowDeiconified(WindowEvent e) {
            }

            public void windowActivated(WindowEvent e) {
            }

            public void windowDeactivated(WindowEvent e) {
            }
        });

        // Start drawing GUI.
        
        panel_1 = new JPanel();
        panel_1.setLayout(new GridLayout(1, 1, 1, 1));
        panel_1.add(btn_disconnect);

        panel_2 = new JPanel();
        panel_2.add(new JLabel(ip));

        panel_3 = new JPanel();
        panel_3.setLayout(new BorderLayout(1, 1));
        panel_3.add(panel_1, BorderLayout.NORTH);
        panel_3.add(new JScrollPane(clientList), BorderLayout.CENTER);
        panel_3.add(panel_2, BorderLayout.SOUTH);

        panel_4 = new JPanel();
        panel_4.setLayout(new BorderLayout(1, 100));
        panel_4.add(new JTextArea("1] lol and stuff\n2] lol\n3] erm"), BorderLayout.CENTER);

        panel_5 = new JPanel();
        panel_5.setLayout(new BorderLayout(1, 1));
        panel_5.add(new JTextArea("<ENTER TEXT HERE>"), BorderLayout.SOUTH);

        panel_6 = new JPanel();
        panel_6.setLayout(new BorderLayout(1, 1));
        panel_6.add(panel_4, BorderLayout.CENTER);
        panel_6.add(panel_5, BorderLayout.SOUTH);

        panel_content = new JPanel();
        panel_content.setLayout(new GridLayout(1, 1, 1, 1));
        panel_content.add(panel_3, BorderLayout.WEST);
        panel_content.add(panel_6, BorderLayout.EAST);
        panel_content.setBorder(BorderFactory.createEmptyBorder(10, 10, 10, 10));

        frame.setContentPane(panel_content);
        frame.pack();
        frame.setSize(350, 400);
        frame.setLocationRelativeTo(null);
        frame.setVisible(true);
        // </editor-fold>

        try {
            // Setup server connection socket.
            server = new ServerSocket(port);
        } catch (IOException ex) {
            Logger.getLogger(ProjectInfernoServer.class.getName()).log(Level.SEVERE, null, ex);
            JOptionPane.showMessageDialog(null, "Error: " + ex.getMessage(), "Alert", JOptionPane.ERROR_MESSAGE);
            System.exit(0);
        }

        // Start accepting connections from players.
        connections = new ArrayList<>();
        (new ConnectionListener()).start();

    }