Cryptoads.in Auto Faucet Rotator

Auto login + rotator faucet + deteksi limit harian Cryptoads.in

目前為 2025-08-06 提交的版本,檢視 最新版本

在您安裝前,Greasy Fork希望您了解本腳本包含“負面功能”,可能幫助腳本的作者獲利,而不能給你帶來任何收益。

作者從這份腳本獲得佣金, 例如透過重寫連結或提供優惠券代碼以加入推薦或附屬代碼 腳本的作者解釋: Directs to a referral link when not logged in

您需要先安裝使用者腳本管理器擴展,如 TampermonkeyGreasemonkeyViolentmonkey 之後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyViolentmonkey 後才能安裝該腳本。

您需要先安裝使用者腳本管理器擴充功能,如 TampermonkeyUserscripts 後才能安裝該腳本。

你需要先安裝一款使用者腳本管理器擴展,比如 Tampermonkey,才能安裝此腳本

您需要先安裝使用者腳本管理器擴充功能後才能安裝該腳本。

(我已經安裝了使用者腳本管理器,讓我安裝!)

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展,比如 Stylus,才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

你需要先安裝一款使用者樣式管理器擴展後才能安裝此樣式

(我已經安裝了使用者樣式管理器,讓我安裝!)

// ==UserScript==
// @name                Cryptoads.in Auto Faucet Rotator
// @namespace           Violentmonkey Scripts
// @match               https://cryptoads.in/*
// @version             0.2
// @grant               GM_getValue
// @grant               GM_setValue
// @grant               GM_addStyle
// @grant               GM_registerMenuCommand
// @require             https://cdn.jsdelivr.net/npm/sweetalert2@11
// @require             https://update.greasyfork.org/scripts/439099/1203718/MonkeyConfig%20Modern%20Reloaded.js
// @description         Auto login + rotator faucet + deteksi limit harian Cryptoads.in
// @author              OjoNgono
// @license             Copyright OjoNgono
// @antifeature         referral-link Directs to a referral link when not logged in
// @icon                https://i.ibb.co/XJSPdz0/large.png
// ==/UserScript==

