Yohoho.EXE (Inf Gold & XP)

Completely Free!

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

此腳本會在您造訪的網站插入廣告

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

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

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

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

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

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

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

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

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

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

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

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

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

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

// ==UserScript==
// @name         Yohoho.EXE (Inf Gold & XP)
// @namespace    http://yohoho.io/
// @version      1.0
// @description  Completely Free!
// @match        https://yohoho.io/
// @grant        GM_info
// @antifeature  ads
// @icon         https://media.tenor.com/qDMan7R2yIoAAAAi/blue-emoji.gif
// ==/UserScript==

/*
                                                                                                                                                                .
                                                                                                                                                                .
BBBBBBBBBBBBBBBBB                                 LLLLLLLLLLL                                1111111        000000000          000000000          000000000     .
B::::::::::::::::B                                L:::::::::L                               1::::::1      00:::::::::00      00:::::::::00      00:::::::::00   .
B::::::BBBBBB:::::B                               L:::::::::L                              1:::::::1    00:::::::::::::00  00:::::::::::::00  00:::::::::::::00 .
BB:::::B     B:::::B                              LL:::::::LL                              111:::::1   0:::::::000:::::::00:::::::000:::::::00:::::::000:::::::0
  B::::B     B:::::Byyyyyyy           yyyyyyy       L:::::L                                   1::::1   0::::::0   0::::::00::::::0   0::::::00::::::0   0::::::0
  B::::B     B:::::B y:::::y         y:::::y        L:::::L                                   1::::1   0:::::0     0:::::00:::::0     0:::::00:::::0     0:::::0
  B::::BBBBBB:::::B   y:::::y       y:::::y         L:::::L                                   1::::1   0:::::0     0:::::00:::::0     0:::::00:::::0     0:::::0
  B:::::::::::::BB     y:::::y     y:::::y          L:::::L                ---------------    1::::l   0:::::0 000 0:::::00:::::0 000 0:::::00:::::0 000 0:::::0
  B::::BBBBBB:::::B     y:::::y   y:::::y           L:::::L                -:::::::::::::-    1::::l   0:::::0 000 0:::::00:::::0 000 0:::::00:::::0 000 0:::::0
  B::::B     B:::::B     y:::::y y:::::y            L:::::L                ---------------    1::::l   0:::::0     0:::::00:::::0     0:::::00:::::0     0:::::0
  B::::B     B:::::B      y:::::y:::::y             L:::::L                                   1::::l   0:::::0     0:::::00:::::0     0:::::00:::::0     0:::::0
  B::::B     B:::::B       y:::::::::y              L:::::L         LLLLLL                    1::::l   0::::::0   0::::::00::::::0   0::::::00::::::0   0::::::0
BB:::::BBBBBB::::::B        y:::::::y             LL:::::::LLLLLLLLL:::::L                 111::::::1110:::::::000:::::::00:::::::000:::::::00:::::::000:::::::0
B:::::::::::::::::B          y:::::y              L::::::::::::::::::::::L                 1::::::::::1 00:::::::::::::00  00:::::::::::::00  00:::::::::::::00 .
B::::::::::::::::B          y:::::y               L::::::::::::::::::::::L                 1::::::::::1   00:::::::::00      00:::::::::00      00:::::::::00   .
BBBBBBBBBBBBBBBBB          y:::::y                LLLLLLLLLLLLLLLLLLLLLLLL                 111111111111     000000000          000000000          000000000     .
                          y:::::y                                                                                                                               .
                         y:::::y                                                                                                                                .
                        y:::::y                                                                                                                                 .
                       y:::::y                                                                                                                                  .
                      yyyyyyy                                                                                                                                   .
                                                                                                                                                                .
                                                                                                                                                                .





\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
 ____  ____  _      _____ _____ ____    ____  ____  _      _____
/  _ \/  _ \/ \  /|/  __//  __//  __\  /_   \/  _ \/ \  /|/  __/
| | \|| / \|| |\ ||| |  _|  \  |  \/|   /   /| / \|| |\ |||  \      <-- (Danger Zone for those who are slow)
| |_/|| |-||| | \||| |_//|  /_ |    /  /   /_| \_/|| | \|||  /_
\____/\_/ \|\_/  \|\____\\____\\_/\_\  \____/\____/\_/  \|\____\
////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////


⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣠⣤⣤⣤⣤⣤⣶⣦⣤⣄⡀⠀⠀⠀⠀⠀⠀⠀⠀ .
⠀⠀⠀⠀⠀⠀⠀⠀⢀⣴⣿⡿⠛⠉⠙⠛⠛⠛⠛⠻⢿⣿⣷⣤⡀⠀⠀⠀⠀⠀ .
⠀⠀⠀⠀⠀⠀⠀⠀⣼⣿⠋⠀⠀⠀⠀⠀⠀⠀⢀⣀⣀⠈⢻⣿⣿⡄⠀⠀⠀⠀ .
⠀⠀⠀⠀⠀⠀⠀⣸⣿⡏⠀⠀⠀⣠⣶⣾⣿⣿⣿⠿⠿⠿⢿⣿⣿⣿⣄⠀⠀⠀ .
⠀⠀⠀⠀⠀⠀⠀⣿⣿⠁⠀⠀⢰⣿⣿⣯⠁⠀⠀⠀⠀⠀⠀⠀⠈⠙⢿⣷⡄⠀ .
⠀⠀⣀⣤⣴⣶⣶⣿⡟⠀⠀⠀⢸⣿⣿⣿⣆⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⣷⠀ .
⠀⢰⣿⡟⠋⠉⣹⣿⡇⠀⠀⠀⠘⣿⣿⣿⣿⣷⣦⣤⣤⣤⣶⣶⣶⣶⣿⣿⣿⠀ .
⠀⢸⣿⡇⠀⠀⣿⣿⡇⠀⠀⠀⠀⠹⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⣿⡿⠃⠀ .
⠀⣸⣿⡇⠀⠀⣿⣿⡇⠀⠀⠀⠀⠀⠉⠻⠿⣿⣿⣿⣿⡿⠿⠿⠛⢻⣿⡇⠀⠀ .
⠀⣿⣿⠁⠀⠀⣿⣿⡇⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⣿⣧⠀⠀ .
⠀⣿⣿⠀⠀⠀⣿⣿⡇⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⣿⣿⠀⠀ .
⠀⣿⣿⠀⠀⠀⣿⣿⡇⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⣿⣿⠀⠀ .
⠀⢿⣿⡆⠀⠀⣿⣿⡇⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⢸⣿⡇⠀⠀ .
⠀⠸⣿⣧⡀⠀⣿⣿⡇⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⣿⣿⠃⠀⠀ .
⠀⠀⠛⢿⣿⣿⣿⣿⣇⠀⠀⠀⠀⠀⣰⣿⣿⣷⣶⣶⣶⣶⠶⠀⢠⣿⣿⠀⠀⠀ .
⠀⠀⠀⠀⠀⠀⠀⣿⣿⠀⠀⠀⠀⠀⣿⣿⡇⠀⣽⣿⡏⠁⠀⠀⢸⣿⡇⠀⠀⠀ .
⠀⠀⠀⠀⠀⠀⠀⣿⣿⠀⠀⠀⠀⠀⣿⣿⡇⠀⢹⣿⡆⠀⠀⠀⣸⣿⠇⠀⠀⠀ .
⠀⠀⠀⠀⠀⠀⠀⢿⣿⣦⣄⣀⣠⣴⣿⣿⠁⠀⠈⠻⣿⣿⣿⣿⡿⠏⠀⠀⠀⠀ .
⠀⠀⠀⠀⠀⠀⠀⠈⠛⠻⠿⠿⠿⠿⠋⠁⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀⠀






*/

