Fartura
-
Posts
8 -
Joined
-
Last visited
Posts posted by Fartura
-
-
Hello, I wanted to create a bot of trades, I already have everything ready, just missing the essential, the exchanges. I already researched everything but I can not create a bot of exchanges .. the maximum where I arrived was this:
manager.on('newOffer', (offer) => { if (offer.partner.getSteamID64() === 'trust steamid64') { offer.accept((err, status) => { if (err) { console.log(err); } else { console.log(`Accepted offer. Status: ${status}.`); } }); } else { offer.decline((err) => { if (err) { console.log(err); } else { console.log('Canceled offer from scammer.'); } }); } });
I wanted my bot to trade and I made a profit, but I do not really know how to do it and I do not understand a lot of code, can someone please help me? PLEASE <3
-
Like I said above, variable "name" is now availabe to use in above code
Just add this code above console.log
client.chatMessage(steamid, 'Hello ' +name+ ', thanks for add me, if you need help write !help');
thanks, it was not working but I changed places and it already works, thank you.one more question, can I erase the friendship after a while? for example, my bot accepts the friendship today at 1:00 p.m. and erases the friendship tomorrow at 1:00 p.m.?What is the code for this to work? -
client.on('friendRelationship', (steamid, relationship) => { if (relationship === 2) { client.addFriend(steamid); client.chatMessage(steamid, 'Hello! Thanks for add me, if you need help write !help'); //getting name using getPersonas client.getPersonas([steamid], function(personas) { var persona = personas[steamid.getSteamID64()]; var name = persona ? persona.player_name : ("[" + steamid.getSteamID64() + "]"); //You can use 'name' to show their name console.log("You add: " + name + " - " +steamid); }); } });
Pretty much like this
I do not think you understood my objective.I want that when the person adds me to appear in the chat of the personHello (here the name of the person who added me)! Thanks for add me, if you need help write! Help -
Use getPersonas
https://github.com/DoctorMcKay/node-steam-user#getpersonassteamids-callback
Using steamcommunity getSteamUser also works
https://github.com/DoctorMcKay/node-steamcommunity/wiki/SteamCommunity#getsteamuserid-callback
sorry but I'm not very good with codeHow should I put my code?Is he as he should be?client.on('friendRelationship', (steamid, relationship) => {if (relationship === 2) {client.addFriend(steamid);client.chatMessage(steamid, 'Hello! Obrigado por me adicionar, se você precisar de ajuda, escreva! help'');console.log("You add " + (steamid))}}); -
my bot accepts requests for friendship, I want to know how do I delete the past friendship requests for example 7 days
-
Hello I wanted to make my bot when someone adds it said "hello (name of person) thanks for adding" how do I? I only have this but I do not know how to put the person's name
I have this:
how to customize to show the person's name?
client.on('friendRelationship', (steamid, relationship) => {if (relationship === 2) {client.addFriend(steamid);client.chatMessage(steamid, 'Hello! Thanks for add me, if you need help write !help');console.log("You add " + (steamid))}});
trades
in node-steam-tradeoffer-manager
Posted
I want to make a bot of public exchanges, and the bot only accept the trades that I earn profit ..