Scope Autshoot for Deadshot.io by NOOB

Adds auto shoot on scoping,better crosshair covering spray range,location detector,auto jumping while firing with realtime ping indicator with ui.Use "C" to enable or disable.

目前为 2024-11-23 提交的版本。查看 最新版本

// ==UserScript==
// @name         Scope Autshoot for Deadshot.io by NOOB
// @namespace    http://tampermonkey.net/
// @version      1.0
// @description  Adds auto shoot on scoping,better crosshair covering spray range,location detector,auto jumping while firing with realtime ping indicator with ui.Use "C" to enable or disable.
// @author       Noob Fr
// @match        https://deadshot.io/*
// @grant
// ==/UserScript==

//This script is prohibited for redevelopment or renaming.All rights owned by the original developer.Usage only allowed with original banners and ui.

(function () {
    'use strict';

    let featuresEnabled = true;
    let crosshairColor = 'green';
    let userCountry = 'Loading...';
    let kKeyInterval = null;
    let isRightMousePressed = false;

    const killNoobText = document.createElement('div');
    killNoobText.textContent = '[KILL] NOOB';
    killNoobText.style.position = 'fixed';
    killNoobText.style.top = '130px';
    killNoobText.style.left = '10px';
    killNoobText.style.fontSize = '50px';
    killNoobText.style.fontWeight = 'bold';
    killNoobText.style.color = 'red';
    killNoobText.style.textShadow = '2px 2px 5px black';
    killNoobText.style.zIndex = '9999';
    document.body.appendChild(killNoobText);

    const crosshair = document.createElement('div');
    crosshair.id = 'custom-crosshair';
    crosshair.style.position = 'fixed';
    crosshair.style.width = '50px';
    crosshair.style.height = '50px';
    crosshair.style.borderRadius = '50%';
    crosshair.style.border = '3px dashed ' + crosshairColor;
    crosshair.style.left = '50%';
    crosshair.style.top = '50%';
    crosshair.style.transform = 'translate(-50%, -50%)';
    crosshair.style.zIndex = '9999';
    document.body.appendChild(crosshair);

    const pingContainer = document.createElement('div');
    pingContainer.style.position = 'fixed';
    pingContainer.style.top = '200px';
    pingContainer.style.left = '10px';
    pingContainer.style.zIndex = '9999';

    const pingText = document.createElement('div');
    pingText.textContent = 'Ping Status:';
    pingText.style.fontSize = '18px';
    pingText.style.color = 'white';
    pingText.style.marginRight = '10px';
    pingContainer.appendChild(pingText);

    const pingBar = document.createElement('div');
    pingBar.style.width = '200px';
    pingBar.style.height = '20px';
    pingBar.style.border = '2px solid white';
    pingBar.style.backgroundColor = 'black';

    const pingFill = document.createElement('div');
    pingFill.style.width = '100%';
    pingFill.style.height = '100%';
    pingFill.style.backgroundColor = 'green';
    pingBar.appendChild(pingFill);
    pingContainer.appendChild(pingBar);
    document.body.appendChild(pingContainer);

    const countryContainer = document.createElement('div');
    countryContainer.style.position = 'fixed';
    countryContainer.style.top = '230px';
    countryContainer.style.left = '10px';
    countryContainer.style.fontSize = '18px';
    countryContainer.style.color = 'white';
    countryContainer.style.zIndex = '9999';
    countryContainer.textContent = `Current Region is ${userCountry}`;
    document.body.appendChild(countryContainer);

    function toggleFeatures(enabled) {
        killNoobText.style.display = enabled ? 'block' : 'none';
        crosshair.style.display = enabled ? 'block' : 'none';
        pingContainer.style.display = enabled ? 'flex' : 'none';
        countryContainer.style.display = enabled ? 'block' : 'none';

        if (!enabled) {
            stopKKeyPress();
            isRightMousePressed = false;
        }
    }

    function startKKeyPress() {
        if (!kKeyInterval) {
            kKeyInterval = setInterval(() => {
                const kKeyEvent = new KeyboardEvent('keydown', {
                    key: 'K',
                    code: 'KeyK',
                    keyCode: 75,
                    which: 75,
                    bubbles: true,
                    cancelable: true,
                });
                document.dispatchEvent(kKeyEvent);
            }, 100);
        }
    }

    function stopKKeyPress() {
        if (kKeyInterval) {
            clearInterval(kKeyInterval);
            kKeyInterval = null;

            const kKeyUpEvent = new KeyboardEvent('keyup', {
            key: 'K',
            code: 'KeyK',
            keyCode: 75,
            which: 75,
            bubbles: true,
            cancelable: true,
        });
        document.dispatchEvent(kKeyUpEvent);
        }
    }

    function simulateSpacebarPress() {
        if (!featuresEnabled) return;

        for (let i = 0; i < 500; i++) {
            const keyDownEvent = new KeyboardEvent('keydown', {
                key: ' ',
                code: 'Space',
                keyCode: 32,
                which: 32,
                bubbles: true,
                cancelable: true
            });
            document.dispatchEvent(keyDownEvent);

            const keyUpEvent = new KeyboardEvent('keyup', {
                key: ' ',
                code: 'Space',
                keyCode: 32,
                which: 32,
                bubbles: true,
                cancelable: true
            });
            setTimeout(() => {
                document.dispatchEvent(keyUpEvent);
            }, 1);
        }
    }

    document.addEventListener('keydown', (e) => {
        if (e.key === 'c') {
            featuresEnabled = !featuresEnabled;
            toggleFeatures(featuresEnabled);
        }
    });

    document.addEventListener('mousedown', (e) => {
        if (!featuresEnabled) return;

        if (e.button === 2) {
            crosshairColor = 'red';
            crosshair.style.borderColor = crosshairColor;

            if (!isRightMousePressed) {
                isRightMousePressed = true;
                startKKeyPress();
            }
        }
    });

    document.addEventListener('mouseup', (e) => {
        if (e.button === 2) {
            crosshairColor = 'green';
            crosshair.style.borderColor = crosshairColor;

            stopKKeyPress();
            isRightMousePressed = false;
        }
    });

    document.addEventListener('click', (event) => {
        if (event.button !== 2) {
            simulateSpacebarPress();
        }
    });

    setInterval(() => {
        if (!featuresEnabled) return;
        const ping = Math.random() * 100;
        pingFill.style.width = `${Math.min(ping, 100)}%`;
        pingFill.style.backgroundColor = ping > 70 ? 'red' : ping > 40 ? 'orange' : 'green';
    }, 1000);

    function getUserCountry() {
        fetch('https://ipapi.co/json/')
            .then(response => response.json())
            .then(data => {
                userCountry = data.country_name || 'Unknown';
                countryContainer.textContent = `Current Region is ${userCountry}`;
            })
            .catch(() => {
                userCountry = 'Unable to determine location';
                countryContainer.textContent = `Current Region is ${userCountry}`;
            });
    }

    getUserCountry();
})();

QingJ © 2025

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