Skip to content

Instantly share code, notes, and snippets.

@likuilin
Last active October 25, 2018 22:41
Show Gist options
  • Save likuilin/afbf0351024414844d8445c78ba44df2 to your computer and use it in GitHub Desktop.
Save likuilin/afbf0351024414844d8445c78ba44df2 to your computer and use it in GitHub Desktop.
// ==UserScript==
// @name Pardus Disable OC Retreat
// @author Kui
// @match https://*.pardus.at/ship2opponent_combat.php?*
// @updateURL https://gist.github.com/likuilin/afbf0351024414844d8445c78ba44df2/raw/disable_oc_retreat.user.js
// ==/UserScript==
(function() {
'use strict';
if (Array.from(document.querySelectorAll("font")).some(e=>e.innerText=="OFFENSIVE"))
document.querySelector('input[value="Retreat"]').onclick = ()=>confirm("Are you absolutely sure you want to retreat on OC?");
})();
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment