Window.eval()? Var?
This commit is contained in:
32
README.md
32
README.md
@@ -82,16 +82,14 @@ If you'd rather use the addon as a script via per example *Greasemonkey* or *Tam
|
||||
// @grant none
|
||||
// ==/UserScript==
|
||||
|
||||
var code = "(" + (function() {
|
||||
var checkReady = setInterval(function() {
|
||||
if (typeof Game.ready !== 'undefined' && Game.ready) {
|
||||
Game.LoadMod('https://aktanusa.github.io/CookieMonster/CookieMonster.js');
|
||||
clearInterval(checkReady);
|
||||
}
|
||||
}, 1000);
|
||||
}).toString() + ")()";
|
||||
'use strict';
|
||||
|
||||
window.eval(code);
|
||||
let checkReady = setInterval(function() {
|
||||
if (typeof Game.ready !== 'undefined' && Game.ready) {
|
||||
Game.LoadMod('https://aktanusa.github.io/CookieMonster/CookieMonster.js');
|
||||
clearInterval(checkReady);
|
||||
}
|
||||
}, 1000);
|
||||
```
|
||||
If you are using the beta, use this instead:
|
||||
|
||||
@@ -105,16 +103,14 @@ If you are using the beta, use this instead:
|
||||
// @grant none
|
||||
// ==/UserScript==
|
||||
|
||||
var code = "(" + (function() {
|
||||
var checkReady = setInterval(function() {
|
||||
if (typeof Game.ready !== 'undefined' && Game.ready) {
|
||||
Game.LoadMod('https://aktanusa.github.io/CookieMonster/CookieMonsterBeta.js');
|
||||
clearInterval(checkReady);
|
||||
}
|
||||
}, 1000);
|
||||
}).toString() + ")()";
|
||||
'use strict';
|
||||
|
||||
window.eval(code);
|
||||
let checkReady = setInterval(function() {
|
||||
if (typeof Game.ready !== 'undefined' && Game.ready) {
|
||||
Game.LoadMod('https://aktanusa.github.io/CookieMonster/CookieMonsterBeta.js');
|
||||
clearInterval(checkReady);
|
||||
}
|
||||
}, 1000);
|
||||
```
|
||||
|
||||
# Bugs and suggestions
|
||||
|
||||
Reference in New Issue
Block a user