您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Adds auction house link for selected items, sets currency to gems, duration to 7 days
当前为
// ==UserScript== // @name Flight Rising - Auction House Improvements (Seller) // @author https://greasyfork.org/en/users/547396 // @description Adds auction house link for selected items, sets currency to gems, duration to 7 days // @namespace https://greasyfork.org/users/547396 // @match https://*.flightrising.com/auction-house/sell/realm/* // @grant none // @version 0.11 // ==/UserScript== (function() { 'use strict'; var clickPanel = document.getElementById('ah-sell-left'), sellItem = document.getElementById('ah-sell-itemname'), sURL = window.location.href, bURL = sURL.replace('sell', 'buy'); clickPanel.addEventListener('click', function ( e ) { var itemName = e.path[1].dataset.name; if ( sURL.toString().indexOf('dragons') <= -1 ){ createButton( itemName ); } selectGemsDays(); }); function createButton( item ) { var ahButton = document.createElement('a'); ahButton.href = bURL + '?itemname=' + item; ahButton.target = '_blank'; ahButton.innerText = 'Auction House →'; // Styles ahButton.classList.add('redbutton'); ahButton.classList.add('anybutton'); ahButton.style.display = 'block'; ahButton.style.margin = '10px auto'; ahButton.style.padding = '5px 8px'; ahButton.style.fontSize = '10px'; ahButton.style.width = '100px'; sellItem.appendChild(ahButton); } // Automatically select gems and 7 days function selectGemsDays() { var gems = document.getElementById('ah-sell-currency-gems'), days = document.getElementById('ah-sell-duration'); // Comment out if you do not want gems/7 days auto-selected gems.checked = true; days.options.selectedIndex = 2; } })();