Submit for MB_Solver

Sending the form after solving the captcha

You will need to install an extension such as Tampermonkey, Greasemonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install an extension such as Tampermonkey or Violentmonkey to install this script.

You will need to install an extension such as Tampermonkey or Userscripts to install this script.

You will need to install an extension such as Tampermonkey to install this script.

You will need to install a user script manager extension to install this script.

(I already have a user script manager, let me install it!)

Advertisement:

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(I already have a user style manager, let me install it!)

Advertisement:

// ==UserScript==
// @name         Submit for MB_Solver
// @namespace    Violentmonkey Scripts
// @version      1.4
// @description  Sending the form after solving the captcha
// @author       MultiBot
// @match        *://*/*
// @grant        none
// ==/UserScript==
(function() {
	'use strict';
	function _Search_Captcha(){
		let done_captcha = false;
		if (document.querySelector('input#antibotlinks') && !document.querySelector('input#antibotlinks').value){
			return false;
		}
		if (window.grecaptcha && window.grecaptcha.getResponse()){
			done_captcha = true;
		}
		if (typeof window.hcaptcha=="object" && window.hcaptcha.getResponse()){
			done_captcha = true;
		}
		if (typeof window.ACPuzzleInfo=="object" && document.querySelector("#adcopy_response").value){
			done_captcha = true;
		}
		if(done_captcha){
			return true;
		}
	}
	function _Search_Selector(query,action){
		if (document.querySelector(query)) {
			var timer = setInterval(function() {
				if (_Search_Captcha()) {
					document.querySelector(query)[action](); clearInterval(timer);
				}
			}, 5000);
		}
	}
	if(document.querySelector('span#clock')){
		var timer = setInterval(function() {
			if (Number(document.querySelector('span#clock').innerText.replace(/[^1-9]+/g,''))==0) {
				location.reload(); clearInterval(timer);
			}
		}, 5000);
	}
	let arr_modal = ['[data-target="#claim"]'];
	for(let key of arr_modal){
		if (document.querySelector(key)){
			document.querySelector(key).click();
			break;
		}
	}
	let arr_form = ['form[action*="/faucet/verify"]','form[action*="/firewall/verify"]','form[action*="/auth/login"]'];
	for(let key of arr_form){
		_Search_Selector(key,'submit');
	}
    let arr_click = ['.btn-success[type="submit"]'];
	for(let key of arr_click){
		_Search_Selector(key,'click');
	}
})();