Go Fast Posted March 3, 2018 Report Posted March 3, 2018 Hi, I want my bot to comment on the user's profile upon a successful trade. I tried looking for it here: https://github.com/DoctorMcKay/node-steam-user#events- But I dont find it anywhere! Thanks! Quote
Go Fast Posted March 4, 2018 Author Report Posted March 4, 2018 So far I got this code inside of my client.on('webSession', (sessionid, cookies): manager.on('sentOfferChanged', function(offer, oldState) { const partnerID = offer.partner.getSteamID64(); console.log(`Offer #${offer.id} changed: ${TradeOfferManager.ETradeOfferState[oldState]} -> ${TradeOfferManager.ETradeOfferState[offer.state]}`); if(TradeOfferManager.ETradeOfferState[offer.state] == "Accepted"){ client.chatMessage(partnerID, "Thank you for trading with me!"); community.getSteamUser(partnerID, function(err, user){ if(err){ console.log(err); } else{ user.comment("Thanks for trading with me", function(err){ if(err){ console.log(err); } }); } }); Error I get:The specified profile could not be found, even though I get the Steam ID by using offer.partner.getSteamID64() Quote
TomYoki Posted March 7, 2018 Report Posted March 7, 2018 (edited) Don't because: 1.) It's super annoying. 2.) It doesn't give any actual advertisement whatsoever. 3.) Bots get community banned for doing this. However, if you still choose to do it just read the actual documentation.> Either a SteamID object or a user's URL (the part after /id/)akatypeof id === 'string' ? "id/" + id : "profiles/" + id.toString() Edited March 7, 2018 by TomYoki Quote
Go Fast Posted March 7, 2018 Author Report Posted March 7, 2018 (edited) Don't because: 1.) It's super annoying. 2.) It doesn't give any actual advertisement whatsoever. 3.) Bots get community banned for doing this. However, if you still choose to do it just read the actual documentation.> Either a SteamID object or a user's URL (the part after /id/)akatypeof id === 'string' ? "id/" + id : "profiles/" + id.toString()I wasn't aware this was not allowed, because I see many card bots doing that. So thank you for the info & also the code! Edit: On a second thought, I'll try to code a script to check if I already left a comment on a specific user's profile today, that way it won't be considered as spam Edited March 7, 2018 by Go Fast 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.