Beispiel #1
0
void Server::externalRoomSay(int roomId, const QString &userName, const QString &message)
{
    // This function is always called from the main thread via signal/slot.
    QReadLocker locker(&roomsLock);
    
    Server_Room *room = rooms.value(roomId);
    if (!room) {
        qDebug() << "externalRoomSay: room id=" << roomId << "not found";
        return;
    }
    room->say(userName, message, false);
}
Beispiel #2
0
void Server::externalRoomSay(int roomId, const QString &userName, const QString &message)
{
    // This function is always called from the main thread via signal/slot.
    QReadLocker locker(&roomsLock);

    Server_Room *room = rooms.value(roomId);
    if (!room) {
        qDebug() << "externalRoomSay: room id=" << roomId << "not found";
        return;
    }
    room->say(userName, message, false);

    getDatabaseInterface()->logMessage(0, userName, "ISL", message, Server_DatabaseInterface::MessageTargetIslRoom, room->getId(), room->getName());
}