Civitai Ultra Fast Auto Clicker

초고속 Civitai 자동 클릭 스크립트 (5초 이내 완료)

目前為 2024-10-23 提交的版本,檢視 最新版本

// ==UserScript==
// @name         Civitai Ultra Fast Auto Clicker
// @namespace    http://tampermonkey.net/
// @version      1.2
// @description  초고속 Civitai 자동 클릭 스크립트 (5초 이내 완료)
// @author       Your Name
// @match        https://civitai.com/images
// @grant        none
// ==/UserScript==

(function() {
    'use strict';

    window.addEventListener('load', function() {
        const panel = document.querySelector('#main > div > div > footer > div.relative.flex.h-\\[var\\(--footer-height\\)\\].w-full.items-center.gap-2.overflow-x-auto.bg-gray-0.p-1.px-2.\\@sm\\:gap-3.dark\\:bg-dark-7.border-t.border-gray-3.dark\\:border-dark-4 > div.mantine-Group-root.mantine-1msv4yg');

        if (panel) {
            const newButton = document.createElement('button');
            newButton.innerText = '터보 클릭';
            newButton.style.cssText = `
                padding: 5px 10px;
                background-color: #ff0000;
                color: white;
                border: none;
                border-radius: 4px;
                cursor: pointer;
                font-size: 12px;
                font-weight: bold;
            `;

            const rapidClickAllButtons = () => {
                const buttons = Array.from(document.querySelectorAll('button'))
                    .filter(button => button.closest('div.absolute.inset-x-1.bottom-1.flex.items-center.justify-between.gap-1'));

                buttons.forEach(button => {
                    try {
                        button.click();
                    } catch (error) {
                        // 에러 무시하고 계속 진행
                    }
                });
            };

            const turboScrollAndClick = async () => {
                const totalDuration = 4000; // 총 실행 시간 4초
                const scrollInterval = 200; // 0.2초마다 스크롤
                const startTime = Date.now();

                while (Date.now() - startTime < totalDuration) {
                    rapidClickAllButtons();

                    // 빠른 스크롤
                    window.scrollBy({
                        top: window.innerHeight,
                        behavior: 'auto'
                    });

                    // 최소한의 대기 시간
                    await new Promise(resolve => setTimeout(resolve, scrollInterval));
                }
            };

            let isProcessing = false;

            newButton.addEventListener('click', async function() {
                if (isProcessing) return;
                isProcessing = true;

                const startTime = Date.now();

                try {
                    await turboScrollAndClick();

                    const executionTime = Date.now() - startTime;
                    console.log(`실행 시간: ${executionTime}ms`);

                    // 4.5초 후 새로고침 (총 5초 이내 완료 보장)
                    if (executionTime < 4500) {
                        setTimeout(() => {
                            location.reload();
                        }, 4500 - executionTime);
                    } else {
                        location.reload();
                    }
                } catch (error) {
                    console.error('Error:', error);
                } finally {
                    isProcessing = false;
                }
            });

            panel.style.display = 'flex';
            panel.style.justifyContent = 'center';
            panel.appendChild(newButton);
        }
    });
})();

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址