Greasy Fork 还支持 简体中文。

Zombs.io resource detector

Open settings and see all the resources of whoever you are next to.

  1. // ==UserScript==
  2. // @name Zombs.io resource detector
  3. // @namespace http://tampermonkey.net/
  4. // @version 1.1
  5. // @description Open settings and see all the resources of whoever you are next to.
  6. // @author You
  7. // @match *://zombs.io/*
  8. // @grant none
  9. // ==/UserScript==
  10. window.loadedIDS = function(){
  11. var returns = []
  12. Object.entries(Game.currentGame.world.entities).forEach((stuff => {
  13. if(stuff[1].targetTick.entityClass == "PlayerEntity" && stuff[1].targetTick.name !== Game.currentGame.world.entities[Game.currentGame.world.getMyUid()].targetTick.name){
  14. returns.push(stuff[1].targetTick.name + " - Wood: " + Game.currentGame.world.entities[stuff[1].targetTick.uid].targetTick.wood + ", Stone: " + Game.currentGame.world.entities[stuff[1].targetTick.uid].targetTick.stone + ", Gold: " + Game.currentGame.world.entities[stuff[1].targetTick.uid].targetTick.gold)
  15. }
  16. }))
  17. return returns;
  18. }
  19. var i = setInterval(function(){
  20. document.querySelector('.hud-settings-grid').innerText = JSON.stringify(window.loadedIDS())
  21. }, 100)