w1w23qw

cryptoclaimhub.com

Mar 8th, 2025 (edited)
56
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. // ==UserScript==
  2. // @name          Cryptoclaimhub.com + countdowntimer
  3. // @namespace     Violentmonkey & Tampermonkey Scripts
  4. // @match         https://cryptoclaimhub.com/*
  5. // @grant         none
  6. // @version       0.3
  7. // @author        Ojo Ngono
  8. // @description   Автоматический переход от крана к короткой ссылке
  9. // @license       Copyright OjoNgono
  10. // @downloadURL https://update.greasyfork.org/scripts/508988/Cryptoclaimhubcom.user.js
  11. // @updateURL https://update.greasyfork.org/scripts/508988/Cryptoclaimhubcom.meta.js
  12. // ==/UserScript==
  13.  
  14. (function() {
  15.     'use strict';
  16. class WorkerInterval {
  17.   worker = null;
  18.   constructor(callback, interval) {
  19.     const blob = new Blob([`setInterval(() => postMessage(0), ${interval});`]);
  20.     const workerScript = URL.createObjectURL(blob);
  21.     this.worker = new Worker(workerScript);
  22.     this.worker.onmessage = callback;
  23.   }
  24.  
  25.   stop() {
  26.     this.worker.terminate();
  27.   }
  28. }
  29.     var CaptchaSolverStatus = document.createElement('div');
  30.     document.body.appendChild(CaptchaSolverStatus);
  31.  
  32.     CaptchaSolverStatus.classList.add('captchasolver-status');
  33.     document.body.appendChild(document.createElement('style')).textContent = (`
  34.                 .captchasolver-status {
  35.                 position: fixed;
  36.                 font-size: 20px !important;
  37.                 top: 140px !important;
  38.                 right: 20px;
  39.                 z-index: 9999;
  40.                 pointer-events: none;
  41.                 }
  42.                 `);
  43.  
  44.     function setCaptchaSolverStatus(html, color) {
  45.         if (color === 'green') {
  46.             CaptchaSolverStatus.style.color = 'green';
  47.         } else if (color === 'red') {
  48.             CaptchaSolverStatus.style.color = 'red';
  49.         } else {
  50.             CaptchaSolverStatus.style.color = 'black';
  51.         }
  52.         CaptchaSolverStatus.innerHTML = html;
  53.     }
  54.  
  55.     setCaptchaSolverStatus('<p><b>Captcha Solver:</b> Console </p><br />', 'red');
  56. //===================================
  57. var finish = document.querySelector("body > div.wrapper > div > main > div > div:nth-child(7) > div > div > div > h4")
  58.     if(finish && finish.textContent == 'You have met the daily limit.')window.location.href='https://cryptoclaimhub.com/home';
  59.     if (window.location.href === "https://cryptoclaimhub.com/ads") {
  60.         let viewButton = document.querySelector('button.btn.btn-primary.view-ad-btn');
  61.         if (viewButton) {
  62.             viewButton.click();
  63.         } else {
  64.             window.location.href = "https://cryptoclaimhub.com/shortlinks";
  65.         }
  66.     }
  67.  
  68.     function checkTurnstile() {
  69.         let turnstileResponse = document.querySelector('input[name="cf-turnstile-response"]');
  70.         if (window.location.href === 'https://cryptoclaimhub.com/faucet'){
  71.         document.querySelector('input[name="cf-turnstile-response"]').value='0.OolNkVEb2SiZgvzqJ-4vHQa3DNXwWIjHdEXG3UGImm1bCywjeNz13mXLzumh29hp1d7UPhMAD6nbZ03_WtGiCdjwNzrfuIuHTC2RbvNmRmHjjd_PdEMrMNmljhqqg3__LX7SaTHpSPBNW1dyDifd5pUoFeYi7nnondQ-gZuHRpU1M507N_Qp6rFzUnqnKxg9CYGKpWq2CUUIWTgD5wba4rykjVBwsaI_wFnPXF09ZSifn-NntfzLrkFgeHd7r7eGtEi-JoRjV0i9T6gYFBGH9TtSfk3g7KsIAx4b1kOyD45ks454ics3FW3cvI4DMUoPazw0gDnl_f8q_oC5jLfZz9cpcNoWN7s0MtFpQ3ZyqEX3zwgG91vLyXR56qrjh8HKyw6YEZDjwlfncSr_fOfKIvGqquLedOus3DHBA8FR45IkTRIz1AUzcjr6-mSiQtP9DS_R39RGl6ps_Eo9yuWW-w5Kg1V120qMIE6Fj8-8piDBR5EFWt67WI3ompkKKHZMy6aSkvdFkf1ciypt6el6NBXWmoPHn1mBu7VwjbcW_8xgmPygW4jVTe_xzZzXjqj7n-jyp4bQND6ocMZo_7j01UoIYTOMMlT1Y47NO9DZdZMvFaHlY1t_w5YM4z8oyZhIMyRBNeZyhJQ5C_RDxmZsKYkXyo9FfHHjGDeq4o_vaTvm05botsaHsOtisQ7F5BTnDHvqIhTq5PZdP57Vv16xXJax_Z_QXaGAN8tsggbB93-fXwscPCwHzZdgWl2agqgCieO97Ih_IHgt30G1dYwbNRnYQ9xQ47MZe6iIT91ApEmDDU0bCV3ldItjnItnpTc9xMYiSWPYdY5lQzH1ON02sw.9stX8PSEu8qLIJfFI5PVSQ.c1dce84bdf6da8b6ffaba91bb319c3f8934d67fcbd69b128aaede26b65eb8b89'
  72.         }
  73.         return turnstileResponse && turnstileResponse.value !== '';
  74.     }
  75.  
  76.     function scrollToMiddle() {
  77.         let middleY = document.body.scrollHeight / 2;
  78.         window.scrollTo({
  79.             top: middleY,
  80.             behavior: 'smooth'
  81.         });
  82.     }
  83.  
  84.     if (window.location.href === 'https://cryptoclaimhub.com/faucet') {
  85.         scrollToMiddle();
  86.     }
  87.  
  88.     function isModalVisible() {
  89.         let modal = document.querySelector('.modal-dialog.modal-dialog-centered.modal-sm.my-custom-modal');
  90.         return modal && modal.offsetParent !== null;
  91.     }
  92.  
  93.     function clickConfirmButton() {
  94.         let confirmButton = document.querySelector('button.btn.btn-primary[type="submit"]');
  95.         if (confirmButton) {
  96.         setTimeout(function() {
  97.             confirmButton.click();
  98.         }, 5000);
  99.             return true;
  100.         }
  101.         return false;
  102.     }
  103.  
  104.     let confirmInterval = new WorkerInterval(function() {
  105.         if (checkTurnstile() && isModalVisible()) {
  106.             if (clickConfirmButton()) {
  107.                 confirmInterval.stop();
  108.             }
  109.         }
  110.     }, 1000);
  111.  
  112.   setTimeout(function() {
  113.         if (!checkTurnstile() && isModalVisible()) {
  114.             clickConfirmButton();
  115.         }
  116.     }, 15000);
  117.  
  118.  
  119.         function clickButtonByStep(stepText) {
  120.     let claimButton = document.querySelector('#claimButton');
  121.  
  122.     if (claimButton) {
  123.  
  124.         if (new RegExp(stepText + '\\s\\d+/\\d+').test(claimButton.textContent)) {
  125.             claimButton.click(); // Пытаюсь нажать на кнопку
  126.             return true;
  127.         }
  128.     }
  129.  
  130.     return false;
  131. }
  132.  
  133. function isIconSelected() {
  134.     let selectedIcon = document.querySelector('.stat.selected');
  135.     if (selectedIcon) {
  136.         console.log("Значок был выбран.");
  137.         return true;
  138.     } else {
  139.         console.log("Мы не будим выбирать ничего.");
  140.         return true;
  141.     }
  142. }
  143.  
  144. function clickButtonByStepText(stepText) {
  145.     let claimButton = document.querySelector("button.step-button-class");
  146.  
  147.     if (claimButton) {
  148.         if (new RegExp(stepText + '\\s\\d+/\\d+').test(claimButton.textContent)) {
  149.             console.log("Кнопки в соответствии с рисунком, попробуйте нажать...");
  150.             claimButton.click();
  151.             return true;
  152.         } else {
  153.             console.log("Пуговицы не подходят к выкройке: " + claimButton.textContent);
  154.         }
  155.     } else {
  156.         console.log("Кнопка не найдена.");
  157.     }
  158.  
  159.     return false;
  160. }
  161.  
  162. let actionInterval = new WorkerInterval(function() {
  163.     if (checkTurnstile() && isIconSelected()) {
  164.         let buttonClicked = clickButtonByStep('Step');
  165.         if (buttonClicked) {
  166.             actionInterval.stop();
  167.         }
  168.         else {
  169.             let confirmButton = document.querySelector("button.btn.btn-primary[type='submit']");
  170.             if (confirmButton) {
  171.                 confirmButton.click();
  172.                 actionInterval.stop();
  173.             } else {
  174.             }
  175.         }
  176.     }
  177. }, 1000);
  178.  
  179.  
  180.  
  181.  
  182.     const buttons = [
  183.         'https://cryptoclaimhub.com/shortlinks/go/20',
  184.         'https://cryptoclaimhub.com/shortlinks/go/31',
  185.         'https://cryptoclaimhub.com/shortlinks/go/1',
  186.         'https://cryptoclaimhub.com/shortlinks/go/8',
  187.         'https://cryptoclaimhub.com/shortlinks/go/2',
  188.         'https://cryptoclaimhub.com/shortlinks/go/15',
  189.         'https://cryptoclaimhub.com/shortlinks/go/16',
  190.         'https://cryptoclaimhub.com/shortlinks/go/22'
  191.     ];
  192.     let currentIndex = 0;
  193.  
  194.     function clickNextButton() {
  195.         if (currentIndex < buttons.length) {
  196.             let claimButton = document.querySelector(`a.btn.btn-primary[href="${buttons[currentIndex]}"]`);
  197.             if (claimButton) {
  198.                 claimButton.click();
  199.                 currentIndex++;
  200.                 setTimeout(clickNextButton, 5000);
  201.             } else {
  202.                 currentIndex++;
  203.                 setTimeout(clickNextButton, 1000);
  204.             }
  205.         }
  206.     }
  207.  
  208.     //clickNextButton();
  209.  
  210.     function startCountdown() {
  211.         const countdownTime = 10 * 60 * 1000;
  212.         const endTime = Date.now() + countdownTime;
  213.         localStorage.setItem('countdownEndTime', endTime);
  214.         let countdownInterval = new WorkerInterval(function() {
  215.             const remainingTime = endTime - Date.now();
  216.             if (remainingTime <= 0) {
  217.                 countdownInterval.stop();
  218.                 window.location.href = "https://cryptoclaimhub.com/faucet";
  219.             }
  220.         }, 1000);
  221.     }
  222.  
  223.     function continueCountdown() {
  224.         const endTime = localStorage.getItem('countdownEndTime');
  225.         if (endTime && Date.now() < endTime) {
  226.             const countdownInterval = new WorkerInterval(function() {
  227.                 const newRemainingTime = endTime - Date.now();
  228.         var minutes = parseInt(newRemainingTime / 60000, 10);
  229.         var seconds = parseInt(newRemainingTime/1000 % 60, 10);
  230.  
  231.         minutes = minutes < 10 ? "0" + minutes : minutes;
  232.         seconds = seconds < 10 ? "0" + seconds : seconds;
  233.  
  234.         document.querySelector("body > div.captchasolver-status").innerHTML = minutes + ":" + seconds;
  235.                 if (newRemainingTime <= 0) {
  236.                     countdownInterval.stop();
  237.                     window.location.href = "https://cryptoclaimhub.com/faucet";
  238.                 }
  239.             }, 1000);
  240.         }
  241.     }
  242.  
  243.     function checkClock() {
  244.     let waitTimeElement = document.getElementById('waitTimeDisplay');
  245.  
  246.     if (waitTimeElement) {
  247.         let waitTimeText = waitTimeElement.innerText;
  248.  
  249.         if (waitTimeText.includes("55s")) {
  250.             startCountdown();
  251.             window.location.href = "https://cryptoclaimhub.com/ads";
  252.         }
  253.     }
  254. }
  255.  
  256.     const observer = new MutationObserver(function(mutations) {
  257.         mutations.forEach(function() {
  258.             checkClock();
  259.         });
  260.     });
  261.  
  262.     observer.observe(document.body, { childList: true, subtree: true });
  263.     checkClock();
  264.     continueCountdown();
  265. })();
  266.  
Add Comment
Please, Sign In to add comment