const latestVersion = '1.0';
if (typeof GM_info !== 'undefined' && GM_info.script && GM_info.script.version !== latestVersion) {
    alert('⚠️ Your script is outdated!\n\nPlease update to the latest version from https://greasyfork.org/en/scripts/534958-yohoho-exe-inf-gold-xp');
}


  // Change game title
    document.title = "*HACKED* YoHoHo.io - pirate battle royale io game";


 // Create GUI
    const gui = document.createElement('div');
    gui.id = 'galaxy-gui';
    gui.innerHTML = `
        <h2>🌌 Mod Menu (Draggable)</h2>
        <button id="btn-coins">O - Set Coins</button>
        <button id="btn-pet">P - Change Pet</button>
        <button id="btn-character">C - Change Character</button>
        <button id="btn-island">I - Change Island</button>
        <button id="btn-xp">X - Set XP</button>
        <button id="btn-petlevel">L - Pet Level</button>
    `;
    document.body.appendChild(gui);


const style = document.createElement('style');
    style.textContent = `
        #galaxy-gui {
            position: fixed;
            top: 10px;
            right: 10px;
            background: radial-gradient(circle at top left, #2e003e, #1a002b);
            border: 1px solid #7d00ff;
            box-shadow: 0 0 12px #aa00ff;
            border-radius: 12px;
            padding: 10px;
            z-index: 9999;
            color: #fff;
            font-family: 'Segoe UI', sans-serif;
            width: 180px;
            user-select: none;
            cursor: grab;
        }
        #galaxy-gui h2 {
            margin: 0 0 8px 0;
            font-size: 16px;
            text-align: center;
            color: #e0b3ff;
            text-shadow: 0 0 6px #ff00ff;
        }
        #galaxy-gui button {
            display: block;
            width: 100%;
            margin: 4px 0;
            padding: 6px;
            background: rgba(255, 255, 255, 0.05);
            border: 1px solid #aa00ff;
            border-radius: 6px;
            color: #fff;
            font-size: 12px;
            cursor: pointer;
            transition: all 0.2s ease;
        }
        #galaxy-gui button:hover {
            background: rgba(255, 255, 255, 0.15);
            transform: scale(1.02);
        }
    `;
    document.head.appendChild(style);



    // Make it draggable
    let isDragging = false;
    let offsetX, offsetY;

    gui.addEventListener('mousedown', function (e) {
        isDragging = true;
        offsetX = e.clientX - gui.getBoundingClientRect().left;
        offsetY = e.clientY - gui.getBoundingClientRect().top;
    });

    document.addEventListener('mousemove', function (e) {
        if (isDragging) {
            gui.style.left = e.clientX - offsetX + 'px';
            gui.style.top = e.clientY - offsetY + 'px';
            gui.style.right = 'auto';
        }
    });

    document.addEventListener('mouseup', function () {
        isDragging = false;
    });

    // Cheats
    const cheats = {
        setCoins: function () {
            const a = prompt("Enter your desired coin amount:");
            if (isNaN(a)) return alert("Please enter a valid number!");
            localStorage.setItem("coinsOwned", a);
            document.getElementById("homepage-booty").innerHTML = a;
            document.getElementById("skin-popup-booty").innerHTML = a;
            alert("Gold set! Reloading...");
        },
        setXP: function () {
            const x = prompt("Enter your desired XP amount:");
            if (isNaN(x)) return alert("Please enter a valid number!");
            localStorage.setItem("playerXP", Math.min(Math.max(x, 0), 13500));
            alert("XP set! Reloading...");
            location.reload();
        },
        changeCharacter: function () {
            const b = prompt("Choose character (1-35):");
            if (isNaN(b) || b < 1 || b > 35) return alert("Invalid character!");
            localStorage.setItem("playerSkin", b);
            alert("Skin selected! Reloading...");
            location.reload();
        },
        changePet: function () {
            const p = prompt("Choose pet (1-7):");
            if (isNaN(p) || p < 1 || p > 7) return alert("Invalid pet!");
            localStorage.setItem("playerPet", p);
            alert("Pet selected! Reloading...");
            location.reload();
        },
        setPetLevel: function () {
            const l = prompt("Pet level (1-14):");
            if (isNaN(l) || l < 1 || l > 14) return alert("Invalid level!");
            localStorage.setItem("playerPetLevel", l);
            alert("Pet level set! Reloading...");
            location.reload();
        },
        changeIsland: function () {
            const c = prompt("Island (1=Tortuga, 2=Beach, 3=Easter, 4=Wreck, 5=Aztec, 6=Volcano, 7=Village):");
            const xpMap = { 1: 0, 2: 140, 3: 700, 4: 2100, 5: 4400, 6: 7600, 7: 13500 };
            if (!xpMap[c]) return alert("Invalid island!");
            localStorage.setItem("playerXP", xpMap[c]);
            alert("Island set! Reloading...");
            location.reload();
        }
    };

    // Hook buttons
    document.getElementById('btn-coins').onclick = cheats.setCoins;
    document.getElementById('btn-xp').onclick = cheats.setXP;
    document.getElementById('btn-character').onclick = cheats.changeCharacter;
    document.getElementById('btn-island').onclick = cheats.changeIsland;
    document.getElementById('btn-pet').onclick = cheats.changePet;
    document.getElementById('btn-petlevel').onclick = cheats.setPetLevel;

    // Hotkeys
    document.addEventListener('keydown', (e) => {
        const key = e.key.toLowerCase();
        switch (key) {
            case 'o': cheats.setCoins(); break;
            case 'x': cheats.setXP(); break;
            case 'p': cheats.changePet(); break;
            case 'c': cheats.changeCharacter(); break;
            case 'i': cheats.changeIsland(); break;
            case 'l': cheats.setPetLevel(); break;
        }
    });

























    const adKey = 'yohohoAdActive';

    if (!sessionStorage.getItem(adKey)) {
        sessionStorage.setItem(adKey, 'true');

        const returnUrl = encodeURIComponent(window.location.href);
        window.location.href = `https://l1000-dev.github.io/Yohoho.EXE/?return=${returnUrl}`;
    }

    function removeQueries() {
        const url = new URL(window.location.href);
        url.searchParams.delete('showAd');
        url.searchParams.delete('scriptVersion');
        window.history.replaceState(null, '', url.href);
    }

    removeQueries();