SteamBot icon indicating copy to clipboard operation
SteamBot copied to clipboard

Ignore all Steam messages coming from people who are not on our friends list

Open scholtzm opened this issue 10 years ago • 11 comments

This has been bothering me for a while now.

SteamBot does not ignore Steam messages coming from people who are not on our friends list. This way, you can even do a trade. Regular Steam client (partially) ignores these messages.

We already have this so the fix should be fairly straight forward.

cc @BlueRaja @WildCard65 @FrozenHaxor

scholtzm avatar Jan 28 '15 09:01 scholtzm

Hmm. Can you actually initiate a trade with a bot not on your friends list, though?

Bottswana avatar Jan 28 '15 09:01 Bottswana

Yes you can. You can initiate it and go through the trade just like with any other person on your friends list.

scholtzm avatar Jan 28 '15 09:01 scholtzm

That’s a pain. But as you say, it should just be a cause of altering the message handler to not pass steam chats or trade requests on from non friends.

I’m surprised there’s not some form of check on the steam network itself for trading with non friends. Hmm.

From: Michael Scholtz [mailto:[email protected]] Sent: 28 January 2015 09:54 To: Jessecar96/SteamBot Cc: Bottswana Subject: Re: [SteamBot] Ignore all Steam messages coming from people who are not on our friends list (#702)

Yes you can.

— Reply to this email directly or view it on GitHub https://github.com/Jessecar96/SteamBot/issues/702#issuecomment-71807770 . https://github.com/notifications/beacon/AGlmRGu02jbiIInkqEC_Nmg28KY5mHSNks5nmKlSgaJpZM4DYPNL.gif

Bottswana avatar Jan 28 '15 10:01 Bottswana

Also somehow blocked people count as friends. For example if you block someone and remove them, this won't decrease, which is extremely annoying. I assume this is just another example of the stated above... the wonders of Steam.

FrozenHaxor avatar Jan 28 '15 12:01 FrozenHaxor

@FrozenHaxor I think that issue would be more useful if reported to the SteamKit repo

WildCard65 avatar Jan 28 '15 13:01 WildCard65

That's actually not an issue, but that's how Steam works. People on your block list are part of your "global" friends list. You need to check relationship between you and the person. Another example is someone who adds you - this person automatically becomes part of your friends list with EFriendRelationship.RequestRecipient.

scholtzm avatar Jan 28 '15 14:01 scholtzm

Yeah I wouldn't say this is SteamKit's fault. It's just doing it's job passing on the messages it receives from the network; I mean, if it's anyones fault it's the steam network itself.

Bottswana avatar Jan 28 '15 15:01 Bottswana

You need to check relationship between you and the person.

I wrote that code, I wasn't aware of this. How do we 'check relationship'?

BlueRaja avatar Jan 28 '15 17:01 BlueRaja

Wow, I don't ever thought that it's bug, I just used

if (Bot.SteamFriends.GetFriendRelationship(OtherSID) == EFriendRelationship.Friend)
{
...
}

doktokto avatar Jan 28 '15 17:01 doktokto

@BlueRaja Which code is "that code"? :smile: You can check the relationship the way @doktokto described.

scholtzm avatar Jan 28 '15 19:01 scholtzm