Add owop captcha bypass

This commit is contained in:
Lamp 2019-03-22 21:37:08 +00:00
parent 2f46a5ac36
commit 7114896ebe
2 changed files with 6 additions and 1 deletions

View File

@ -42,4 +42,6 @@ module.exports = {
"Breastmilk ♥ 7:45 AM" "Breastmilk ♥ 7:45 AM"
], ],
"owop_captcha_password": process.env.OWOP_CAPTCHA_PASSWORD,
} }

View File

@ -19,7 +19,10 @@ global.screenshotter = {
} }
try { try {
await page.goto('http://ourworldofpixels.com'); await page.goto('http://ourworldofpixels.com');
await page.evaluate(function () { OWOP.camera.zoom = 1; }); await page.evaluate(function () {
localStorage.owopcaptcha = require('./config').owop_captcha_password;
OWOP.camera.zoom = 1;
});
await new Promise(resolve => setTimeout(resolve, 2000)); await new Promise(resolve => setTimeout(resolve, 2000));
await page.evaluate(function () { await page.evaluate(function () {
for (let butt of document.getElementsByTagName('button')) { for (let butt of document.getElementsByTagName('button')) {