(function () {
  'use strict';

  // Konfigurasi 
  const cfg = new MonkeyConfig({
    title: 'Pengaturan Cryptoads',
    menuCommand: 'Buka Pengaturan',
    params: {
      Email: {
        label: "Email FaucetPay",
        type: "text",
        default: ""
      }
    }
  });

  const email = cfg.get('Email');
  const REFERRAL = 'https://cryptoads.in/?r=158';

  // Cek 
  function isLoggedIn() {
    return !document.querySelector('header a.btn.btn-accent[href="/"]');
  }

  // Isi 
  function fillLoginForm(email) {
    const form = document.querySelector('form.user');
    if (!form) return;
    const input = form.querySelector('input[name="wallet"]');
    const submit = form.querySelector('button[type="submit"]');
    if (input) input.value = email;
    if (submit) {
      const checker = setInterval(() => {
        if (document.querySelector('.iconcaptcha-widget.iconcaptcha-success')) {
          submit.click();
          clearInterval(checker);
        }
      }, 1000);
    }
  }

  // Cek 
  function checkLoginReferral() {
    const loggedIn = isLoggedIn();
    if (loggedIn && (!email || email === '')) {
      Swal.fire({
        icon: 'warning',
        title: 'Email FaucetPay belum diisi!',
        confirmButtonText: 'Ya, logout',
      }).then(() => window.location.href = "https://cryptoads.in/logout");
      return;
    }
    if (!loggedIn && (!email || email === '')) {
      Swal.fire({
        icon: 'info',
        title: 'Isi Email FaucetPay di Pengaturan Userscript',
        confirmButtonText: 'OK',
      });
      return;
    }
    if (!loggedIn && !window.location.href.includes("?r=")) {
      window.location.href = REFERRAL;
    } else if (!loggedIn && email) {
      fillLoginForm(email);
    }
  }

  // Daftar
  const urls = [
    "https://cryptoads.in/faucet/currency/doge",
    "https://cryptoads.in/faucet/currency/ltc",
    "https://cryptoads.in/faucet/currency/sol",
    "https://cryptoads.in/faucet/currency/trx"
  ];

  // Deteksi
  function checkDailyLimitReached() {
    const alertBox = document.querySelector('.alert.alert-danger.text-center');
    if (alertBox && alertBox.textContent.includes("Daily claim limit for this coin reached")) {
      const currentUrl = window.location.href;
      const lastFaucetUrl = urls[urls.length - 1];

      if (currentUrl === lastFaucetUrl) {
        console.log("🔁 Limit terakhir tercapai. Pindah ke /links/currency/trx");
        window.location.href = "https://cryptoads.in/links/currency/trx";
      } else {
        console.log("🔁 Limit tercapai. Pindah ke dashboard untuk rotasi berikutnya");
        window.location.href = "https://cryptoads.in/dashboard";
      }
    }
  }

  // Fungsi 
  function rotateUrls() {
    const loggedIn = isLoggedIn();
    const onDashboard = window.location.pathname === "/dashboard";

    if (loggedIn && onDashboard) {
      let currentIndex = parseInt(localStorage.getItem('currentIndex')) || 0;
      const targetUrl = urls[currentIndex];

      console.log(`🔁 Rotating to: ${targetUrl}`);
      localStorage.setItem('currentIndex', (currentIndex + 1) % urls.length);
      window.location.href = targetUrl;
    } else {
      console.log("⏳ Menunggu di dashboard untuk rotator...");
    }
  }

  // Auto 
  let claimClicked = false;

  function clickClaimFaucet() {
    if (claimClicked) return;

    const btn = document.getElementById('subbutt');
    const isCaptchaSolved = document.querySelector('.iconcaptcha-widget.iconcaptcha-success');

    if (btn && isCaptchaSolved && !btn.disabled) {
      console.log("✅ Captcha selesai. Klik tombol claim...");
      btn.click();
      claimClicked = true;
    }

    const goClaim = [...document.querySelectorAll("a.btn")].find(a => a.textContent.toLowerCase().includes("go claim"));
    if (goClaim) goClaim.click();
  }

  // Inisialisasi 
  window.addEventListener('load', () => {
  checkLoginReferral();

  setTimeout(() => {
    checkDailyLimitReached();
    rotateUrls();
  }, 1500);

  setInterval(clickClaimFaucet, 1000);

  ShortlinkClaim(); 
    autoClickSubbuttAfterCaptcha(); 
});
})();

    function ShortlinkClaim() {
  // Deteksi 
  if (!window.location.pathname.startsWith("/links/currency/")) return;

  const interval = setInterval(() => {
    const buttons = document.querySelectorAll('a.btn');

    for (const btn of buttons) {
      const text = btn.innerText.trim().toLowerCase();

      if (/claim\s[1-5]\/5/i.test(text)) {
        console.log(`🔍 Menemukan tombol: ${text}`);
        btn.scrollIntoView({ behavior: 'smooth', block: 'center' });

        if (!btn.disabled && btn.offsetParent !== null) {
          console.log("✅ Klik tombol klaim sekarang...");
          clearInterval(interval);
          setTimeout(() => {
            btn.click();
          }, 1000);
        }
        return;
      }
    }
  }, 1000);
}

function autoClickSubbuttAfterCaptcha() {
  const path = window.location.pathname;
  const regex = /^\/links\/check\/2\/[a-zA-Z]+$/;

  if (!regex.test(path)) return; // Hanya jalan di /links/check/2/coin

  console.log("🔍 Memeriksa captcha dan tombol #subbutt...");

  const interval = setInterval(() => {
    const isCaptchaSolved = document.querySelector('.iconcaptcha-widget.iconcaptcha-success');
    const subbutt = document.getElementById('subbutt');

    if (isCaptchaSolved && subbutt && !subbutt.disabled) {
      console.log("✅ Captcha selesai. Mengklik tombol #subbutt...");
      subbutt.scrollIntoView({ behavior: 'smooth', block: 'center' });
      subbutt.click();
      clearInterval(interval);
    }
  }, 1000);
}