MuteList *OLD*

Adds a /mutelist <regxp> command

  1. // ==UserScript==
  2. // @name MuteList *OLD*
  3. // @namespace skyboy@kongregate
  4. // @author skyboy
  5. // @version 1.0.1
  6. // @description Adds a /mutelist <regxp> command
  7. // @include http://www.kongregate.com/games/*/*
  8. // @exclude http://www.kongregate.com/games/*/*/*
  9. // @homepage http://userscripts-mirror.org/scripts/show/73254
  10. // ==/UserScript==
  11. if (/^\/?games\/[^\/]+\/[^\/?]+(\?.*)?$/.test(window.location.pathname))
  12. setTimeout(function() {
  13. window.location.assign("javascript:holodeck.addChatCommand(\"mutelist\", function(h,d){d=d.match(/^\\/mutelist\\s*(\\S+)?/i)[1];var a=0,b=holodeck._chat_window._mutings,s=\"\",p,o=[];if(!!d){for(p in b){if(b[p]&&p.match(d)){o.push(p)}}a=o.length+' matching users muted:\\xa0 '+o.join(', \\xa0')}else{for(p in b){s+=p+', \\xa0';++a};a=a+' users muted:\\xa0 '+s.substr(0,s.length-3);}h.activeDialogue().kongBotMessage(a);return false});void(0)");
  14. }, 1250);