Jump to content
McKay Development

Recommended Posts

Posted
Here's a bit of my code, which works I've removed the callback as it didn't need to be there, so I can check when an offer is pending confirmation, then it gets added to the database, but when it gets added if for some reason the bot doesn't auto acceppt it (I have .checkconfirmations on but still if there's an error) so this code wouldn't be the best, so how would I check upon when the bot confirms a trade?

 

Here's the little bit of code

 

offer.Send(callback etc 

{

 

if(status == "pending")

{

console.log("Trade offer Pending. Offer #" + offer.id + " Regardless, adding to database with the offer state: 9");

tradeData = { tradeofferid: offer.id, steamid: partner, type: type, amount: value, paid: 0, offerState: 7 };

connection.query('INSERT INTO csgotrades SET ?', tradeData);

}

 

});

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...