-
-
Notifications
You must be signed in to change notification settings - Fork 28
/
Game-Inventories-Count.user.js
32 lines (29 loc) · 1.12 KB
/
Game-Inventories-Count.user.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
// ==UserScript==
// @name Game Inventories Count
// @icon https://store.steampowered.com/favicon.ico
// @namespace steam
// @version 1.7
// @description It shows how many game inventories user has
// @author Lutymane
// @match *://steamcommunity.com/*/*/inventory*
// @match *://steamcommunity.com/groups/InventoryService
// @grant none
// ==/UserScript==
var Inventories = null;
var Count = 0;
$J(document).ready(function () {
if (location.href.includes('InventoryService')) {
Count = $J('.group_associated_game_icon').length;
$J('.rightbox_content_header').contents()[0].textContent += ' COUNT: ' + Count;
}
else {
Inventories = $J('[id*=inventory_link_]');
Count = Inventories.length;
$J('.games_list_tabs_ctn.responsive_hidden').before('<div class="fraud_warning"><div class="fraud_warning_box"><span>Game Inventories Count: ' + Count + '</span></div></div>');
setTimeout(function () {
Inventories.each(function () {
$J(this).attr('style', 'display:block;');
});
}, 500);
}
});