From 481af24ca7b41d80d7e3a76ec0fefa7b9ab339cf Mon Sep 17 00:00:00 2001 From: George Hazan Date: Mon, 16 Dec 2024 18:48:19 +0300 Subject: added notification service --- protocols/Steam/src/steam_server.cpp | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'protocols/Steam/src/steam_server.cpp') diff --git a/protocols/Steam/src/steam_server.cpp b/protocols/Steam/src/steam_server.cpp index 4528ccecfe..f7330dbc49 100644 --- a/protocols/Steam/src/steam_server.cpp +++ b/protocols/Steam/src/steam_server.cpp @@ -66,6 +66,21 @@ void CSteamProto::OnMessageSent(const CFriendMessagesSendMessageResponse &reply, ///////////////////////////////////////////////////////////////////////////////////////// +void CSteamProto::OnGotNotification(const CSteamNotificationNotificationsReceivedNotification &reply, const CMsgProtoBufHeader &hdr) +{ + if (hdr.eresult != 1) + return; + + debugLogA("got %d notifications", reply.n_notifications); + + for (int i = 0; i < reply.n_notifications; i++) { + auto *N = reply.notifications[i]; + debugLogA("notification type %d: %s", N->notification_type, N->body_data); + } +} + +///////////////////////////////////////////////////////////////////////////////////////// + void CSteamProto::SendFriendActiveSessions() { CFriendsMessagesGetActiveMessageSessionsRequest request; -- cgit v1.2.3