Skip to content

Gets the data required by some Steam Trading Card bots.

Notifications You must be signed in to change notification settings

Kladdkaka/BadgeScraper

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

48 Commits
 
 
 
 
 
 
 
 

Repository files navigation

BadgeScraper

Gets the data required by some Steam Trading Card bots.

Requirements

  1. Node.js
apt-get install nodejs
  1. NPM (Node.js Package Manager)
apt-get install npm

How to Install / Run

  1. Clone this Git
git clone https://github.com/SpartanC001/BadgeScraper.git
cd BadgeScraper
  1. Install Node.js Packages
npm i
  1. Run it!
node index.js

How to Update

  1. Pull the newest commits
git pull
  1. Install additional Node.js packages in case any new ones were added
npm i
  1. Re-run it!
node index.js

Modifying Bot Code

  1. In utils.js add these lines at the top of the file;
var fs = require('fs');
var path = require('path');
  1. In utils.js replace t.getCardsInSets function with the following;
t.getCardsInSets = (callback) => {
    fs.readFile(path.join(__dirname,'.','set_data.json'), 'utf8', (err,data) => {
        if (err) {
            callback(err);
        }
        callback(null, JSON.parse(data));
    });
};
  1. Place your set_data.json in the directory along with the bot files.
  2. You're good to go! Your bot should now work again with correct set data!

Notes

  • Script may take 30 minutes or more to complete on a slow connection!
  • set_data.json is only provided once the script completes.
  • Adjust reqLimit to change the speed of the script (warning below).
var reqLimit = 25; // Max simultaneous requests
  • Setting reqLimit too high on a slow connection will possibly result in the script getting stuck and never completing, or even crashing, setting it too high on a fast connection may also get you rate-limited by Steam!

Found this helpful and saved your bot?

  • Feel free to send some bitcoin my way;
1NvqNqZrcJuqq6rsPyB2CazapxCZ4Wk6Fs

About

Gets the data required by some Steam Trading Card bots.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 100.0%