Skip to content

Instantly share code, notes, and snippets.

@chodyo
Last active December 27, 2021 17:49
Show Gist options
  • Save chodyo/36db1be5147d568d2a1c330f7c5955fc to your computer and use it in GitHub Desktop.
Save chodyo/36db1be5147d568d2a1c330f7c5955fc to your computer and use it in GitHub Desktop.
Tampermonkey script to skip through the steam exploration queue
// ==UserScript==
// @name Fast trading card
// @namespace http://tampermonkey.net/
// @version 1.0.6
// @description skip through the steam exploration queue to get your trading card without having to click
// @author https://github.com/chodyo
// @updateURL https://gist.github.com/chodyo/36db1be5147d568d2a1c330f7c5955fc/raw/fast_trading_card.user.js
// @downloadURL https://gist.github.com/chodyo/36db1be5147d568d2a1c330f7c5955fc/raw/fast_trading_card.user.js
// @match https://store.steampowered.com/app/*
// @match https://store.steampowered.com/agecheck/app/*
// @icon https://www.google.com/s2/favicons?domain=steampowered.com
// @grant none
// ==/UserScript==
(function() {
'use strict';
function next() {
document.getElementsByClassName("next_in_queue_content")[0].click();
}
// Try to click next as soon as the page is done loading
document.onreadystatechange = next();
// But sometimes the page never finishes loading
setInterval(next, 2000);
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment