N
N
Nick Anonymous2020-05-02 01:56:28
Node.js
Nick Anonymous, 2020-05-02 01:56:28

I downloaded the sources of the trade bot on node js, after installation an error appeared, how can I solve it, and how do I set up such a bot in general?

I downloaded the node js trade bot sources from here -> https://github.com/alex7kom/node-steam-tradeoffers <- unpacked it into a prepared folder in the domains Open Server. Since I only needed a bot that sends a trade to another person, I decided to use the ready-made code from examples/offerbot.js I downloaded additional node-steam, steam-weblogon, and steam-web-api-key I entered the data, I received an email , but after the next launch I got such an error 5eaca87b1a1b6578253684.png
Who has experience in setting up or creating trade bots, please help, there is almost no information on the Internet about how to set up such bots.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
E
edward_freedom, 2020-05-07
@edward_freedom

Try to specify a function as the third parameter of fs callback, as indicated here . The line where to replace is indicated in the error

fs.writeFile("hello.txt", "Hello мир!", function(error){
 
    if(error) throw error; // если возникла ошибка
    console.log("Асинхронная запись файла завершена. Содержимое файла:");
    let data = fs.readFileSync("hello.txt", "utf8");
    console.log(data);  // выводим считанные данные
});

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question