Jump to content
McKay Development

xLeeJYx

Member
  • Posts

    100
  • Joined

  • Last visited

Everything posted by xLeeJYx

  1. solved by doing console.log(err.message)
  2. you dont wanna get banned on steam
  3. im trying to undestand what you are trying to say. Do you mean that, when 2 or more offers are sent at the same time, the bot only accept the first one and ignore the others until a new offer was sent ?
  4. u can have as many offer sent and received as you want
  5. haha, thanks but i already figured out by myself. Just fixed bp.tf automatic's bug
  6. As the picture below how can i check if the item name contain the tag 'Craft Item' ?
  7. haha forgot to write that for him, i have that on my code
  8. var SteamUser = require('steam-user') var client = new SteamUser(); //Commands client.on('friendMessage', function (steamID, message) { if(message == "!help"){ client.chatMessage(steamID, '\n' + 'These are the commands I have :' + '\n' + '!help' + '\n' + '!prices' + '\n' + '!owner'); } else if(message == "!prices"){ client.chatMessage(steamID, '\n' + 'Buy: 1 scrap \(0.11 ref\) \(Each\)' + '\n' + 'Sell: 2 scrap \(0.22\) \(Each\)'); } else if(message == "!owner"){ client.chatMessage(steamID, '\n' + 'My owner is LeeTheGayKid') } else { client.chatMessage(steamID, 'I don\'t understand what you are trying to say, try !help instead'); } }); This the code i used on my bot, feel free to edit
  9. when you say that, i aspect you to have gotten the new identity secret and shared secret. And did you try sending offer to other people?
  10. did you change phone or something ? and had 15 days passed ?
  11. For the error im getting this thing, its so long and annouying, how can i make it show only Error: The settings on this account do not allow you to add comments Error: The settings on this account do not allow you to add comments. at SteamCommunity.<anonymous> (C:\Users\JingYong-PC\Desktop\backpacktf-automatic-pro-master\node_modules\steamcommunity\components\users.js:151:13) at Request._callback (C:\Users\JingYong-PC\Desktop\backpacktf-automatic-pro-master\node_modules\steamcommunity\components\http.js:67:15) at Request.self.callback (C:\Users\JingYong-PC\Desktop\backpacktf-automatic-pro-master\node_modules\request\request.js:188:22) at emitTwo (events.js:106:13) at Request.emit (events.js:191:7) at Request.<anonymous> (C:\Users\JingYong-PC\Desktop\backpacktf-automatic-pro-master\node_modules\request\request.js:1171:10) at emitOne (events.js:96:13) at Request.emit (events.js:188:7) at IncomingMessage.<anonymous> (C:\Users\JingYong-PC\Desktop\backpacktf-automatic-pro-master\node_modules\request\request.js:1091:12) at IncomingMessage.g (events.js:291:16)
  12. manager.on('newOffer', (offer) =>{ function getpitems(){ offer.itemsToReceive.forEach(function(item) { if (item.appid == "440") { console.log(Status + 'All items are TF2 items'); }else{ console.log(Status + '1 or more of our items isn\'t TF2 items!') }; }) } function getoitems(){ offer.itemsToGive.forEach(function(item){ if(item.appid == "440"){ console.log(Status + 'All items are TF2 items') }else{ console.log(Status + '1 or more of our items isn\'t TF2 items!') } }) } getpitems(); getoitems(); if(getpitems.item.appid && getoitems.item.appid == '440'){ offer.accept((err) =>{ if(err){ console.log(err) } }) }else{ offer.decline((err) =>{ if(err){ console.log(err) } }) } }) ive make them into functions so i dont mess them up if(getpitems.item.appid && getoitems.item.appid == '440'){ offer.accept((err) =>{ if(err){ console.log(err) } }) }else{ offer.decline((err) =>{ if(err){ console.log(err) } })Hmm how do i make it accept the offer if the items are tf2 items ? The code up there is just something useless i tried to make
  13. ok i've got it to write down whats offered in console. This is the current code... manager.on('newOffer', (offer) =>{ console.log(trade + 'Received 1 new offer : #' + offer.id); console.log(trade + magenta + offer.partner.toString() + white + ' offered their ' + magenta + offer.itemsToReceive + white + ' for our ' + magenta + offer.itemsToGive + white); if(offer.itemsToGive == 0){ console.log(trade + 'Offer #' + offer.id + ' is a gift offer, accepting'); offer.accept(function (err){ if(err){ console.log(err) } }) }else{ console.log(trade + 'Our Items') console.log(offer.itemsToGive) console.log(trade + 'Their Items') console.log(offer.itemsToReceive) if(offer.itemsToReceive == 'Scrap Metal'){ console.log('Scrap metal found on partner\s offer !') } } }); I wanna make it check if the appid/market_hash_name is match something i want sell. how to i do it ? i tried... and it dont seem to work. Again i know i suck :c if(offer.itemsToReceive.appid == '440'){ console.log(trade + 'It\'s a TF2 trade!' )}
  14. what should i type so that, what is offered will be displayed in the console and check if it is containing tf2 items only ?
  15. multiple bots ? do you mean you want to run more than 1 bot on 1 pc ?
  16. This is my code, how can know what will i be traded ? i want it to log it in the console manager.on('newOffer', (offer) =>{ console.log(magenta + ('Received 1 new offer') + white); console.log(magenta + offer.partner.toString() + white + ' offered their ' + magenta + offer.itemsToReceive + white + ' for our ' + magenta + offer.itemsToGive + white) }); with this code im receiving this in console
  17. hmm this is the whole code, still couldnt fix it, im new to coding please don't judge. It still wont post the comment it gave this error... C:\Users\JingYong-PC\Desktop\comment\test.js:40 community.postUserComment(manager.offer.partner.toString(), 'Test'); ^ TypeError: Cannot read property 'partner' of undefined at TradeOfferManager.manager.on (C:\Users\JingYong-PC\Desktop\comment\test.js:40:40) at emitTwo (events.js:106:13) at TradeOfferManager.emit (events.js:191:7) at received.forEach (C:\Users\JingYong-PC\Desktop\comment\node_modules\steam-tradeoffer-manager\lib\polling.js:237:10) at Array.forEach (native) at getOffers (C:\Users\JingYong-PC\Desktop\comment\node_modules\steam-tradeoffer-manager\lib\polling.js:219:12) at Helpers.checkNeededDescriptions (C:\Users\JingYong-PC\Desktop\comment\node_modules\steam-tradeoffer-manager\lib\index.js:359:4) at Object.exports.checkNeededDescriptions (C:\Users\JingYong-PC\Desktop\comment\node_modules\steam-tradeoffer-manager\lib\helpers.js:90:3) at _apiCall (C:\Users\JingYong-PC\Desktop\comment\node_modules\steam-tradeoffer-manager\lib\index.js:350:11) at SteamCommunity._community.httpRequest (C:\Users\JingYong-PC\Desktop\comment\node_modules\steam-tradeoffer-manager\lib\webapi.js:54:3) Press any key to continue . . . //Required modules const SteamCommunity = require('steamcommunity'); const TradeOfferManager = require('steam-tradeoffer-manager'); const SteamTotp = require('steam-totp'); const SteamUser = require('steam-user'); //Config var config = require('./config.json') var client = new SteamUser(); var community = new SteamCommunity(); var manager = new TradeOfferManager({ steam: client, community: community, language: 'en', }); client.logOn( { accountName: config.username, password: config.password, twoFactorCode: SteamTotp.generateAuthCode(config.shared_secret) }); client.on('loggedOn', () => { console.log('Logged in to steam !'); client.setPersona(SteamUser.Steam.EPersonaState.Online); client.gamesPlayed(440); }); client.on('webSession', (sessionid, cookies) => { manager.setCookies(cookies); community.setCookies(cookies); community.startConfirmationChecker(10000, config.identity_secret); }); manager.on('receivedOfferChanged', () => { community.postUserComment(manager.offer.partner.toString(), 'Test'); });
  18. Umm what should code in there, i want it to comment when incomming trade was accepted i tried this const SteamCommunity = require('steamcommunity'); const TradeOfferManager = require('steam-tradeoffer-manager'); var community = new SteamCommunity(); var manager = new TradeOfferManager(); manager.on(receivedOfferChanged, (comment) => { community.postUserComment(offer.partner.toString(), 'Test'); });it didnt comment on the profile though
  19. This is my current project https://github.com/xLeeJYx/backpacktf-automatic-pro i plan to increase more functions on the bot My question is this : how do i make node-steamcommunity comment on profile's user when the trade succeded is there something like manager.on('succes'){ postUserComment(offer.partner.toString(), "Thanks for trading with me!") }
×
×
  • Create New...