您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Adds buttons to pages to allow you to quick use point refills and resets without being on the donator page
当前为
// ==UserScript== // @name Cartel Empire - Quick Refills/Resets // @namespace baccy.ce // @version 0.1 // @description Adds buttons to pages to allow you to quick use point refills and resets without being on the donator page // @author Baccy // @match https://cartelempire.online/* // @icon https://cartelempire.online/images/icon-white.png // @grant none // @license MIT // ==/UserScript== (function() { 'use strict'; let title = null; let url; let header = 1; switch (location.pathname) { case '/PetShop': title = 'Pet Shop'; url = 'https://cartelempire.online/Donator/ResetPetShop'; break; case '/Town/Club': title = 'Club'; url = 'https://cartelempire.online/Donator/ResetClubRecruitment'; break; case '/Casino/Blackjack': title = 'Refill Tokens'; url = 'https://cartelempire.online/Donator/ResetTokens'; break; case '/Casino/Spinner': title = 'Refill Tokens'; url = 'https://cartelempire.online/Donator/ResetTokens'; break; case '/Casino/Slots': title = 'Refill Tokens'; url = 'https://cartelempire.online/Donator/ResetTokens'; break; case '/Casino/Lottery': title = 'Refill Tokens'; url = 'https://cartelempire.online/Donator/ResetTokens'; header = 3; break; case '/Gym': title = 'Refill Energy'; url = 'https://cartelempire.online/Donator/Refill/Energy'; header = 0; break; case '/University': title = 'Refill Energy'; url = 'https://cartelempire.online/Donator/Refill/Energy'; header = 0; break; case '/Hospital': title = 'Refill Life'; url = 'https://cartelempire.online/Donator/Refill/Life'; header = 0; break; default: break; } if (title !== null) { const headers = document.querySelectorAll('.header-section'); if (headers[header]) { headers[header].style.cssText = 'display: flex; justify-content: space-between;'; const button = document.createElement('button'); button.textContent = title; button.style.cssText = 'background: #1e1e1e; color: #fff; border: 1px solid #555; padding: 10px 15px; border-radius: 5px; cursor: pointer; font-size: 14px;'; button.addEventListener('click', async () => { const response = await fetch(url, { method: 'POST' }); if (response.ok) window.location.reload(); }); headers[header].appendChild(button); } } })();