Ejemplo n.º 1
0
  public ServerConnection getConnection() {
    for (ServerConnection connection : ServerCore.instance().connections.values()) {
      if (connection.user != null) {
        if (connection.user.username == username) {
          return connection;
        }
      }
    }

    return null;
  }
Ejemplo n.º 2
0
  public User(String name, ArrayList<String> message) {
    username = name;
    messages = message;

    ServerCore.instance().cachedUsers.put(username, this);
  }