woepertjes Posted March 31, 2018 Report Posted March 31, 2018 (edited) Is their a function/piece of code that is similar to the following: client.on('friendRelationship', (steamid, relationship) => { if (relationship === 2) { client.addFriend(steamid); } }); But instead of it being for friends and friend invites, it being for groups and group invites? Cheers on the info! Edited March 31, 2018 by woepertjes Quote
Dr. McKay Posted March 31, 2018 Report Posted March 31, 2018 https://github.com/DoctorMcKay/node-steam-user#grouprelationship https://github.com/DoctorMcKay/node-steam-user#respondtogroupinvitegroupsteamid-accept Quote
woepertjes Posted March 31, 2018 Author Report Posted March 31, 2018 I added this code: client.on('groupRelationship', (sid, relationship) => { if (relationship === 2) { client.respondToGroupInvite(sid, true); } }); I've tested it and it failed. I have the strongest of feelings that i'm using it wrong. Quote
Dr. McKay Posted March 31, 2018 Report Posted March 31, 2018 That will only respond to invitations that come in while the bot is running. If the invitation was already there when you started up, it won't emit groupRelationship. You want to also check myGroups. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.