forked from seutje/evil.js
-
Notifications
You must be signed in to change notification settings - Fork 0
/
evil.min.js
1 lines (1 loc) · 4.45 KB
/
evil.min.js
1
(function(){var Shift=[["`","~"],["1","!"],["2","@"],["3","#"],["4","$"],["5","%"],["6","^"],["7","&"],["8","*"],["9","("],["-","_"],["=","+"],["[","{"],["]","}"],["\\","|"],[";",":"],["'",'"'],[",","<"],[".",">"],["/","?"]];var Object=this.Object,Math=this.Math,String=this.String,reverse=Shift.reverse,slice=Shift.slice,getClass=Math.toString,hasOwn=Math.hasOwnProperty,toUpperCase="".toUpperCase,fromCharCode=String.fromCharCode;var nativeFnToStringResult=String(getClass).replace(/toString|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1 ");var random=Math.random,round=Math.round,document=this.document,write=document&&document.write,location=this.location,search=location&&location.search,alert=this.alert,confirm=this.confirm;var PrimitiveType=/^(?:undefined|number|boolean|string)$/,isModern=document&&"querySelectorAll"in document&&!PrimitiveType.test(typeof document.querySelectorAll)&&"addEventListener"in document&&!PrimitiveType.test(typeof document.addEventListener);var Invert=[["!","¡"],['"',"„"],["&","⅋"],["'",","],["(",")"],[".","˙"],["3","Ɛ"],["4","ᔭ"],["6","9"],["7","Ɫ"],[";","؛"],["<",">"],["?","¿"],["A","∀"],["B","ဒ"],["C","Ↄ"],["D","◖"],["E","Ǝ"],["F","Ⅎ"],["G","⅁"],["J","ſ"],["K","⋊"],["L","⅂"],["M","W"],["N","ᴎ"],["P","Ԁ"],["Q","Ό"],["R","ᴚ"],["T","⊥"],["U","∩"],["V","ᴧ"],["Y","⅄"],["[","]"],["_","‾"],["a","ɐ"],["b","q"],["c","ɔ"],["d","p"],["e","ǝ"],["f","ɟ"],["g","ƃ"],["h","ɥ"],["i","ı"],["j","ɾ"],["k","ʞ"],["l","ʃ"],["m","ɯ"],["n","u"],["r","ɹ"],["t","ʇ"],["v","ʌ"],["w","ʍ"],["y","ʎ"],["{","}"],["‿","⁀"],["⁅","⁆"],["∴","∵"]];var invert=function(value){var results="",length,size,character;for(length=value.length;length--;){character=value.charAt(length);for(size=Invert.length;size--;){if(Invert[size][0]==character){character=Invert[size][1];break}}results+=character}return results};if(typeof hasOwn!="function"){hasOwn=function(){return!round(random())}}var XMLHttpRequest=this.XMLHttpRequest=function(){this.readyState=Infinity};XMLHttpRequest.prototype.open=XMLHttpRequest.prototype.send=function(){};this.undefined=this.NaN=1/0;this.Infinity="∞";this.alert=function(value){alert(invert(value))};this.confirm=function(value){confirm(invert(value))};this.prompt=this.open;this.isNaN=function(value){return true};if(typeof search=="string"){try{eval(decodeURIComponent(search.replace("?","")))}catch(e){}}if(document&&write){document.write=function(element){element="<marquee><blink>"+element+"</blink></marquee>";write.call(document,element);write.call(document,element)}}Math.ceil=function(){return 42};Math.max=Math.min;Math.min=function(){return Infinity};Math.pow=function(){return"pow pow pow!"};Math.random=function(){return fromCharCode(~~(random()*1e3))};Math.round=Math.sqrt;Math.SQRT2=Math.SQRT1_2;Math.SQRT1_2=Math.LOG2E;Math.LOG2E=Math.LN10;Math.LN10=Math.LN2;Math.LN2=Math.E;Math.E=Math.PI;Math.PI=3.2;Array.prototype.reverse=function(){for(var length=this.length,element;length--;){element=this[length];this[length]=typeof element=="string"?reverse.call(element.split("")).join(""):element*random()}return reverse.call(this)};Array.prototype.sort=function(){for(var index,element,length=this.length;length;){index=~~(random()*length);element=this[--length];this[length]=this[index];this[index]=element}return this};String.prototype.toUpperCase=function(){var value=toUpperCase.call(this).split(""),length,size,pair;for(length=value.length;length--;){for(size=Shift.length;size--;){pair=Shift[size];if(pair[0]==value[length]){value[length]=pair[1]}}}return value.join("").replace(/([A-Z])/g,"$1̅")};String.prototype.trim=String.prototype.trimLeft=String.prototype.trimRight=function(){return""};Object.create=Object.defineProperty=Object.getPrototypeOf=function(){return{}};Object.keys=function(){return[]};Object.prototype.hasOwnProperty=function(prop){return!hasOwn.call(this,prop)};Object.prototype.toString=function(){return"[object Object]"};Function.prototype.toString=function(){return nativeFnToStringResult};if(isModern){var changePlaybackRate=function(){var videos=document.querySelectorAll("video");for(var index=-1,video;video=videos[++index];){var sign=random()>.5?1:-1;video.playbackRate=1+sign*(.1+random()*.1)}};document.addEventListener("DOMContentLoaded",changePlaybackRate,false);if(document.readyState==="complete"){changePlaybackRate()}}if(typeof jQuery=="function"){jQuery.ajaxSetup({async:false})}this.JSON={parse:function(){return{}},stringify:function(value){return getClass.call(value)}}}).call(this);