|
|
|
|
|
by granttimmerman
4311 days ago
|
|
I created a music auto-player since I was too lazy to play your guy's songs by myself. Paste this in the console. // SETTINGS
var input = "rsa ecde srgu yhgr bv rsa ecde srgu yhgr bv hybtg ser erv";
input += " hybtg iii r hybtg ser erv tvr rrr rvgres rrr rvg rrr rvgres ";
input += "ggg rgh grs sxebbe cuuuhbgres grs sxebbe cbbbgvrsai";
var TIME_INTERVAL = 300;
// Add jquery
var script = document.createElement('script');
script.src = 'http://code.jquery.com/jquery-1.11.0.min.js';
script.type = 'text/javascript';
document.getElementsByTagName('head')[0].appendChild(script);
function play () {
// Sound array setup
var soundArray = [];
var down = $.Event("keydown");
var up = $.Event("keyup");
input = ' ' + input; // hack
for (var i = 0; i < input.length; ++i) {
soundArray.push(input.toUpperCase().charCodeAt(i));
}
// Start sound
var index = 0;
function playSound () {
up.which = soundArray[index];
$("body").trigger(up);
++index;
down.which = soundArray[index];
$("body").trigger(down);
// // is there another?
if (index < soundArray.length) {
setTimeout(playSound, TIME_INTERVAL);
}
}
playSound();
}
(function loadjQuery () {
if (typeof jQuery === 'undefined') {
setTimeout(loadjQuery, 100);
} else {
play();
}
})();
|
|
"uyvyu,pl,ynuuupl,kmk,,uyvuyvyu,pl,ynuuupl,kmk,,uyvppp;[[;plp;;;pl,kmk,ynuu,,,kmmml;pl,,kuu,lp;[,lp;l,"
completely breaks it about half way through.
Anyway, cool hack!