You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add a button to hide inventory cards.
Some cards you reserve for crafting badges or for collecting, and don't want to sell them. It would be interesting to be able to hide them, in order to leave only the tradable cards showing. Thus facilitating, visualize and sell with the script.
The text was updated successfully, but these errors were encountered:
darkdroider
changed the title
[Sugestion] Add a button to hide inventory cards
[Suggestion] Add a button to hide inventory cards
Apr 3, 2023
function sellAllCards() {
loadAllInventories().then(function () {
var items = getInventoryItems();
var filteredItems = [];
items.forEach(function (item) {
if (!getIsTradingCard(item) || !item.marketable) {
return;
}
let str = item.description.market_hash_name;
let index = str.indexOf('-');
let gameid = str.slice(0, index);
let result = {};
let flag = 0;
for (let key in NotSellCard) {
result[key] = {};
for (let subKey in NotSellCard[key]) {
if (subKey == gameid) {
flag = 1;
}
}
}
if (flag == 1) {
console.log('Do not sell ' + gameid + ' card.');
} else {
filteredItems.push(item);
}
});
sellItems(filteredItems);
}, function () {
logDOM('Could not retrieve the inventory...');
});
}
When the game ID in NotSellCard, you click 'Sell All Cards' button, which will not sell the game ID cards.
The above code will not sell all cards with game ID 218410,619390,1186460,399120,766280,548840.
Add a button to hide inventory cards.
Some cards you reserve for crafting badges or for collecting, and don't want to sell them. It would be interesting to be able to hide them, in order to leave only the tradable cards showing. Thus facilitating, visualize and sell with the script.
The text was updated successfully, but these errors were encountered: