
xLeeJYx
Member-
Posts
100 -
Joined
-
Last visited
Everything posted by xLeeJYx
-
solved by doing console.log(err.message)
-
you dont wanna get banned on steam
-
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 ?
-
Question Polling file and max pending trades
xLeeJYx replied to OczkoSX's topic in node-steam-tradeoffer-manager
u can have as many offer sent and received as you want -
haha, thanks but i already figured out by myself. Just fixed bp.tf automatic's bug
-
As the picture below how can i check if the item name contain the tag 'Craft Item' ?
-
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
-
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?
-
did you change phone or something ? and had 15 days passed ?
-
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)
-
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
-
In Wow thanks man
-
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!' )}
-
Anyone can help me with this ? ;_;
-
what should i type so that, what is offered will be displayed in the console and check if it is containing tf2 items only ?
-
multiple bots ? do you mean you want to run more than 1 bot on 1 pc ?
-
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
-
How to make manager do something when trade succeded
xLeeJYx replied to xLeeJYx's topic in node-steam-tradeoffer-manager
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'); }); -
How to make manager do something when trade succeded
xLeeJYx replied to xLeeJYx's topic in node-steam-tradeoffer-manager
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 -
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!") }