// ==UserScript== // @name 橙光无限鲜花 // @version 1.0.1.0 // @namespace http://tampermonkey.net/ // @description 使用说明:进入游戏后右上角点击启用 // @author 希尔顿 // @icon data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw== // @grant none // @match https://*.66rpg.com/h5/* // @downloadURL none // ==/UserScript== ;(function () { 'use strict' const v = window.document.createElement('button') v.textContent = '菜单' v.style.position = 'fixed' v.style.background = '#ffcc00' v.style.top = '03px' v.style.right = '5px' v.style.borderRadius = '0px' v.style.zIndex = '9999' v.addEventListener('click', f6) window.document.body.appendChild(v) const v2 = window.document.createElement('div') v2.style.display = 'none' v2.style.position = 'fixed' v2.style.top = '3.60px' v2.style.left = '100px' v2.style.transform = 'translate(-0%, -0%)' v2.style.width = '200px' v2.style.backgroundColor = 'edd1d8' v2.style.padding = '10px' v2.style.borderRadius = '0px' v2.style.zIndex = '9999' const v3 = { label: '修改鲜花', action: f8, } const v31 = { label: '无限花开启', action: f9, } const v32 = { label: '开启全屏', action: f10, } const v33 = [v3, v31, v32] v33.forEach((p17) => { const v34 = window.document.createElement('button') v34.textContent = p17.label v34.addEventListener('click', p17.action) v2.appendChild(v34) }) const v35 = window.document.createElement('button') v35.textContent = '退出' v35.addEventListener('click', f7) v2.appendChild(v35) window.document.body.appendChild(v2) function f6() { v2.style.display = 'block' } function f7() { v2.style.display = 'none' } function f8() { { const vPrompt2 = prompt('鲜花数量') if ( typeof getUserData !== 'undefined' && typeof getUserData() === 'object' ) { { getUserData().totalFlower = vPrompt2 getUserData().freshFlower = vPrompt2 getUserData().wildFlower = vPrompt2 getUserData().tempFlower = vPrompt2 getUserData().realFlower = vPrompt2 getUserData().haveFlower = vPrompt2 } } } } function f9() { ;(function () { 'use strict' const v36 = { uid: 31467085, userName: '中皇晴雪', token: '', isLogin: true, haveWZ: 0, dumpling_num: 0, allWZ: 0, platform: 'H5', device: 'Pc', vip_level: '0', screen_game_ad: 0, channel_id: null, tan_wz_num: 0, realWZ: 0, } const vF12 = () => { if (typeof window.getUserData === 'function') { window.getUserData = function () { console.log('已动态修改 getUserData 函数的返回值!') return v36 } console.log('getUserData 函数已成功覆盖!') } else { console.log('getUserData 函数尚未定义,等待下一次检查...') setTimeout(vF12, 100) } } vF12() document.addEventListener('DOMContentLoaded', function () { { var v37 = document.createElement('div') v37.id = 'authorInfo' v37.style.display = 'none' v37.style.position = 'fixed' v37.style.top = '0' v37.style.left = '0' v37.style.width = '100%' v37.style.height = '100%' v37.style.backgroundColor = 'rgba(0, 0, 0, 0.5)' v37.style.justifyContent = 'center' v37.style.alignItems = 'center' v37.style.zIndex = '1000' var v38 = document.createElement('div') v38.style.background = 'white' v38.style.padding = '20px' v38.style.borderRadius = '5px' v38.style.textAlign = 'center' var v39 = document.createElement('p') v39.textContent = '橙光无限鲜花' var v40 = document.createElement('button') v40.textContent = '关闭' v40.style.marginTop = '10px' v40.addEventListener('click', function () { v37.style.display = 'none' }) v38.appendChild(v39) v38.appendChild(v40) v37.appendChild(v38) document.body.appendChild(v37) v37.style.display = 'flex' } }) const v41 = '1680808' const v42 = '45209f587de1ac248d9fce9e304334ba' const v43 = ['/PropShop/engine/v5/user/getUserHaveAllPropNum'] const v44 = [ '/PropShop/engine/v2/PropOrder/createBuyOrder', '/PropShop/engine/v5/Game/get_goods_list', ] let v45 = false let v46 = false let v47 = true const vF13 = (p18) => { console.log('[全面拦截脚本日志] ' + p18) } const vF14 = (p19) => { try { const v48 = new URL(p19, location.origin) v48.searchParams.set('gindex', v41) v48.searchParams.set('token', v42) return v48.toString() } catch (_0x266f7d) { vF13('URL 修改失败: ' + _0x266f7d.message) return p19 } } const vF15 = () => { const v49 = XMLHttpRequest.prototype.open XMLHttpRequest.prototype.open = function (p20, p21, ..._0x1d4d07) { if ( (v45 && v43.some((p22) => p21.includes(p22))) || (v46 && v44.some((p23) => p21.includes(p23))) ) { p21 = vF14(p21) } this._modifiedUrl = p21 return v49.call(this, p20, p21, ..._0x1d4d07) } } const vF16 = () => { const v50 = document.createElement document.createElement = function (p24, ..._0x2b3c47) { { if (p24.toLowerCase() === 'script') { { const v51 = v50.call(this, p24, ..._0x2b3c47) Object.defineProperty(v51, 'src', { set(p25) { { if ( (v45 && v43.some((p26) => p25.includes(p26))) || (v46 && v44.some((p27) => p25.includes(p27))) ) { { const vVF14 = vF14(p25) vF13('[JSONP请求拦截] 修改后的URL: ' + vVF14) return v51.setAttribute('src', vVF14) } } return v51.setAttribute('src', p25) } }, get() { return v51.getAttribute('src') }, }) return v51 } } return v50.call(this, p24, ..._0x2b3c47) } } } const vF17 = (p28, p29) => { const v52 = document.createElement('div') v52.textContent = p28 v52.style = '\n position: fixed;\n top: 20px;\n left: 20px;\n background: rgba(0, 0, 0, 0.5);\n color: white;\n padding: 10px;\n border-radius: 5px;\n z-index: 9999;\n cursor: move;\n font-size: 12px;\n ' v52.draggable = true v52.ondragstart = (p30) => { { p30.dataTransfer.setData('text/plain', null) const v53 = v52.getBoundingClientRect() p30.dataTransfer.effectAllowed = 'move' v52.dataset.offsetX = p30.clientX - v53.left v52.dataset.offsetY = p30.clientY - v53.top } } v52.ondragend = (p31) => { v52.style.left = p31.clientX - v52.dataset.offsetX + 'px' v52.style.top = p31.clientY - v52.dataset.offsetY + 'px' } v52.onclick = p29 document.body.appendChild(v52) return v52 } const vF18 = () => { v47 = !v47 document.querySelectorAll('.intercept-button').forEach((p32) => { p32.style.display = v47 ? 'block' : 'none' }) } const vF19 = () => { const vVF17 = vF17('点击我开启商城无限花', () => { v45 = !v45 alert('尽量不要购买太多东西!够用即可!' + (v45 ? '启用' : '禁用')) }) vVF17.classList.add('intercept-button') const vVF172 = vF17('点我开启修改鲜花按钮', () => { v46 = !v46 alert('开启后可使用修改鲜花按钮' + (v46 ? '启用' : '禁用')) }) vVF172.style.top = '60px' vVF172.classList.add('intercept-button') } const vF20 = () => { vF15() vF16() vF19() document.addEventListener('dblclick', vF18) vF13('全面请求拦截脚本已成功运行') } if (document.readyState === 'loading') { document.addEventListener('DOMContentLoaded', vF20) } else { vF20() } })() } })() function f10() { if ( !window.document.fullscreenElement && !window.document.mozFullScreenElement && !window.document.webkitFullscreenElement && !window.document.msFullscreenElement ) { if (window.document.documentElement.requestFullscreen) { window.document.documentElement.requestFullscreen() } else if (window.document.documentElement.msRequestFullscreen) { window.document.documentElement.msRequestFullscreen() } else if (window.document.documentElement.mozRequestFullScreen) { window.document.documentElement.mozRequestFullScreen() } else if (window.document.documentElement.webkitRequestFullscreen) { window.document.documentElement.webkitRequestFullscreen( Element.ALLOW_KEYBOARD_INPUT ) } } else if (window.document.exitFullscreen) { window.document.exitFullscreen() } else if (window.document.msExitFullscreen) { window.document.msExitFullscreen() } else if (window.document.mozCancelFullScreen) { window.document.mozCancelFullScreen() } else if (window.document.webkitExitFullscreen) { window.document.webkitExitFullscreen() } } ;(function () { 'use strict' setTimeout(function () { if (typeof userData !== 'undefined') { userData.isLogin = true console.log('userData.isLogin 已设置为 true') } else { console.error('userData 对象未定义') } }, 10000) })() ;(function () { 'use strict' const v54 = { uid: 31467085, userName: '中皇晴雪', token: '', isLogin: true, haveWZ: 0, dumpling_num: 0, allWZ: 0, platform: 'H5', device: 'Pc', vip_level: '0', screen_game_ad: 0, channel_id: null, tan_wz_num: 0, realWZ: 0, } const vF21 = () => { if (typeof window.getUserData === 'function') { window.getUserData = function () { console.log('已动态修改 getUserData 函数的返回值!') return v54 } console.log('getUserData 函数已成功覆盖!') } else { console.log('getUserData 函数尚未定义,等待下一次检查...') setTimeout(vF21, 100) } } vF21() const vF22 = () => { { interceptXHR() interceptJSONP() initializeButtons() document.addEventListener('dblclick', toggleButtonsVisibility) log('全面请求拦截脚本已成功运行') } } if (document.readyState === 'loading') { document.addEventListener('DOMContentLoaded', vF22) } else { vF22() } })()