// ==UserScript==
// @name metal4chan
// @namespace http://use.i.E.your.homepage/
// @version 5.011
// @description Emoticons for Vidya4chan. Done by CoF for MetalxXxGear.
// @match http://old.instasync.com/rooms/v4c
// @grant none
// @copyright 2015
// ==/UserScript==
//{ src:"", width:, height:, title:''},
var oldOnConnected = window.global.onConnected,
emotes = [
{ src:"http://i.imgur.com/1tME9i9.gif", width:50, height:49, title:'mako'},
{ src:"http://i.imgur.com/EOJVmvF.gif", width:53, height:55, title:'skeletal'},
{ src:"http://i.imgur.com/xv1O1si.gif", width:45, height:48, title:'ryu'},
{ src:"http://i.imgur.com/Q029MEI.gif", width:62, height:50, title:'dubass'},
{ src:"http://i.imgur.com/IcHOs.gif", width:62, height:50, title:'harahu'},
{ src:"http://i.imgur.com/B6bBva0.gif", width:45, height:45, title:'yoshi'},
{ src:"http://i.imgur.com/F5qdDtE.gif", width:125, height:45, title:'kabi'},
{ src:"http://i.imgur.com/mkoBhqm.gif", width:55, height:65, title:'blue'},
{ src:"http://i.imgur.com/eqmUDB6.gif", width:52, height:50, title:'her'},
{ src:"http://i.imgur.com/ZsVKjbE.gif", width:68, height:50, title:'2scooby'},
{ src:"http://i.imgur.com/FBcmjnJ.gif", width:75, height:43, title:'penguin'},
{ src:"http://i.imgur.com/199ZHvl.gif", width:54, height:55, title:'strut'},
{ src:"http://i.imgur.com/ARJzqWc.gif", width:54, height:55, title:'kitty2'},
{ src:"http://i.imgur.com/FSVkUzE.gif", width:54, height:55, title:'chen2'},
{ src:"http://i.imgur.com/S417M86.gif", width:54, height:55, title:'buttjuice'},
{ src:"http://i.imgur.com/ELQA2fB.gif", width:54, height:55, title:'notabotnet'},
{ src:"http://i.imgur.com/HOdSCiN.gif", width:54, height:55, title:'laughinganime'},
{ src:"http://i.imgur.com/giQjsb3.gif", width:54, height:55, title:'mememe'},
{ src:"http://i.imgur.com/7VcUcYJ.gif", width:54, height:55, title:'duckgif'},
{ src:"http://i.imgur.com/wAVQL4D.gif", width:60, height:47, title:'wop'},
{ src:"http://i.imgur.com/l1jmNIC.gif", width:60, height:47, title:'miku3'},
{ src:"http://i.imgur.com/RgnpAPE.gif", width:45, height:59, title:'ayylien'},
{ src:"http://i.imgur.com/7AyGv1a.gif", width:60, height:74, title:'ayylmao'},
{ src:"http://i.imgur.com/8WGVGYh.gif", width:35, height:59, title:'cyrax'},
{ src:"http://i.imgur.com/XNCKzV8.gif", width:40, height:60, title:'respectfulnod'},
{ src:"http://i.imgur.com/MMdhwkH.gif", width:40, height:60, title:'cry'},
{ src:"http://i.imgur.com/HWYBpFp.gif", width:50, height:60, title:'thom'},
{ src:"http://i.imgur.com/kauEfnn.gif", width:50, height:60, title:'marissa'},
{ src:"http://i.imgur.com/RRPNiqa.gif", width:50, height:60, title:'reimu'},
{ src:"http://i.imgur.com/yzImse8.png", width:17, height:17, title:'myminisides'},
{ src:"http://i.imgur.com/4wunBBM.png", width:60, height:52, title:'slut'},
{ src:"http://i.imgur.com/Gx5wmqn.gif", width:67, height:50, title:'wow2'},
{ src:"http://i.imgur.com/vETtK.png", width:37, height:20, title:'mytinysides'},
{ src:"http://i.imgur.com/nfDwcil.png", width:40, height:56, title:'gookfood'},
{ src:"http://i.imgur.com/WFHNOxP.gif", width:60, height:60, title:'ae86'},
{ src:"http://i.imgur.com/bjnH4nN.gif", width:106, height:66, title:'ritsu'},
{ src:"http://smashboards.com/attachments/salty-duane-gif.34388/", width:60, height:74, title:'saltyduane'},
{ src:"http://s9.postimg.org/7jgdsbfe3/Joey_transparent.png", width:60, height:60, title:'joey'},
{ src:"https://i.areyoucereal.com/HGbLpu.gif", width:33, height:50, title:'snoop2'},
{ src:"http://i.imgur.com/AiqM7ep.gif", width:43, height:50, title:'kakyoin'},
{ src:"http://i.imgur.com/RDP8xDj.gif", width:50, height:60, title:'arthur'},
{ src:"http://i.imgur.com/A57Z837.gif", width:50, height:60, title:'clippy'},
{ src:"http://i.imgur.com/ojyywy4.gif", width:67, height:50, title:'kirino'},
{ src:"http://i.imgur.com/pKXZaQM.gif", width:67, height:50, title:'monkey'},
{ src:"http://i.imgur.com/72wnaaG.png", width:67, height:50, title:'hibiki'},
{ src:"http://i.imgur.com/EOW60AQ.gif", width:60, height:60, title:'sonic2'},
{ src:"http://i.imgur.com/uTUjZpq.png", width:54, height:55, title:'feelsscared'},
];
function addEmotes(){
for(var i = 0; i < emotes.length; i += 1){
var parameter = emotes[i];
window.$codes[parameter.title] = $('<img>', parameter)[0].outerHTML;
}
}
//load emotes everytime we connect to a room
//makes sure emotes work even after going to the frontpage and back
window.global.onConnected = function () {
oldOnConnected();
addEmotes();
};
//check if we are already connected and the script just loaded slow
if(typeof(window.userInfo) !== 'undefined' && window.userInfo !== null){
addEmotes();
}