[Premium] Faucet Monitor with Faucetpay Rotator

Fully automated support for HCaptcha, ReCaptcha, and Antibot measures with a user-friendly interface on https://coinfinity.top/downloads.php for site management and settings. Updated weekly for optimal performance.

目前為 2024-02-18 提交的版本,檢視 最新版本

// ==UserScript==
// @name         [Premium] Faucet Monitor with Faucetpay Rotator
// @namespace    https://greasyfork.org/users/1162863
// @version      3.4.1
// @description  Fully automated support for HCaptcha, ReCaptcha, and Antibot measures with a user-friendly interface on https://coinfinity.top/downloads.php for site management and settings. Updated weekly for optimal performance.
// @author       Andrewblood
// @match        *://*.coinfinity.top/*
// @match        *://*.faucetpay.io/*
// @match        *://*.dogenetwork.fun/*
// @match        *://*.solnetwork.fun/*
// @match        *://*.sollcrypto.com/*
// @match        *://*.cryptoclaps.com/*
// @match        *://*.baltoniearn.com/claim/tron/*
// @match        *://*.vptron.online/TRX/*
// @match        *://*.claimcoins.site/reward/*
// @match        *://*.bnbminers.site/earns/*
// @match        *://*.ltcmines.site/earns/*
// @match        *://*.tronxminer.com/rewards/*
// @match        *://*.etcoin.site/earn/*
// @match        *://*.autofaucet.dutchycorp.space/*
// @match        *://*.freebitco.in/*
// @match        *://*.rollercoin.com/*
// @match        *://*.freebitcoin.io/*
// @match        *://*.freebinancecoin.com/*
// @match        *://*.free-doge.com/*
// @match        *://*.freetether.com/*
// @match        *://*.freecardano.com/*
// @match        *://*.freedash.io/*
// @match        *://*.freeethereum.com/*
// @match        *://*.freebfg.com/*
// @match        *://*.freebittorrent.com/*
// @match        *://*.freepancake.com/*
// @match        *://*.freematic.com/*
// @match        *://*.freeshibainu.com/*
// @match        *://*.coinfaucet.io/*
// @match        *://*.freenem.com/*
// @match        *://*.freeusdcoin.com/*
// @match        *://*.free-tron.com/*
// @match        *://*.freesteam.io/*
// @match        *://*.freeneo.io/*
// @match        *://*.free-ltc.com/*
// @match        *://*.freecryptom.com/*
// @exclude      *://www.coinfinity.top/free-faucet/index.php
// @exclude      *://coinfinity.top/free-faucet/index.php
// @icon         https://coinfinity.top/favicon.ico
// @grant        GM_addStyle
// @grant        GM_setValue
// @grant        GM_getValue
// @grant        GM_listValues
// @grant        GM_deleteValue
// @grant        window.close
// @antifeature  referral-link     Referral-Link is in this Script integrated.
// @antifeature  ads               Advertisment Button with usefull sites.
// @license      Copyright Andrewblood
// ==/UserScript==
/*
Experience the next level of Faucet claiming with unparalleled features:

- User Interface: You can use https://coinfinity.top for the interface/buttons for managing websites, installing requirements, saving Faucetpay email address, and handling stored URLs
- Requirements Integration: Provides extension and script recommendations with install buttons for enhanced functionality.
- HCaptcha/ReCaptcha/Antibot Handling: Intelligently tackles security challenges, ensuring a smooth claiming process.
- Advanced Automation: Seamlessly fills forms and clicks buttons on Faucetpay Faucet sites, reducing manual effort.
- Efficient Navigation: Automatically moves through supported Faucet URLs, preventing revisits site until next day if it is empty or dayli limit reached for strategic claiming.
- Error Handling: Reloads pages, ensuring up-to-date claiming and avoiding downtime.



        "https://etcoin.site/earn/tron/",
        "https://etcoin.site/earn/doge/",
        "https://etcoin.site/earn/litecoin/",
        "https://etcoin.site/earn/binance/",
        "https://etcoin.site/earn/ripple/",
        "https://etcoin.site/earn/ethereum/",
        "https://etcoin.site/earn/bitcoin/",


*/
(function() {
    'use strict';

    GM_addStyle(`
    .overlay-button {
        position: fixed;
        bottom: 10px;
    }

    #advertisementButton {
        left: 10px;
    }

    #faucetMonitorButton {
        left: calc(50% - 70px); /* Adjusted position for the Faucet Monitor Button */
        transform: translateX(-50%);
    }

    #faucetpayRotatorButton {
        bottom: 10px;
        right: calc(50% - 150px); /* Adjusted position for the Rotator Button */
    }

    #settingsButton {
        right: 75px;
    }

    #aboutButton {
        right: 10px;
    }
    #overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background-color: rgba(0, 0, 0, 0.5);
        z-index: 999;
    }
    #overlay-content {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        background-color: white;
        padding: 20px;
        border-radius: 5px;
        max-height: 80%;
        overflow-y: auto;
    }
    #overlay-content table th,
    #overlay-content table td {
        padding-right: 15px;
    }

    #overlay-content table th,
    #overlay-content table td {
        padding-right: 15px;
    }
#resetAllUrlsButton {
    display: block;
    margin: 0 auto;
    margin-top: 10px;
}
        #coinBTC, #coinETH, #coinADA, #coinSOL, #coinBNB, #coinXRP,
        #coinUSDT, #coinDOGE, #coinLTC, #coinBCH, #coinTRX, #coinDGB,
        #coinDASH, #coinZEC, #coinMATIC, #coinFEY {
            width: 450px;
        }
`);

    var urls = [
        { name: 'Faucetpay - Dayli Reward', url: 'https://faucetpay.io' },
        { name: 'Freebitco.in - Claim/1000% BTC Bonus/WoF', url: 'https://freebitco.in' },
        { name: 'Dutchycorp - Claim/PTC', url: 'https://autofaucet.dutchycorp.space' },
        { name: 'Rollercoin - Marketplace buyer', url: 'https://rollercoin.com' },
        { name: 'CF Freebitcoin - Shortlinks/Promotions Bypass', url: 'https://app.freebitcoin.io' },
        { name: 'CF Freebinancecoin - Shortlinks/Promotions Bypass', url: 'https://app.freebinancecoin.com' },
        { name: 'CF Freedoge - Shortlinks/Promotions Bypass', url: 'https://app.free-doge.com' },
        { name: 'CF Freetether - Shortlinks/Promotions Bypass', url: 'https://app.freetether.com' },
        { name: 'CF Freecardano - Shortlinks/Promotions Bypass', url: 'https://app.freecardano.com' },
        { name: 'CF Freedash - Shortlinks/Promotions Bypass', url: 'https://app.freedash.io' },
        { name: 'CF Freeethereum - Shortlinks/Promotions Bypass', url: 'https://app.freeethereum.com' },
        { name: 'CF Freebfg - Shortlinks/Promotions Bypass', url: 'https://app.freebfg.com' },
        { name: 'CF Freebittorrent - Shortlinks/Promotions Bypass', url: 'https://app.freebittorrent.com' },
        { name: 'CF Freepancake - Shortlinks/Promotions Bypass', url: 'https://app.freepancake.com' },
        { name: 'CF Freematic - Shortlinks/Promotions Bypass', url: 'https://app.freematic.com' },
        { name: 'CF Freeshibainu - Shortlinks/Promotions Bypass', url: 'https://app.freeshibainu.com' },
        { name: 'CF Coinfaucet - Shortlinks/Promotions Bypass', url: 'https://app.coinfaucet.io' },
        { name: 'CF Freenem - Shortlinks/Promotions Bypass', url: 'https://app.freenem.com' },
        { name: 'CF Freeusdcoin - Shortlinks/Promotions Bypass', url: 'https://app.freeusdcoin.com' },
        { name: 'CF Free-tron - Shortlinks/Promotions Bypass', url: 'https://app.free-tron.com' },
        { name: 'CF Freesteam - Shortlinks/Promotions Bypass', url: 'https://app.freesteam.io' },
        { name: 'CF Freeneo - Shortlinks/Promotions Bypass', url: 'https://app.freeneo.io' },
        { name: 'CF Free-ltc - Shortlinks/Promotions Bypass', url: 'https://app.free-ltc.com' },
        { name: 'CF Freecryptom - Shortlinks/Promotions Bypass', url: 'https://app.freecryptom.com' }
    ];

    var faucetpayurls = [
        "https://baltoniearn.com/claim/tron/",
        "https://vptron.online/TRX/",
        "https://claimcoins.site/reward/tron/",
        "https://claimcoins.site/reward/doge/",
        "https://claimcoins.site/reward/litecoin/",
        "https://claimcoins.site/reward/binance/",
        "https://claimcoins.site/reward/ripple/",
        "https://claimcoins.site/reward/bitcoin/",
        "https://bnbminers.site/earns/tron/",
        "https://bnbminers.site/earns/litecoin/",
        "https://bnbminers.site/earns/feyorra/",
        "https://bnbminers.site/earns/binance/",
        "https://bnbminers.site/earns/ripple/",
        "https://bnbminers.site/earns/ethereum/",
        "https://bnbminers.site/earns/bitcoin/",
        "https://ltcmines.site/earns/tron/",
        "https://ltcmines.site/earns/doge/",
        "https://ltcmines.site/earns/litecoin/",
        "https://ltcmines.site/earns/binance/",
        "https://ltcmines.site/earns/ripple/",
        "https://ltcmines.site/earns/ethereum/",
        "https://ltcmines.site/earns/bitcoin/",
        "https://tronxminer.com/rewards/tron/",
        "https://tronxminer.com/rewards/doge/",
        "https://tronxminer.com/rewards/feyorra/",
        "https://tronxminer.com/rewards/binance/",
        "https://tronxminer.com/rewards/ripple/",
        "https://tronxminer.com/rewards/bitcoin/",
        "https://cryptoclaps.com/earn/dogecoin/",
        "https://cryptoclaps.com/earn/tron/",
        "https://cryptoclaps.com/earn/litecoin/",
        "https://cryptoclaps.com/earn/binance/",
        "https://cryptoclaps.com/earn/solana/",
        "https://cryptoclaps.com/earn/ethereum/",
        "https://cryptoclaps.com/earn/bch/",
        "https://cryptoclaps.com/earn/xrp/",
        "https://cryptoclaps.com/earn/dash/",
        "https://cryptoclaps.com/earn/polygon/",
        "https://cryptoclaps.com/earn/usdt/",
        "https://cryptoclaps.com/earn/zcash/",
        "https://sollcrypto.com/home/page/bitcoin/",
        "https://sollcrypto.com/home/page/doge/",
        "https://sollcrypto.com/home/page/tron/",
        "https://sollcrypto.com/home/page/digibyte/",
        "https://sollcrypto.com/home/page/litecoin/",
        "https://sollcrypto.com/home/page/binance/",
        "https://sollcrypto.com/home/page/solana/",
        "https://sollcrypto.com/home/page/ethereum/",
        "https://sollcrypto.com/home/page/bch/",
        "https://sollcrypto.com/home/page/xrp/",
        "https://sollcrypto.com/home/page/dash/",
        "https://sollcrypto.com/home/page/zcash/",
    ];

    var storedUrls = GM_getValue('storedUrls', []) || [];

    function createButton(id, text, content) {
        var button = document.createElement('button');
        button.id = id;
        button.className = 'overlay-button';
        button.innerHTML = text;
        button.addEventListener('click', function() {
            var overlay = document.getElementById('overlay');
            overlay.style.display = 'block';
            var overlayContent = document.getElementById('overlay-content');
            overlayContent.innerHTML = content;
        });
        document.body.appendChild(button);
    }

    createButton('advertisementButton', 'Advertisement', '<h2>Advertisement</h2><p>Explore more earning opportunities from script developer on <a href="https://coinfinity.top/downloads.php" target="_blank">Coinfinity.top</a></p>');

    createButton('faucetMonitorButton', 'Faucet Monitor', '<h2>Faucet Monitor</h2><p>Faucet Monitor content goes here</p>');

    function showFaucetMonitorTable() {
        var tableContent = '<h2>Faucet Monitor</h2><table><tr><th>Connect</th><th>Name</th><th>Active</th></tr>';

        urls.forEach(function(item) {
            var isActive = GM_getValue(item.url, false);
            tableContent += '<tr><td><a href="' + item.url + '" target="_blank">Connect</a></td><td>' + item.name + '</td><td><input type="checkbox" id="active-' + item.url + '"' + (isActive ? ' checked' : '') + '></td></tr>';
        });

        tableContent += '</table>';

        var overlay = document.getElementById('overlay');
        overlay.style.display = 'block';
        var overlayContent = document.getElementById('overlay-content');
        overlayContent.innerHTML = tableContent;

        urls.forEach(function(item) {
            var checkbox = document.getElementById('active-' + item.url);
            checkbox.addEventListener('change', function() {
                GM_setValue(item.url, checkbox.checked);
            });
        });
    }

    document.getElementById('faucetMonitorButton').addEventListener('click', showFaucetMonitorTable);

    createButton('faucetpayRotatorButton', 'Faucetpay Rotator', '<h2>Faucetpay Rotator</h2><p>Faucetpay Rotator content goes here</p>');

    function showFaucetpayUrlsTable() {
        var tableContent = '<h2>Faucetpay Rotator</h2><table><tr><th>Connect</th><th>URL</th><th>Deactivated Until</th><th>Reason</th><th>Reset Time</th></tr>';

        faucetpayurls.forEach(function(url) {
            var storedUrlInfo = storedUrls.find(function(storedUrl) {
                return storedUrl.url === url;
            });

            var connectLink = '<a href="' + url + '" target="_blank">Connect</a>';
            var time = 'N/A';
            var reason = 'N/A';
            var resetTimeLink = '';

            if (storedUrlInfo && new Date(storedUrlInfo.timestamp) > new Date()) {
                time = storedUrlInfo.timestamp;
                reason = storedUrlInfo.reason;
                resetTimeLink = '<a href="#" onclick="resetStoredUrl(\'' + url + '\')">Reset</a>';
            }

            tableContent += '<tr><td>' + connectLink + '</td><td>' + url + '</td><td>' + time + '</td><td>' + reason + '</td><td>' + resetTimeLink + '</td></tr>';
        });

        tableContent += '</table>';

        tableContent += '<button id="resetAllUrlsButton" onclick="resetAllStoredUrls()">Reset All URLs</button>';

        var overlay = document.getElementById('overlay');
        overlay.style.display = 'block';
        var overlayContent = document.getElementById('overlay-content');
        overlayContent.innerHTML = tableContent;
    }

    unsafeWindow.resetStoredUrl = function(url) {
        var storedUrls = GM_getValue('storedUrls', []);
        var indexToRemove = storedUrls.findIndex(function(item) {
            return item.url === url;
        });

        if (indexToRemove !== -1) {
            storedUrls.splice(indexToRemove, 1);
            GM_setValue('storedUrls', storedUrls);
            alert('URL entry reset successfully!');
            showFaucetpayUrlsTable();
        } else {
            alert('URL entry not found!');
        }
    };

    unsafeWindow.resetAllStoredUrls = function () {
        var confirmation = confirm('Are you sure you want to reset all stored URLs?');
        if (confirmation) {
            GM_deleteValue('storedUrls');
            alert('All stored URLs reset successfully!');
            showFaucetpayUrlsTable();
        }
    };

    document.getElementById('faucetpayRotatorButton').addEventListener('click', showFaucetpayUrlsTable);

    // Create Settings button
    createButton('settingsButton', 'Settings', `
 <h2>Settings</h2>
<p>For full automation you need to install this additional scripts and save your Faucetpay Email</p>
<ul>
    <li><b>HCaptcha + ReCaptcha:</b> NoCoding Data Scraper and CAPTCHA Solver - <a href="https://chromewebstore.google.com/search/minirpa.net" target="_blank">Install Here</a></li>
    <li><b>Antibot Words:</b> AB Links Solver - <a href="https://greasyfork.org/de/scripts/459453-ab-links-solver" target="_blank">Install Here</a></li>
</ul>
<label for="faucetpayEmail">Enter <a href="https://faucetpay.io/?r=2922788" target="_blank">Faucetpay</a> Email:</label>
<input type="text" id="faucetpayEmail" placeholder="Enter your Faucetpay Email">
<button onclick="saveFaucetpayEmail()">Save</button>
<h3>Update Coin Addresses</h3>
<label for="coinBTC">Bitcoin (BTC):</label>
<input type="text" id="coinBTC" placeholder="Enter BTC Address"><br>

<label for="coinETH">Ethereum (ETH):</label>
<input type="text" id="coinETH" placeholder="Enter ETH Address"><br>

<label for="coinADA">Cardano (ADA):</label>
<input type="text" id="coinADA" placeholder="Enter ADA Address"><br>

<label for="coinSOL">Solana (SOL):</label>
<input type="text" id="coinSOL" placeholder="Enter SOL Address"><br>

<label for="coinBNB">Binance Coin (BNB):</label>
<input type="text" id="coinBNB" placeholder="Enter BNB Address"><br>

<label for="coinXRP">Ripple (XRP):</label>
<input type="text" id="coinXRP" placeholder="Enter XRP Address"><br>

<label for="coinUSDT">Tether TRC20 (USDT):</label>
<input type="text" id="coinUSDT" placeholder="Enter USDT Address"><br>

<label for="coinDOGE">Dogecoin (DOGE):</label>
<input type="text" id="coinDOGE" placeholder="Enter DOGE Address"><br>

<label for="coinLTC">Litecoin (LTC):</label>
<input type="text" id="coinLTC" placeholder="Enter LTC Address"><br>

<label for="coinBCH">Bitcoin Cash (BCH):</label>
<input type="text" id="coinBCH" placeholder="Enter BCH Address"><br>

<label for="coinTRX">Tron (TRX):</label>
<input type="text" id="coinTRX" placeholder="Enter TRX Address"><br>

<label for="coinDGB">DigiByte (DGB):</label>
<input type="text" id="coinDGB" placeholder="Enter DGB Address"><br>

<label for="coinDASH">Dash (DASH):</label>
<input type="text" id="coinDASH" placeholder="Enter DASH Address"><br>

<label for="coinZEC">Zcash (ZEC):</label>
<input type="text" id="coinZEC" placeholder="Enter ZEC Address"><br>

<label for="coinMATIC">Polygon (MATIC):</label>
<input type="text" id="coinMATIC" placeholder="Enter MATIC Address"><br>

<label for="coinFEY">Feyorra (FEY):</label>
<input type="text" id="coinFEY" placeholder="Enter FEY Address"><br>

<button onclick="saveCoinAddresses()">Save</button>
`);

    unsafeWindow.saveCoinAddresses = function () {
        var coinAddresses = {
            BTC: document.getElementById('coinBTC').value,
            ETH: document.getElementById('coinETH').value,
            ADA: document.getElementById('coinADA').value,
            SOL: document.getElementById('coinSOL').value,
            BNB: document.getElementById('coinBNB').value,
            XRP: document.getElementById('coinXRP').value,
            USDT: document.getElementById('coinUSDT').value,
            DOGE: document.getElementById('coinDOGE').value,
            LTC: document.getElementById('coinLTC').value,
            BCH: document.getElementById('coinBCH').value,
            TRX: document.getElementById('coinTRX').value,
            DGB: document.getElementById('coinDGB').value,
            DASH: document.getElementById('coinDASH').value,
            ZEC: document.getElementById('coinZEC').value,
            MATIC: document.getElementById('coinMATIC').value,
            FEY: document.getElementById('coinFEY').value
        };
        GM_setValue('coinAddresses', coinAddresses);
        alert('Coin Addresses saved successfully!');
    };

    document.getElementById('settingsButton').addEventListener('click', function() {
        // Retrieve Faucetpay Email and pre-fill the input field
        var savedFaucetpayEmail = GM_getValue('faucetpayEmail', '');
        var faucetpayEmailInput = document.getElementById('faucetpayEmail');
        if (savedFaucetpayEmail !== '' && faucetpayEmailInput !== null) {
            faucetpayEmailInput.value = savedFaucetpayEmail;
        }

        // Retrieve saved coin addresses and pre-fill the input fields
        var savedCoinAddresses = GM_getValue('coinAddresses', {});
        document.getElementById('coinBTC').value = savedCoinAddresses.BTC || '';
        document.getElementById('coinETH').value = savedCoinAddresses.ETH || '';
        document.getElementById('coinADA').value = savedCoinAddresses.ADA || '';
        document.getElementById('coinSOL').value = savedCoinAddresses.SOL || '';
        document.getElementById('coinBNB').value = savedCoinAddresses.BNB || '';
        document.getElementById('coinXRP').value = savedCoinAddresses.XRP || '';
        document.getElementById('coinUSDT').value = savedCoinAddresses.USDT || '';
        document.getElementById('coinDOGE').value = savedCoinAddresses.DOGE || '';
        document.getElementById('coinLTC').value = savedCoinAddresses.LTC || '';
        document.getElementById('coinBCH').value = savedCoinAddresses.BCH || '';
        document.getElementById('coinTRX').value = savedCoinAddresses.TRX || '';
        document.getElementById('coinDGB').value = savedCoinAddresses.DGB || '';
        document.getElementById('coinDASH').value = savedCoinAddresses.DASH || '';
        document.getElementById('coinZEC').value = savedCoinAddresses.ZEC || '';
        document.getElementById('coinMATIC').value = savedCoinAddresses.MATIC || '';
        document.getElementById('coinFEY').value = savedCoinAddresses.FEY || '';
    });


    createButton('aboutButton', 'About', `
        <h2>About Faucet Monitor with Faucetpay Rotator</h2>
        <p>Faucet Monitor with Faucetpay Rotator is a sophisticated tool meticulously crafted to streamline faucet management and rotation processes for cryptocurrency enthusiasts.</p>
        <p>Key Features:</p>
        <ul>
            <li><b>Faucet Management:</b> Effortlessly manage and monitor multiple faucets and rotator sites from a unified interface.</li>
            <li><b>Rotator Functionality:</b> Access a curated list of Faucetpay rotator sites, enabling seamless rotation and utilization of various faucets.</li>
            <li><b>Customization:</b> Activate or deactivate specific faucets based on your preferences, offering unparalleled flexibility and control over your faucet experience.</li>
            <li><b>Requirements Overview:</b> Gain insights into optimal faucet usage requirements, including CAPTCHA solutions and antibot measures.</li>
            <li><b>Save Preferences:</b> Store your Faucetpay email address for seamless integration and management of faucet rewards.</li>
            <li><b>Advertisement Section:</b> Explore additional earning opportunities through featured advertisements and offers.</li>
            <li><b>About Section:</b> Learn more about the Faucet Monitor tool and its developer, Andrewblood, through the informative About section.</li>
        </ul>
        <p>Experience enhanced efficiency and convenience in your cryptocurrency faucet endeavors with Faucet Monitor with Faucetpay Rotator.</p>

        <h2>About the Scripts:</h2>
        <ul>
            <li><strong>Auto-Reload Script:</strong> This script periodically checks various URLs on specific websites to determine if certain conditions are met, such as having sufficient funds or reaching the daily claim limit. If conditions are met, it automatically reloads the page and saves the respective URLs and timestamps for later use.</li>
            <li><strong>Freebitco Script:</strong> This script automates certain actions on the Freebitco.in website, including rolling, checking for bonuses, and other tasks to earn reward points.</li>
            <li><strong>Dutchycorp Script:</strong> This script automates various actions on the Dutchycorp Autofaucet website, including rolling, checking captchas, and other tasks to earn rewards.</li>
            <li><strong>CFfaucets Script:</strong> This script automates redirection to various faucet websites and performs some actions to earn rewards.</li>
        </ul>
    `);

    window.addEventListener('click', function(event) {
        var overlay = document.getElementById('overlay');
        if (event.target == overlay) {
            overlay.style.display = 'none';
        }
    });

    var overlay = document.createElement('div');
    overlay.id = 'overlay';
    var overlayContent = document.createElement('div');
    overlayContent.id = 'overlay-content';
    overlay.appendChild(overlayContent);
    document.body.appendChild(overlay);



    var currentURL = new URL(window.location.href).origin;

    // Freebitco.in
    if (GM_getValue(currentURL) && window.location.href.includes("freebitco.in")) {
        function isCaptchaChecked() {
            return hcaptcha && hcaptcha.getResponse().length !== 0;
        }

        if(window.location.href.includes("https://freebitco.in/signup/?op=s")) {
            if(window.location.href != ("https://freebitco.in/signup/?op=s&r=3595810")) {
                window.location.replace("https://freebitco.in/signup/?op=s&r=3595810");
            }
        }


        if(window.location.href === ("https://freebitco.in/") || window.location.href === ("https://freebitco.in/?op=home") || window.location.href === ("https://freebitco.in/#")) {
            setTimeout(function() {

                // click WoF
                if (document.querySelector("#free_wof_spins_msg") && document.querySelector("#free_wof_spins_msg").innerText.includes("Play them here")){
                    console.log("Make the WoF Spins.");
                    window.open('https://freebitco.in/static/html/wof/wof-premium.html', '_blank');
                }


                if (document.querySelector("#free_play_form_button").style.display == "none"){
                    console.log("Wait for next Roll.");
                    setTimeout(function() {
                        window.close();
                    }, 1000*30);
                }
                else
                {
                    console.log("Let's look for Bonus");
                    document.querySelector("body > div.large-12.fixed > div > nav > section > ul > li:nth-child(8) > a").click();
                    document.querySelector("#rewards_tab > div.row.reward_category_container_main_div > div > div:nth-child(4) > div.reward_category_name").click();
                    setTimeout(function() {
                        var yourrwp = parseFloat(document.querySelector("#rewards_tab > div:nth-child(2) > div > div.reward_table_box.br_0_0_5_5.user_reward_points.font_bold").innerText.replace(/,/, ''))
                        console.log("Your current Reward Points are:");
                        console.log(yourrwp);
                        var bonuscost = parseFloat(document.querySelector("#fp_bonus_rewards > div:nth-child(2) > div:nth-child(2) > div.large-6.small-12.columns > div").innerText.replace(/,/, ''))
                        console.log("The Price for 1000% BTC-Bonus is:");
                        console.log(bonuscost);
                        if (yourrwp > bonuscost){
                            document.querySelector("#fp_bonus_rewards > div:nth-child(2) > div:nth-child(2) > div:nth-child(3) > button").click();
                        }
                        else
                        {
                            console.log("Your balance is too low to buy.");
                        }
                        document.querySelector("#free_play_link_li > a").click();
                    }, 1000*5);

                    // Make the Roll
                    setTimeout(function() {
                        if (document.querySelector("#anchor")){
                            console.log("Wait for Captcha and.....");

                            if (isCaptchaChecked()) {
                                document.querySelector("#free_play_form_button").click();
                                setTimeout(function() {
                                    window.close();
                                }, 1000*30);
                            }
                        }
                        else
                        {
                            document.querySelector("#free_play_form_button").click();
                            setTimeout(function() {
                                window.close();
                            }, 1000*10);
                        }
                    }, 1000*10);
                }
            }, 1000*5);
        }

        if (window.location.href.includes("https://freebitco.in/static/html/wof/wof-premium.html")) {
            setTimeout(function() {
                document.querySelector("#wofc-section > div > div.wofc-spins > p > button:nth-child(2)").click();
            }, 1000*10);
            setTimeout(function() {
                window.close();
            }, 1000*30);
        }
    }

    // Dutchycorp
    if (GM_getValue(currentURL) && window.location.href.includes("dutchycorp")) {
        function isCaptchaChecked() {
            return grecaptcha && grecaptcha.getResponse().length !== 0;
        }

        function visibleCheck(elm) {
            if (!elm.offsetHeight && !elm.offsetWidth) { return false; }
            if (getComputedStyle(elm).visibility === 'hidden') { return false; }
            return true;
        }

        if (window.location.href == "https://autofaucet.dutchycorp.space/signup.php") {
            if (window.location.href != "https://autofaucet.dutchycorp.space/signup.php?r=Andrewblood&s=Script") {
                window.location.replace("https://autofaucet.dutchycorp.space/signup.php?r=Andrewblood&s=Script");
            }
        }

        if (window.location.href.indexOf('login') === -1 && window.location.href.indexOf('register') === -1) {

            var isRecaptchaEnabled = GM_getValue('recaptchaStatus');

            if (isRecaptchaEnabled) {
                runScript();
            } else {
                if (window.location.href !== 'https://autofaucet.dutchycorp.space/account.php') {
                    window.location.href = 'https://autofaucet.dutchycorp.space/account.php';
                } else {
                    document.querySelector("#methods > form > font > form:nth-child(16) > div > input").click();
                    var selectElement = document.querySelector('select[name="captcha"]');

                    if (selectElement) {
                        var options = selectElement.options;
                        for (var i = 0; i < options.length; i++) {
                            if (options[i].value === '3') {
                                options[i].selected = true;
                                var event = new Event('change');
                                selectElement.dispatchEvent(event);
                                break;
                            }
                        }
                    }
                    var updateButton = document.querySelector('button[name="change-captcha"]');
                    updateButton.click();

                    GM_setValue('recaptchaStatus', 'enabled');
                }
            }

            function runScript() {
                setTimeout(function(){
                    location.reload();
                }, 180000);

                if (window.location.href.includes("https://autofaucet.dutchycorp.space/account.php")) {
                    window.location.replace("https://autofaucet.dutchycorp.space/dashboard.php");
                }

                if (window.location.href == "https://autofaucet.dutchycorp.space/dashboard.php") {
                    window.location.replace("https://autofaucet.dutchycorp.space/roll.php");
                }

                if (window.location.href.includes("https://autofaucet.dutchycorp.space/roll.php")) {
                    if (!document.querySelector("#timer")) {
                        setInterval(function() {
                            if (isCaptchaChecked()) {
                                if (document.querySelector(".boost-btn.unlockbutton")) {
                                    document.querySelector(".boost-btn.unlockbutton").click();
                                }
                                if (visibleCheck(document.querySelector("#claim_boosted"))) {
                                    document.querySelector("#claim_boosted").click();
                                }
                            }
                        }, 5000);
                    } else {
                        setTimeout(function() {
                            window.location.replace("https://autofaucet.dutchycorp.space/coin_roll.php");
                        }, 5000);
                    }
                }

                if (window.location.href.includes("https://autofaucet.dutchycorp.space/coin_roll.php")) {
                    if (!document.querySelector("#timer")) {
                        setInterval(function() {
                            if (isCaptchaChecked()) {
                                if (document.querySelector(".boost-btn.unlockbutton")) {
                                    document.querySelector(".boost-btn.unlockbutton").click();
                                }
                                if (visibleCheck(document.querySelector("#claim_boosted"))) {
                                    document.querySelector("#claim_boosted").click();
                                }
                            }
                        }, 5000);
                    } else {
                        setTimeout(function() {
                            window.location.replace("https://autofaucet.dutchycorp.space/ptc/wall.php");
                        }, 5000);
                    }
                }

                if (window.location.href.includes("https://autofaucet.dutchycorp.space/ptc/wall.php")) {
                    var wallLink = document.querySelectorAll(".col.s10.m6.l4 a[name='claim']");
                    if (wallLink.length >= 1) {
                        wallLink[0].style.backgroundColor = "red";
                        let match = wallLink[0].onmousedown.toString().match(/'href', '(.+)'/);
                        let hrefValue = match[1];
                        setTimeout(function() {
                            window.location.replace("https://autofaucet.dutchycorp.space" + hrefValue);
                        }, 5000);
                    } else {
                        setTimeout(function() {
                            window.location.replace("https://autofaucet.dutchycorp.space/ptc/");
                        }, 5000);
                    }
                }

                if (window.location.href.includes("https://autofaucet.dutchycorp.space/ptc/view")) {
                    setInterval(function() {
                        if (document.querySelector("#sec").innerText === 'Payout in  0 seconds') {
                            document.getElementsByClassName("g-recaptcha bordeaux-btn btn-small waves-effect waves-red")[0].click();
                            setTimeout(function() {
                                console.log("Wait for Captcha");
                            }, 30000);
                        } else {
                            console.log("Wait on timer.");
                        }
                    }, 5000);
                }

                if (window.location.href == "https://autofaucet.dutchycorp.space/ptc/") {
                    setInterval(function() {
                        if (document.querySelector("body > div.col.s12 > div.row > div.col.s12.m12.l10 > center:nth-child(1) > h4")) {
                            if (document.querySelector("body > div.col.s12 > div.row > div.col.s12.m12.l10 > center:nth-child(1) > h4").innerText == ' All Available Ads Watched') {
                                window.close();
                            }
                        } else if (visibleCheck(document.getElementsByClassName("g-recaptcha gradient-btn btn-small waves-effect waves-purple")[0])) {
                            document.getElementsByClassName("g-recaptcha gradient-btn btn-small waves-effect waves-purple")[0].click();

                        } else {
                            console.log("Wait on timer.");
                        }
                    }, 5000);
                }
            }
        }
    }


    // CF Faucets
    if (GM_getValue(currentURL) && (window.location.href.includes("freebitcoin") ||
                                    window.location.href.includes("freebinancecoin") ||
                                    window.location.href.includes("free-doge") ||
                                    window.location.href.includes("freeusdcoin") ||
                                    window.location.href.includes("freecryptom") ||
                                    window.location.href.includes("free-ltc") ||
                                    window.location.href.includes("freedash") ||
                                    window.location.href.includes("freeneo") ||
                                    window.location.href.includes("freecardano") ||
                                    window.location.href.includes("freebfg") ||
                                    window.location.href.includes("freepancake") ||
                                    window.location.href.includes("freebittorrent") ||
                                    window.location.href.includes("coinfaucet") ||
                                    window.location.href.includes("freematic") ||
                                    window.location.href.includes("freetether") ||
                                    window.location.href.includes("freesteam") ||
                                    window.location.href.includes("freenem") ||
                                    window.location.href.includes("freeshibainu") ||
                                    window.location.href.includes("free-tron") ||
                                    window.location.href.includes("freeethereum"))) {

        if(window.location.href == ("https://freebitcoin.io/")){
            if(window.location.href != ("https://freebitcoin.io/?ref=804096")){
                window.location.replace("https://freebitcoin.io/?ref=804096")
            }
        }
        if(window.location.href == ("https://freebinancecoin.com/")){
            if(window.location.href != ("https://freebinancecoin.com/?ref=418938")){
                window.location.replace("https://freebinancecoin.com/?ref=418938")
            }
        }
        if(window.location.href === ("https://free-doge.com/")){
            if(window.location.href !== ("https://free-doge.com/?ref=334834")){
                window.location.replace("https://free-doge.com/?ref=334834")
            }
        }
        if(window.location.href == ("https://freeusdcoin.com/")){
            if(window.location.href != ("https://freeusdcoin.com/?ref=237334")){
                window.location.replace("https://freeusdcoin.com/?ref=237334")
            }
        }
        if(window.location.href == ("https://freecryptom.com/")){
            if(window.location.href != ("https://freecryptom.com/?ref=145077")){
                window.location.replace("https://freecryptom.com/?ref=145077")
            }
        }
        if(window.location.href == ("https://free-ltc.com/")){
            if(window.location.href != ("https://free-ltc.com/?ref=278353")){
                window.location.replace("https://free-ltc.com/?ref=278353")
            }
        }
        if(window.location.href == ("https://freedash.io/")){
            if(window.location.href != ("https://freedash.io/?ref=241665")){
                window.location.replace("https://freedash.io/?ref=241665")
            }
        }
        if(window.location.href == ("https://freeneo.io/")){
            if(window.location.href != ("https://freeneo.io/?ref=172683")){
                window.location.replace("https://freeneo.io/?ref=172683")
            }
        }
        if(window.location.href == ("https://freecardano.com/")){
            if(window.location.href != ("https://freecardano.com/?ref=495783")){
                window.location.replace("https://freecardano.com/?ref=495783")
            }
        }
        if(window.location.href == ("https://freebfg.com/")){
            if(window.location.href != ("https://freebfg.com/?ref=34816")){
                window.location.replace("https://freebfg.com/?ref=34816")
            }
        }
        if(window.location.href == ("https://freepancake.com/")){
            if(window.location.href != ("https://freepancake.com/?ref=63758")){
                window.location.replace("https://freepancake.com/?ref=63758")
            }
        }
        if(window.location.href == ("https://freebittorrent.com/")){
            if(window.location.href != ("https://freebittorrent.com/?ref=33463")){
                window.location.replace("https://freebittorrent.com/?ref=33463")
            }
        }
        if(window.location.href == ("https://coinfaucet.io/")){
            if(window.location.href != ("https://coinfaucet.io/?ref=966105")){
                window.location.replace("https://coinfaucet.io/?ref=966105")
            }
        }
        if(window.location.href == ("https://freematic.com/")){
            if(window.location.href != ("https://freematic.com/?ref=102515")){
                window.location.replace("https://freematic.com/?ref=102515")
            }
        }
        if(window.location.href == ("https://freetether.com/")){
            if(window.location.href != ("https://freetether.com/?ref=353801")){
                window.location.replace("https://freetether.com/?ref=353801")
            }
        }
        if(window.location.href == ("https://freesteam.io/")){
            if(window.location.href != ("https://freesteam.io/?ref=190554")){
                window.location.replace("https://freesteam.io/?ref=190554")
            }
        }
        if(window.location.href == ("https://freenem.com/")){
            if(window.location.href != ("https://freenem.com/?ref=367461")){
                window.location.replace("https://freenem.com/?ref=367461")
            }
        }
        if(window.location.href == ("https://freeshibainu.com/")){
            if(window.location.href != ("https://freeshibainu.com/?ref=206136")){
                window.location.replace("https://freeshibainu.com/?ref=206136")
            }
        }
        if(window.location.href == ("https://free-tron.com/")){
            if(window.location.href != ("https://free-tron.com/?ref=526291")){
                window.location.replace("https://free-tron.com/?ref=526291")
            }
        }
        if(window.location.href == ("https://freeethereum.com/")){
            if(window.location.href != ("https://freeethereum.com/?ref=430971")){
                window.location.replace("https://freeethereum.com/?ref=430971")
            }
        }

        setInterval(function() {
            if (window.location.href.includes("free-rolls")) {
                setTimeout(function(){
                    window.location.replace("promotion/csw1td1eqp");
                }, 5000);
            }
        }, 1000);

        if (window.location.href.includes("csw1td1eqp")){
            setTimeout(function() {
                document.location.reload();
            }, 120000);
            setInterval(function(){
                if (document.querySelector("#__nuxt > div > div > main > div > div > div.p-message.p-component.p-message-error.my-8 > div") || document.querySelector("#__nuxt > div > div > main > div > div > div.p-message.p-component.p-message-success.my-8 > div"))
                {
                    window.location.replace("q5rlm6ot3r")
                }
                else
                {
                    console.log("Captcha is not solved yet, next check in 3 seconds.");
                }
            }, 3000)
        }

        if (window.location.href.includes("q5rlm6ot3r")){
            setTimeout(function() {
                document.location.reload();
            }, 120000);
            setInterval(function(){
                if (document.querySelector("#__nuxt > div > div > main > div > div > div.p-message.p-component.p-message-error.my-8 > div") || document.querySelector("#__nuxt > div > div > main > div > div > div.p-message.p-component.p-message-success.my-8 > div"))
                {
                    window.location.replace("ki2r0jq5r0")
                }
                else
                {
                    console.log("Captcha is not solved yet, next check in 3 seconds.");
                }
            }, 3000)
        }

        if (window.location.href.includes("ki2r0jq5r0")){
            setTimeout(function() {
                document.location.reload();
            }, 120000);
            setInterval(function(){
                if (document.querySelector("#__nuxt > div > div > main > div > div > div.p-message.p-component.p-message-error.my-8 > div") || document.querySelector("#__nuxt > div > div > main > div > div > div.p-message.p-component.p-message-success.my-8 > div"))
                {
                    window.location.replace("n6kr3x7p5u")
                }
                else
                {
                    console.log("Captcha is not solved yet, next check in 3 seconds.");
                }
            }, 3000)
        }

        if (window.location.href.includes("n6kr3x7p5u")){
            setTimeout(function() {
                document.location.reload();
            }, 120000);
            setInterval(function(){
                if (document.querySelector("#__nuxt > div > div > main > div > div > div.p-message.p-component.p-message-error.my-8 > div") || document.querySelector("#__nuxt > div > div > main > div > div > div.p-message.p-component.p-message-success.my-8 > div"))
                {
                    window.location.replace("5g57e0vksm")
                }
                else
                {
                    console.log("Captcha is not solved yet, next check in 3 seconds.");
                }
            }, 3000)
        }

        if (window.location.href.includes("5g57e0vksm")){
            setTimeout(function() {
                document.location.reload();
            }, 120000);
            setInterval(function(){
                if (document.querySelector("#__nuxt > div > div > main > div > div > div.p-message.p-component.p-message-error.my-8 > div") || document.querySelector("#__nuxt > div > div > main > div > div > div.p-message.p-component.p-message-success.my-8 > div"))
                {
                    window.close()
                }
                else
                {
                    console.log("Captcha is not solved yet, next check in 3 seconds.");
                }
            }, 3000)
        }
    }

    // Rollercoin
    if (GM_getValue(currentURL) && window.location.href.includes("rollercoin")) {
        var button = document.createElement('button');
        button.innerHTML = 'Show Saved Marketplace Products';

        GM_addStyle(`
        .show-saved-products-button {
            position: fixed;
            bottom: 10px;
            left: 250px;
            z-index: 9999;
            padding: 5px 10px;
            background-color: #007bff;
            color: #fff;
            border: none;
            border-radius: 5px;
            cursor: pointer;
            font-size: 12px;
        }

        .rollercoinoverlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background-color: rgba(0, 0, 0, 0.5);
            z-index: 9998;
            display: none;
            color: black;
        }

        .rollercoinoverlay-content {
            position: absolute;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            background-color: #fff;
            padding: 20px;
            border-radius: 5px;
            color: black;
        }
        .saved-products-table {
            width: 100%;
            border-collapse: collapse;
        }
        .saved-products-table th, .saved-products-table td {
            border: 1px solid #ddd;
            padding: 8px;
            text-align: left;
        }
        .saved-products-table th {
            background-color: #f2f2f2;
        }
    `);

        button.classList.add('show-saved-products-button');

        document.body.appendChild(button);

        var rollercoinoverlay = document.createElement('div');
        rollercoinoverlay.classList.add('rollercoinoverlay');
        var rollercoinoverlayContent = document.createElement('div');
        rollercoinoverlayContent.classList.add('rollercoinoverlay-content');
        rollercoinoverlay.appendChild(rollercoinoverlayContent);
        document.body.appendChild(rollercoinoverlay);

        button.addEventListener('click', function() {
            updateOverlayContent();
            rollercoinoverlay.style.display = 'block';
        });

        rollercoinoverlay.addEventListener('click', function() {
            rollercoinoverlay.style.display = 'none';
        });

        function updateOverlayContent() {
            var savedProducts = GM_listValues().map(function(key) {
                return {url: key, data: GM_getValue(key)};
            });

            var tableHTML = '<h2>Saved Marketplace Products</h2><table class="saved-products-table">';
            tableHTML += '<tr><th>Connect</th><th>Product Name</th><th>Saved Buy Price</th></tr>';

            savedProducts.forEach(function(product) {
                if (product.url.includes("rollercoin.com/marketplace/buy")) {
                    tableHTML += '<tr>';
                    tableHTML += '<td><a href="' + product.url + '">Connect</a></td>';
                    tableHTML += '<td>' + product.data.itemText + '</td>';
                    tableHTML += '<td>' + product.data.buyPrice + ' RLT</td>';
                    tableHTML += '</tr>';
                }
            });

            tableHTML += '</table>';

            rollercoinoverlayContent.innerHTML = tableHTML;
        }

        if (window.location.href === "https://rollercoin.com/") {
            window.location.replace("https://rollercoin.com/?r=llfv26zk");
        }

        if (window.location.href.includes("https://rollercoin.com/sign-up")) {
            if (window.location.href !== "https://rollercoin.com/sign-up?r=llfv26zk") {
                window.location.replace("https://rollercoin.com/sign-up?r=llfv26zk");
            }
        }

        let overlayCreated = false;
        let itemPrice = '';

        function createOverlay() {
            if (overlayCreated) return;

            GM_addStyle(`
            #customOverlay {
                position: fixed;
                bottom: 50px;
                left: 20px;
                width: 350px;
                background-color: rgba(255, 255, 255, 0.9);
                border: 1px solid #ccc;
                z-index: 9999;
                padding: 5px;
                overflow: auto;
                text-align: left;
            }
            #customOverlay h2 {
                font-size: 20px;
                color: black;
                text-align: center;
            }
            #customOverlay table {
                width: 100%;
            }
            #customOverlay table tr {
                border-bottom: 1px solid #ccc;
            }
            #customOverlay table tr:last-child {
                border-bottom: none;
            }
            #customOverlay table td {
                padding: 8px;
                font-size: 16px;
                color: black;
            }
            #customOverlay p {
                font-size: 16px;
                color: black;
                margin: 5px 0;
                text-align: center;
            }
            #customOverlay input {
                width: 80%;
                margin: 0 auto;
                display: block;
            }
            #customOverlay button {
                width: 80%;
                margin: 10px auto;
                display: block;
                padding: 8px;
                border-radius: 4px;
                cursor: pointer;
            }
            #startButton {
                background-color: #4CAF50;
                color: white;
                border: none;
            }
            #stopButton {
                background-color: #f44336;
                color: white;
                border: none;
            }
        `);

            const currentURL = window.location.href;
            const savedData = GM_getValue(currentURL);

            const overlay = document.createElement('div');
            overlay.id = 'customOverlay';
            overlay.innerHTML = `
            <h2>Marketplace buyer</h2>
            <table>
                <tr>
                    <td>Product Name</td>
                    <td id="itemText"></td>
                </tr>
                <tr>
                    <td>Current Buy Price</td>
                    <td id="itemPrice"></td>
                </tr>
                <tr>
                    <td>Saved Buy Price</td>
                    <td id="buyPriceDisplay">${savedData ? savedData.buyPrice + ' RLT' : 'Not Saved'}</td>
                </tr>
            </table>
            <input type="text" id="buyPriceInput" placeholder="Enter New Buy Price">
            <button id="saveButton">Save</button>
            <button id="startButton">Start Automatic Buy</button>
            <button id="stopButton" style="display: none;">Stop Automatic Buy</button>
        `;
            document.body.appendChild(overlay);

            overlayCreated = true;

            const buyPriceInput = document.getElementById('buyPriceInput');
            buyPriceInput.addEventListener('click', function (event) {
                if (buyPriceInput.value === '' && itemPrice) {
                    const cleanItemPrice = itemPrice.replace(" RLT", "");
                    buyPriceInput.value = cleanItemPrice;
                }
            });

            const saveButton = document.getElementById('saveButton');
            saveButton.addEventListener('click', function (event) {
                const itemText = document.getElementById('itemText').textContent;
                const buyPrice = document.getElementById('buyPriceInput').value;

                let savedData = GM_getValue(currentURL);

                if (savedData) {
                    savedData.buyPrice = buyPrice;
                    GM_setValue(currentURL, savedData);
                    alert(`Buy Price updated for URL: ${currentURL}\nItem Text: ${itemText}\nNew Buy Price: ${buyPrice} RLT`);
                    window.location.reload()
                } else {
                    savedData = { itemText, buyPrice };
                    GM_setValue(currentURL, savedData);
                    alert(`New data saved for URL: ${currentURL}\nItem Text: ${itemText}\nBuy Price: ${buyPrice} RLT`);
                    window.location.reload()
                }

                document.getElementById('buyPriceDisplay').textContent = buyPrice + ' RLT';
            });

            const startButton = document.getElementById('startButton');
            const stopButton = document.getElementById('stopButton');

            let buyPrice = '';
            let intervalId;

            if (savedData && savedData.intervalRunning) {
                startButton.style.display = 'none';
                stopButton.style.display = 'block';

                setTimeout(function() {
                    window.location.reload();
                }, 1000*60*5);

                intervalId = setInterval(checkPrice, 500);
            }

            startButton.addEventListener('click', function (event) {
                startButton.style.display = 'none';
                stopButton.style.display = 'block';

                setTimeout(function() {
                    window.location.reload();
                }, 1000*60*5);

                GM_setValue(currentURL, { ...savedData, intervalRunning: true });
                intervalId = setInterval(checkPrice, 500);
            });

            stopButton.addEventListener('click', function (event) {
                startButton.style.display = 'block';
                stopButton.style.display = 'none';

                GM_setValue(currentURL, { ...savedData, intervalRunning: false });
                clearInterval(intervalId);
            });

            function checkPrice() {
                const itemPriceElement = document.querySelector(".input-price-wrapper > p.item-price");
                const itemPrice = itemPriceElement ? parseFloat(itemPriceElement.innerText.replace(" RLT", "")) : 0;

                const currentURL = window.location.href;
                const savedData = GM_getValue(currentURL);
                const buyPrice = parseFloat(savedData.buyPrice);

                if (itemPrice === 0) return;

                if (buyPrice > itemPrice) {
                    document.querySelector(".item-info-buy-wrapper.col-12.col-lg-4 > button").click();

                    const intervalId = setInterval(function () {
                        const overlayButton = document.querySelector(".modal.fade.show > div > div > div > div > button.roller-button.default.cyan");
                        if (overlayButton && overlayButton.offsetParent !== null) {
                            overlayButton.click();
                            clearInterval(intervalId);
                            window.location.reload();
                        }
                    }, 500);
                }
            }
        }

        setInterval(function () {
            if (window.location.href.match(/^https?:\/\/[^/]+\/marketplace\/buy\//)) {
                createOverlay();

                const itemTitle = document.querySelector(".col-12.col-lg-9 > div > h4");
                const itemText = itemTitle ? itemTitle.innerText : '';
                const itemPriceElement = document.querySelector(".input-price-wrapper > p.item-price");
                itemPrice = itemPriceElement ? itemPriceElement.innerText : '';

                document.getElementById('itemText').textContent = itemText;
                document.getElementById('itemPrice').textContent = itemPrice;
            } else if (!window.location.href.match(/^https?:\/\/[^/]+\/marketplace\/buy\//) && overlayCreated) {
                const existingOverlay = document.getElementById('customOverlay');
                if (existingOverlay) {
                    const stopButton = document.querySelector("#stopButton");
                    if (stopButton.style.display === 'block') {
                        stopButton.click();
                    }
                    existingOverlay.remove();
                    overlayCreated = false;
                }
            }
        }, 500);
    }

    if (GM_getValue(currentURL) && window.location.href.includes("faucetpay")) {
        if (window.location.href === ("https://faucetpay.io/")){
            window.location.replace("https://faucetpay.io/?r=2922788");
        }


        // Create a button to trigger the script
        const buttonHTML = '<button id="startScriptButton">Save Wallet Addresses</button>';
        document.body.insertAdjacentHTML('beforeend', buttonHTML);

        // Add some basic styling to the button
        GM_addStyle(`
        #startScriptButton {
            position: fixed;
            bottom: 40px;
            left: calc(50% - 100px); /* Half the button width for centering */
            padding: 10px 20px;
            background-color: #007bff;
            color: #fff;
            border: none;
            border-radius: 5px;
            cursor: pointer;
            z-index: 9999;
        }
    `);

        function startAddressCollection() {
            const tableRows = document.querySelectorAll('.style_rowWrapper__3zn_i');

            const storedAddresses = GM_getValue('coinAddresses') || {};

            tableRows.forEach(row => {
                const coinName = row.querySelector('span:nth-child(3) img').alt;
                const walletAddress = row.querySelector('span:nth-child(2)').textContent.trim();

                if (!storedAddresses.hasOwnProperty(coinName)) {
                    storedAddresses[coinName] = [walletAddress];
                } else {
                    if (!Array.isArray(storedAddresses[coinName])) {
                        storedAddresses[coinName] = [];
                    }

                    if (!storedAddresses[coinName].includes(walletAddress)) {
                        storedAddresses[coinName].push(walletAddress);
                    }
                }
            });

            // Save updated addresses
            GM_setValue('coinAddresses', storedAddresses);

            // Display updated addresses in console
            console.log('Addresses saved:\n', storedAddresses);
        }

        // Add event listener to the button
        document.getElementById('startScriptButton').addEventListener('click', startAddressCollection);




        function clickUserDashboardLink() {
            var userDashboardLink = document.querySelector('a[href="/page/user-admin"]');

            if (userDashboardLink && userDashboardLink.offsetParent !== null) {
                userDashboardLink.click();
                clearInterval(checkInterval1);
            }
        }

        var checkInterval1 = setInterval(clickUserDashboardLink, 3000);
    }



    var currentPageUrl = window.location.href

    if (faucetpayurls.includes(currentPageUrl) || window.location.href.includes("[email protected]")) {
        function isElementVisible(selector) {
            var element = document.querySelector(selector);
            return element && element.offsetWidth > 0 && element.offsetHeight > 0;
        }

        function clickButton(selector) {
            var button = document.querySelector(selector);
            if (button) {
                button.click();
            }
        }

        setTimeout(function () {
            location.reload();
        }, 120000);

        var indexOfRParameter = currentPageUrl.indexOf("?r=");
        if (indexOfRParameter !== -1) {
            currentPageUrl = currentPageUrl.substring(0, indexOfRParameter);
        }

        var selector1 = ".alert.alert-danger.fade.show";
        if (isElementVisible(selector1) && document.querySelector(selector1)?.innerText === ' The faucet does not have sufficient funds for this transaction.') {
            var reason1 = 'sufficient funds';
            var timestamp1 = new Date(new Date().getTime() + 6 * 60 * 60 * 1000).toISOString().slice(0, 19).replace('T', ' ');
            saveUrl(currentPageUrl, timestamp1, reason1);
        }

        var selector2 = ".alert.alert-danger.fade.show";
        if (isElementVisible(selector2) && document.querySelector(selector2)?.innerText === ' Your daily claim limit has been reached. Please come back in tomorrow.') {
            var reason2 = 'daily claim limit';
            var timestamp2 = new Date(new Date().getTime() + 12 * 60 * 60 * 1000).toISOString().slice(0, 19).replace('T', ' ');
            //            var tomorrow = new Date();
            //            tomorrow.setDate(tomorrow.getDate() + 1);
            //            tomorrow.setHours(2, 0, 0, 0);
            //            var timestamp2 = tomorrow.toISOString().slice(0, 19).replace('T', ' ');
            saveUrl(currentPageUrl, timestamp2, reason2);
        }

        function saveUrl(url, timestamp, reason) {
            var urlWithTimestamp = { url: url, timestamp: timestamp, reason: reason };

            var existingUrlIndex = storedUrls.findIndex(function (storedUrl) {
                return storedUrl.url === url;
            });

            if (existingUrlIndex !== -1) {
                storedUrls[existingUrlIndex].timestamp = timestamp;
                storedUrls[existingUrlIndex].reason = reason;
            } else {
                storedUrls.push(urlWithTimestamp);
            }

            GM_setValue('storedUrls', storedUrls);
        }

        if ((isElementVisible(".alert.alert-success.fade.show") &&
             document.querySelector(".alert.alert-success.fade.show").innerText.includes('satoshi')) ||
            (isElementVisible(".alert.alert-danger.fade.show") &&
             document.querySelector(".alert.alert-danger.fade.show").innerText === ' The faucet does not have sufficient funds for this transaction.') ||
            (isElementVisible(".alert.alert-danger.fade.show") &&
             document.querySelector(".alert.alert-danger.fade.show").innerText === ' Session invalid, try again') ||
            (isElementVisible(".alert.alert-danger.fade.show") &&
             document.querySelector(".alert.alert-danger.fade.show").innerText.includes('wait')) ||
            (isElementVisible(".alert.alert-danger.fade.show") &&
             document.querySelector(".alert.alert-danger.fade.show").innerText === ' Your daily claim limit has been reached. Please come back in tomorrow.')) {
            function checkAndConnectNextUrl() {
                var currentUrl = window.location.href.includes('?r=') ? window.location.href.split('?r=')[0] : window.location.href;

                console.log("Current URL:", currentUrl);

                var currentIndex = faucetpayurls.indexOf(currentUrl);

                console.log("Current Index:", currentIndex);

                var validUrlFound = false;

                for (var i = currentIndex + 1; i < currentIndex + faucetpayurls.length; i++) {
                    var nextUrl = faucetpayurls[i % faucetpayurls.length];

                    console.log("Checking next URL:", nextUrl);

                    var storedUrlInfo = storedUrls.find(function (storedUrl) {
                        return storedUrl.url === nextUrl;
                    });

                    console.log("Stored URL Info:", storedUrlInfo);

                    if (!storedUrlInfo || new Date() > new Date(storedUrlInfo.timestamp)) {
                        console.log("Connecting to the next valid URL:", nextUrl);

                        window.location.href = nextUrl;

                        validUrlFound = true;

                        break;
                    }
                }

                if (!validUrlFound) {
                    alert("All sites are empty or daily limit reached. Please start the script tomorrow again. You can also change the Faucetpay E-Mail and set all a new time Active");
                }
            }

            checkAndConnectNextUrl();
        } else {
            var currentURL = window.location.href;
            var referralCode = '[email protected]';

            if (!currentURL.includes(referralCode)) {
                currentURL += referralCode;
                window.location.href = currentURL;
            } else {
                var faucetpayEmailInput = document.querySelector("#address");
                if (faucetpayEmailInput) {
                    var storedEmail = GM_getValue('faucetpayEmail', '');
                    faucetpayEmailInput.value = storedEmail;

                    var loginbutton = document.querySelectorAll('button[data-target="#captchaModal"]');
                    loginbutton[0].click();

                    if (document.querySelector("#captchaModal").innerText.includes('AntiBot links')) {
                        var intervalId = setInterval(function() {
                            var antibotLinksValue = document.querySelector("#antibotlinks").value.length;
                            var recaptchaResponseValue = document.querySelector("#g-recaptcha-response").value.length;

                            if (antibotLinksValue > 1 && recaptchaResponseValue > 1) {
                                clearInterval(intervalId);

                                clickButton("#login");
                            }
                        }, 1000);
                    } else {
                        var intervalId2 = setInterval(function() {
                            var recaptchaResponseValue = document.querySelector("#g-recaptcha-response").value.length;

                            if (recaptchaResponseValue > 1) {
                                clearInterval(intervalId2);

                                clickButton("#login");
                            }
                        }, 1000);
                    }
                }

            }
        }
    }


    if (window.location.href.includes("solnetwork")) {
        if (window.location.href === "https://solnetwork.fun/") {
            window.location.href = "https://solnetwork.fun/ref/52489";
        }
        if (window.location.href.includes("dashboard")) {
            if (document.querySelector("body > div.container-fluid.mt-5 > div > div.col-md-6.text-center > div:nth-child(1) > div > div:nth-child(2) > div").innerText.includes('sufficient funds')){
                function checkAndConnectNextUrl() {
                    var currentUrl = document.referrer;

                    console.log("Current URL:", currentUrl);

                    var currentIndex = faucetpayurls.indexOf(currentUrl);

                    console.log("Current Index:", currentIndex);

                    var validUrlFound = false;

                    for (var i = currentIndex + 1; i < currentIndex + faucetpayurls.length; i++) {
                        var nextUrl = faucetpayurls[i % faucetpayurls.length];

                        console.log("Checking next URL:", nextUrl);

                        var storedUrlInfo = storedUrls.find(function (storedUrl) {
                            return storedUrl.url === nextUrl;
                        });

                        console.log("Stored URL Info:", storedUrlInfo);

                        if (!storedUrlInfo || new Date() > new Date(storedUrlInfo.timestamp)) {
                            console.log("Connecting to the next valid URL:", nextUrl);

                            window.location.href = nextUrl;

                            validUrlFound = true;

                            break;
                        }
                    }

                    if (!validUrlFound) {
                        alert("All sites are empty or daily limit reached. Please start the script tomorrow again. You can also change the Faucetpay E-Mail and set all a new time Active");
                    }
                }

                checkAndConnectNextUrl();
            } else {
                window.location.href = "https://solnetwork.fun/faucet-sol"
            }

        }

        // Aktionen, wenn die URL "https://solnetwork.fun/faucet-sol" ist
        if (window.location.href.includes("https://solnetwork.fun/faucet-sol")) {
            // Klicken auf den ersten Button
            document.querySelector("body > div.container-fluid.mt-5 > div > div.col-md-6.text-center > div:nth-child(1) > div > div:nth-child(4) > div > table > tbody > tr:nth-child(3) > td > button").click();

            // Überprüfung und Klick für den zweiten Button und Turnstile
            var checkAndClick = setInterval(function() {
                // Überprüfen, ob der zweite Button sichtbar ist
                var secondButton = document.querySelector("#claimButton");
                var turnstile = document.querySelector('[name="cf-turnstile-response"]');

                if (secondButton && turnstile) {
                    // Wenn der zweite Button und der Turnstile sichtbar sind
                    // Überprüfen, ob der Turnstile-Wert größer als 1 ist
                    if (turnstile.value.length > 1) {
                        // Klicken auf den zweiten Button
                        secondButton.click();
                        clearInterval(checkAndClick); // Stoppen der Überprüfung
                    }
                } else {
                    // Wenn der zweite Button oder der Turnstile noch nicht sichtbar sind
                    // Wiederholen des Klicks auf den ersten Button
                    document.querySelector("body > div.container-fluid.mt-5 > div > div.col-md-6.text-center > div:nth-child(1) > div > div:nth-child(4) > div > table > tbody > tr:nth-child(3) > td > button").click();
                }
            }, 1000); // Überprüfung alle 1000 Millisekunden (1 Sekunde)
        }
    }

})();