// ==UserScript== // @name Roblox Game Filter // @namespace http://tampermonkey.net/ // @version 0.1 // @description Filters specific Roblox games based on their title. Filters can be adjusted by editing the 'filters' array. // @author Ned - https://github.com/NedWilbur // @match *.roblox.com/* // @icon https://www.google.com/s2/favicons?sz=64&domain=roblox.com // @grant none // @license MIT // @downloadURL none // ==/UserScript== (function() { 'use strict'; window.addEventListener('load', function () { removeCards(); }, false); window.addEventListener('scroll', function () { removeCards(); }, false); } )(); function removeCards() { const filters = ['scar', 'ani-tron', 'detention', 'escape', 'killer', 'terror']; const cards = document.querySelectorAll('[data-testid="game-tile"]'); for (let i = 0; i <= cards.length-1; i++) { const title = cards[i].getElementsByClassName('game-name-title')[0].getAttribute('title').toLowerCase(); for (let k = 0; k <= filters.length-1; k++) { const filter = filters[k].toLowerCase(); if(title.includes(filter)) { console.log(`Removing card (contains '${filter}': ${title}`); cards[i].remove(); } } } }