// ==UserScript==
// @name Assmotes
// @namespace Intended for Unoeme's
// @version 0.03
// @description Memes
// @grant none
// @copyright 2015
// @include *://*.instasync.com/*
// @include *://instasync.com/*
// @include *://*.instasync.com/*
// @include *://instasync.com/*
// ==/UserScript==
// { src:"", width:, height:, title:''},
// { src:"", width:, height:, name:''},
var emotes = [
{ src:"http://i.imgur.com/v5yD2QN.jpg", width:98, height:55, title:'4u'},
{ src:"http://i.imgur.com/4cGasFZ.jpg", width:50, height:50, title:'bait'},
{ src:"http://i.imgur.com/VozZp9a.jpg", width:98, height:55, title:'bigguy'},
{ src:"http://i.imgur.com/mQlmx4o.gif", width:46, height:55, title:'canteven'},
{ src:"http://i.imgur.com/ObIFFbr.gif", width:61, height:50, title:'cena'},
{ src:"http://i.imgur.com/09bHA1f.png", width:62, height:50, title:'damagecontrol'},
{ src:"http://i.imgur.com/sHJfV20.gif", width:48, height:60, title:'delectable'},
{ src:"http://i.imgur.com/8AlFMQY.gif", width:75, height:55, title:'drunktwat'},
{ src:"http://i.imgur.com/7Tocjvz.jpg", width:37, height:50, title:'hi'},
{ src:"http://i.imgur.com/3Lft6v7.gif", width:45, height:50, title:'jonstop'},
{ src:"http://i.imgur.com/vU13Hgh.gif", width:76, height:50, title:'judenpls'},
{ src:"http://i.imgur.com/pmrrYag.gif", width:68, height:50, title:'kick'},
{ src:"http://i.imgur.com/vVIMrEM.gif", width:72, height:50, title:'loafening'},
{ src:"http://i.imgur.com/5tRLBC4.gif", width:49, height:50, title:'lolilol'},
{ src:"http://i.imgur.com/1tR8UGZ.png", width:133, height:45, title:'mystery'},
{ src:"http://i.imgur.com/iilzWxx.jpg", width:41, height:55, title:'ohfuck'},
{ src:"http://i.imgur.com/i2rfbNJ.jpg", width:63, height:60, title:'rlytho'},
{ src:"http://i.imgur.com/X7rYeEX.png", width:57, height:55, title:'shitnigger'},
{ src:"http://i.imgur.com/uWJZKZa.png", width:52, height:50, title:'toplel'},
{ src:"http://i.imgur.com/XEmrnog.jpg", width:68, height:50, title:'trump'},
{ src:"http://i.imgur.com/hypI7ad.jpg", width:140, height:45, title:'victory'},
{ src:"http://i.imgur.com/2hlSZv7.jpg", width:75, height:55, title:'wowremyourehuge'},
{ src:"http://i.imgur.com/belpqK0.gif", width:250, height:250, title:'mindcrush'},
{ src:"https://i.imgur.com/e59lUCu.gif", width:220, height:200, title:'bigblackgif'},
{ src:"https://i.ytimg.com/vi/Z6gG3tKDBlk/maxresdefault.jpg", width:100, height:60, title:'doit'},
{ src:"https://wwcdn.weddingwire.com/wedding/1120001_1125000/1123438/thumbnails/400x400_1346783188237-partyhard.jpg", width:110, height:110, title:'partyhard'},
{ src:"http://i.imgur.com/YqdnTBX.jpg", width:100, height:100, title:'bigblacknigga'},
{ src:"http://i.imgur.com/RFlgdxc.gif", width:90, height:120, title:'lipsuckin'},
{ src:"https://i.imgur.com/e59lUCu.gif", width:220, height:200, title:'bigblackgif'},
{ src:"http://i.imgur.com/c1hMV16.jpg", width:100, height:100, title:'fuckboy'},
{ src:"https://steamcommunity.com//economy/emoticon/:dappershark:", width:18, height:18, title:'dappershark'},
{ src:"http://images-cdn.moviepilot.com/image/upload/c_fill,h_296,w_480/t_mp_quality/screen-shot-2015-02-18-at-4-37-30-pm-the-russian-sleep-experiment-is-the-freakiest-story-ever-told-but-is-it-true-png-267188.jpg", width:120, height:100, title:'sleep'},
{ src:"https://i.imgur.com/Df8bSz6.gif", width:150, height:115, title:'snieg'},
{ src:"http://i.imgur.com/pm2jbj7.gif", width:150, height:94, title:'sack'},
{ src:"https://i.imgur.com/HdzRq4d.gif", width:125, height:100, title:'cut'},
{ src:"https://i.imgur.com/KlabckX.png", width:85, height:85, title:'tramplin'},
{ src:"http://i.imgur.com/belpqK0.gif", width:250, height:250, title:'mindcrush'},
{ src:"http://i.imgur.com/2YOG5cO.gif", width:90, height:60, title:'judenpls'},
{ src:"http://images-cdn.moviepilot.com/image/upload/c_fill,h_296,w_480/t_mp_quality/screen-shot-2015-02-18-at-4-37-30-pm-the-russian-sleep-experiment-is-the-freakiest-story-ever-told-but-is-it-true-png-267188.jpg", width:4096, height:2160, title:'youaskedforthis'},
{ src:"https://i.imgur.com/09J9qW6.gif", width:100, height:75, title:'hikevin'},
{ src:"http://www.arigato.heisi.at/wcf/images/smilies/pusheen_hello.png", width:75, height:100, title:'hi'},
{ src:"http://i.imgur.com/k9xpUve.gif", width:100, height:100, title:'thefuck'},
];
function addEmotes(){
emotes.forEach(function(emote){
window.$codes[emote.title || emote.name] = $('<img>', emote)[0].outerHTML;
});
}
function main(){
if(!window.$codes || Object.keys(window.$codes).length === 0){
setTimeout(main, 75);
}else{
addEmotes();
}
}
if (window.document.readyState === 'complete') {
main();
} else {
window.addEventListener('load', main, false);
}