mirror of
https://github.com/Detanup01/gbe_fork.git
synced 2025-01-12 02:19:31 +08:00
use the new functions to check for friend ID in the auto accept list
This commit is contained in:
parent
a98baef856
commit
d73faeff38
@ -1241,7 +1241,7 @@ void Callback(Common_Message *msg)
|
|||||||
data.m_ulGameID = f->appid();
|
data.m_ulGameID = f->appid();
|
||||||
callbacks->addCBResult(data.k_iCallback, &data, sizeof(data));
|
callbacks->addCBResult(data.k_iCallback, &data, sizeof(data));
|
||||||
|
|
||||||
if (overlay->Ready() && !settings->auto_accept_invites.count(msg->source_id()))
|
if (overlay->Ready() && !settings->hasOverlayAutoAcceptInviteFromFriend(msg->source_id()))
|
||||||
{
|
{
|
||||||
//TODO: the user should accept the invite first but we auto accept it because there's no gui yet
|
//TODO: the user should accept the invite first but we auto accept it because there's no gui yet
|
||||||
// Then we will handle it !
|
// Then we will handle it !
|
||||||
@ -1260,7 +1260,7 @@ void Callback(Common_Message *msg)
|
|||||||
if (msg->friend_messages().type() == Friend_Messages::GAME_INVITE) {
|
if (msg->friend_messages().type() == Friend_Messages::GAME_INVITE) {
|
||||||
PRINT_DEBUG("Steam_Friends Got Game Invite\n");
|
PRINT_DEBUG("Steam_Friends Got Game Invite\n");
|
||||||
//TODO: I'm pretty sure that the user should accept the invite before this is posted but we do like above
|
//TODO: I'm pretty sure that the user should accept the invite before this is posted but we do like above
|
||||||
if (overlay->Ready() && !settings->auto_accept_invites.count(msg->source_id()))
|
if (overlay->Ready() && !settings->hasOverlayAutoAcceptInviteFromFriend(msg->source_id()))
|
||||||
{
|
{
|
||||||
// Then we will handle it !
|
// Then we will handle it !
|
||||||
overlay->SetRichInvite(*find_friend(static_cast<uint64>(msg->source_id())), msg->friend_messages().connect_str().c_str());
|
overlay->SetRichInvite(*find_friend(static_cast<uint64>(msg->source_id())), msg->friend_messages().connect_str().c_str());
|
||||||
|
@ -242,7 +242,7 @@ void Steam_Overlay::OpenOverlayInvite(CSteamID lobbyId)
|
|||||||
void Steam_Overlay::OpenOverlay(const char* pchDialog)
|
void Steam_Overlay::OpenOverlay(const char* pchDialog)
|
||||||
{
|
{
|
||||||
// TODO: Show pages depending on pchDialog
|
// TODO: Show pages depending on pchDialog
|
||||||
if ((strncmp(pchDialog, "Friends", sizeof("Friends") - 1) == 0) && (settings->auto_accept_invites.size() > 0)) {
|
if ((strncmp(pchDialog, "Friends", sizeof("Friends") - 1) == 0) && (settings->overlayAutoAcceptInvitesCount() > 0)) {
|
||||||
PRINT_DEBUG("Not opening overlay's friends list because some friends are defined in the auto accept list\n");
|
PRINT_DEBUG("Not opening overlay's friends list because some friends are defined in the auto accept list\n");
|
||||||
AddAutoAcceptInviteNotification();
|
AddAutoAcceptInviteNotification();
|
||||||
} else {
|
} else {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user