This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function dyslexia(string){return String.fromCharCode.apply(this,string.split('').map(function(a){return a.charCodeAt()^255;}))} | |
var a = "{lives:3}"; | |
var z = dyslexia(a); | |
a == dyslexia(z); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var evIl = function(script) { | |
blob = new Blob([script], { | |
type: "application/javascript" | |
}); | |
url = window.URL.createObjectURL(blob); | |
s = document.createElement('script'); | |
s.src = url; | |
document.head.appendChild(s); | |
window.URL.revokeObjectURL(url); | |
s.parentElement.removeChild(s); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function blend(element,blendMode,opacity) { | |
// this._.extraTexture.loadContentsOf(element); | |
// this._.extraTexture.use(1); | |
element._.use(1); | |
if(gl.blend == undefined){ | |
var shader= (function () { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Reserved words | |
-------------- | |
Width | |
Height | |
X | |
Y | |
Scale - not used yet but will be used to declare the scalling method and details (slice and all that) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function(window){ | |
var EVENT_EXISTS = 'GlobalEvents: Event already exists.'; | |
var eventIsRunning, | |
_eventStack, | |
_findByName, | |
stackEvent, | |
removeEvent, | |
eventListener, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// http://jsfiddle.net/justin_c_rounds/Gd2S2/ | |
function checkLineIntersection(startX1, startY1, endX1, endY1, startX2, startY2, endX2, endY2, result) { | |
// if the lines intersect, the result contains the x and y of the intersection (treating the lines as infinite) and booleans for whether line segment 1 or line segment 2 contain the point | |
var denominator, a, b, numerator1, numerator2, result = result || { | |
x: 0, | |
y: 0, | |
onLine1: false, | |
onLine2: false | |
}; | |
denominator = ((endY2 - startY2) * (endX1 - startX1)) - ((endX2 - startX2) * (endY1 - startY1)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function colorToHSL(red, green, blue) { | |
var luminance, hue, saturation; | |
red = red / 255; | |
green = green / 255; | |
blue = blue / 255; | |
var vmax = Math.max(Math.max(red, green), blue); | |
var vmin = Math.min(Math.min(red, green), blue); | |
var delta = vmax - vmin; | |
var luminance = (vmax + vmin) / 2; | |
if (delta > 0) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function getFnName(fn) { | |
var f = typeof fn == 'function'; | |
var s = f && ((fn.name && ['', fn.name]) || fn.toString().match(/function ([^\(]+)/)); | |
return (!f && 'not a function') || (s && s[1] || 'anonymous'); | |
} | |
console.log(getFnName(String)); // 'String' | |
console.log(getFnName(function test(){})); // 'test' | |
console.log(getFnName(function (){})); // 'anonymous' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var p1 = { | |
x: 20, | |
y: 20 | |
}; | |
var p2 = { | |
x: 40, | |
y: 40 | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Goes through all selected folders (one deep) and checks if a wav file with the same name of a flac files exists and if it does then delete it. | |
This is my first script for QtTabBar....one of the best extensions to Windows, EVER! | |
`qs.InvokeCommand( "DeleteFile", fc.item().Path);` | |
Didnt work for me, complains the command doesnt exist. If I try using the command code of 125 then it doesnt bitch but it doesnt seem to do anything either. Using the fso.DeleteFile worked fine, except it didnt send it to the recycle bin which would have been nice, but I spose theres something for that but didnt look coz its working ;). |
OlderNewer