public Integer isExitValid (Integer currentRoom, String trigger, String username, PrintWriter out) {
        for (Map.Entry<String, String[]> exit : environmentExits.entrySet()) {
            if (exit.getKey().startsWith(currentRoom + ":")) {
                String[] tempArray = exit.getValue();
                if (tempArray[1].equals(trigger)) {
                    if (Integer.parseInt(tempArray[2]) == currentRoom) {
                        out.println("You wander through the exit but somehow end up back in the SAME room you tried to leave! Maybe you should go a different way...");
                        out.flush();
                    } else {
                        for (Map.Entry<String, ClientHandler> user : GlobalVars.activeUsers.entrySet()) {
                            if (user.getValue().currentRoom.equals(currentRoom)) {
                                if (!user.getValue().username.equals(username)) {
                                    PrintWriter uOut = user.getValue().out;
                                    uOut.println(username + " left the room.");
                                    uOut.flush();
                                }
                            }
                        }
                        changeRoom(Integer.parseInt(tempArray[2]), username, out);
                    }
                    return Integer.parseInt(tempArray[2]);
                }
            }
        }
        return 0;
    }