Jump to content
McKay Development

sent Offer remains in state 2


Recommended Posts

When I send an offer from the bot to the user and the user accepts and confirms with the mobile the bot's account receives the item but no event is launched on bot.
Polling Data manually every 2 seconds shows that the offer is shown in pollData in state 2 still. Also no other events seem to work for me (EG: .on("debug",console.log) ). Can I have made a mistake that crashed the events?

My code looks something like this

 

console.dir("logged");
var manager = new SteamTrades({
	"community": bot.community, // Polling every 30 seconds is fine since we get notifications from Steam
	//"domain": "example.com", 
	"pollInterval": 5000,
	"language": "en" // We want English item descriptions
});
manager.on('sentOfferChanged',function(offer, oldState) {
	console.dir("sentOfferChanged");
	console.dir(offer);
});
manager.on('pollFailure',function(err){
	console.log("failed to poll");
	console.log(err);
});
manager.on('pollData',function(pollData){
	console.log("pollData ",pollData);
});
manager.on('debug', console.log);
live_bots[bot.index].manager = manager;

Link to comment
Share on other sites

1) SteamTrades is actually var SteamTrades = require("steam-tradeoffer-manager");  so just bad naming.
2) no, I only create the trade manager object after it's already logged via a Steam Community by passing the community object (I assumed this step also takes the cookies ? )
3) For the events none, for pollData I print with an interval is something like
{ sent: { '1389220944': 2 } }

So Trad is still in state 2

Link to comment
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
×
×
  • Create New...