Last active
August 17, 2018 12:34
-
-
Save Eskuero/af7516218b7dd006abd6934681026c56 to your computer and use it in GitHub Desktop.
GreaseMonkey script to allow easy typing of hacker font in niu.moe Download the extension and open the raw link of the following file to install: https://addons.mozilla.org/en-US/firefox/addon/greasemonkey/
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
// ==UserScript== | |
// @name Hacker buttons | |
// @version 1 | |
// @include *niu.moe* | |
// @grant none | |
// ==/UserScript== | |
setTimeout(function() { | |
hackerbutton = document.createElement("img"); | |
hackerbutton.src = "https://cdn.niu.moe/custom_emojis/images/000/004/734/original/934bc263da8d1735.png"; | |
hackerbutton.width = "26"; | |
hackerbutton.onclick = function() { hacker() }; | |
document.getElementsByClassName("emoji-picker-dropdown")[0].appendChild(hackerbutton); | |
}, 3000); | |
function hacker() { | |
text = prompt("Type your message:"); | |
emojiform = ""; | |
for (i = 0; i < text.length; i++) { | |
if (text[i] != " ") { | |
var letter = text[i].toLowerCase(); | |
emojiform += ":hacker_" + letter + ": "; | |
} else { | |
emojiform += "\n"; | |
} | |
} | |
document.getElementsByClassName("autosuggest-textarea__textarea")[0].value = emojiform; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment