private final void buildNotifications() {
	// any function that calls this should be wrapped in synchronized(notifications) to make sure that it doesn't change before that function finishes with the updated notifications
	if (!bDirty) {
	    return;
	}
	final Set<Integer> chs = WorldRegistryImpl.getInstance().getChannelServer();

	if (notifications.keySet().size() != chs.size()) {
	    notifications.clear();
	    for (final Integer ch : chs) {
		notifications.put(ch, new java.util.LinkedList<Integer>());
	    }
	} else {
	    for (List<Integer> l : notifications.values()) {
		l.clear();
	    }
	}
	for (final MapleGuildCharacter mgc : members) {
	    if (!mgc.isOnline()) {
		continue;
	    }
	    final List<Integer> ch = notifications.get(mgc.getChannel());
	    if (ch == null) {
		System.err.println("Unable to connect to channel " + mgc.getChannel());
	    } else {
		ch.add(mgc.getId());
	    }
	}
	bDirty = false;
    }