Created
September 1, 2017 15:11
-
-
Save neenhouse/d0491c25d5cf1664fb192f3d6ffd5865 to your computer and use it in GitHub Desktop.
Ponies
This file contains hidden or 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(){ | |
var basePonyConfig = document.createElement('script'); | |
basePonyConfig.setAttribute('src','https://panzi.github.io/Browser-Ponies/browserponies.js'); | |
basePonyConfig.setAttribute('id','browser-ponies-script'); | |
document.head.appendChild(basePonyConfig); | |
var ponyScript = document.createElement('script'); | |
ponyScript.setAttribute('src','https://panzi.github.io/Browser-Ponies/basecfg.js'); | |
ponyScript.setAttribute('id','browser-ponies-script'); | |
document.head.appendChild(ponyScript); | |
function init(){ | |
if(window.BrowserPonies && window.BrowserPoniesBaseConfig) { | |
document.head.appendChild(ponyScript); | |
BrowserPonies.setBaseUrl('https://panzi.github.io/Browser-Ponies/'); | |
BrowserPonies.loadConfig(BrowserPoniesBaseConfig); | |
BrowserPonies.loadConfig({ | |
'baseurl':'https://panzi.github.io/Browser-Ponies/', | |
'fadeDuration':500, | |
'volume':1,'fps':25,'speed':3,'audioEnabled':false,'showFps':false,'showLoadProgress':true, | |
'speakProbability':0.1, | |
'spawn':{'applejack':1,'fluttershy':1,'pinkie pie':1,'rainbow dash':1,'rarity':1,'twilight sparkle':1}, | |
'autostart':true | |
}); | |
BrowserPonies.start(); | |
} else { | |
setTimeout(init, 500); | |
} | |
} | |
init(); | |
})(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment