Greasy Fork is available in English.

Surviv.io | Health and Adrenaline counter

apple apple apple

  1. // ==UserScript==
  2. // @name Surviv.io | Health and Adrenaline counter
  3. // @namespace https://github.com/Samer-Kizi
  4. // @version 1.1
  5. // @description apple apple apple
  6. // @author sk
  7. // @license MIT
  8. // @match https://surviv.io/*
  9. // @match https://surviv2.io/*
  10. // @match https://2dbattleroyale.com/*
  11. // @match https://2dbattleroyale.org/*
  12. // @match https://piearesquared.info/*
  13. // @match https://thecircleisclosing.com/*
  14. // @match https://secantsecant.com/*
  15. // @match https://parmainitiative.com/*
  16. // @match https://ot38.club/*
  17. // @match https://drchandlertallow.com/*
  18. // @match https://rarepotato.com/*
  19. // @match https://archimedesofsyracuse.info/*
  20. // @match https://nevelskoygroup.com/*
  21. // @match https://kugahi.com/*
  22. // @match https://kugaheavyindustry.com/*
  23. // @match https://chandlertallowmd.com/*
  24. // @grant none
  25. // @require http://code.jquery.com/jquery-3.4.1.min.js
  26. // ==/UserScript==
  27.  
  28. // I stole health counter from Michal2SAB lol
  29.  
  30. (function() {
  31. 'use strict';
  32. var lastHP = 0
  33. var health = document.createElement("span");
  34. health.style = "display:block;position:fixed;z-index: 2;margin:6px 0 0 0;right: 15px;mix-blend-mode: difference;font-weight: bold;font-size:large;";
  35. document.querySelector("#ui-health-container").appendChild(health);
  36.  
  37. var adr = document.createElement("span");
  38. adr.style = "display:block;position:fixed;z-index: 2;margin:6px 0 0 0;left: 15px;mix-blend-mode: difference;font-weight: bold;font-size:large;";
  39. document.querySelector("#ui-health-container").appendChild(adr);
  40.  
  41. setInterval(function(){
  42. var hp = document.getElementById("ui-health-actual").style.width.slice(0,-1)
  43. if(lastHP !== hp){
  44. lastHP = hp
  45. health.innerHTML = Math.round(hp)
  46. }
  47. var boost0 = document.getElementById("ui-boost-counter-0").querySelector(".ui-bar-inner").style.width.slice(0,-1),
  48. boost1 = document.getElementById("ui-boost-counter-1").querySelector(".ui-bar-inner").style.width.slice(0,-1),
  49. boost2 = document.getElementById("ui-boost-counter-2").querySelector(".ui-bar-inner").style.width.slice(0,-1),
  50. boost3 = document.getElementById("ui-boost-counter-3").querySelector(".ui-bar-inner").style.width.slice(0,-1),
  51. adr0 = boost0*25/100 + boost1*25/100 + boost2*37.5/100 + boost3*12.5/100
  52. adr.innerHTML = Math.round(adr0)
  53. })
  54. })();