Poki Ad Skip Tool

A JavaScript tool that modifies PokiSDK ad callbacks to skip advertisement flows in browser games.

θα χρειαστεί να εγκαταστήσετε μια επέκταση όπως το Tampermonkey, το Greasemonkey ή το Violentmonkey για να εγκαταστήσετε αυτόν τον κώδικα.

You will need to install an extension such as Tampermonkey to install this script.

θα χρειαστεί να εγκαταστήσετε μια επέκταση όπως το Tampermonkey ή το Violentmonkey για να εγκαταστήσετε αυτόν τον κώδικα.

θα χρειαστεί να εγκαταστήσετε μια επέκταση όπως το Tampermonkey ή το Userscripts για να εγκαταστήσετε αυτόν τον κώδικα.

You will need to install an extension such as Tampermonkey to install this script.

Θα χρειαστεί να εγκαταστήσετε μια επέκταση διαχείρισης κώδικα χρήστη για να εγκαταστήσετε αυτόν τον κώδικα.

(Έχω ήδη έναν διαχειριστή κώδικα χρήστη, επιτρέψτε μου να τον εγκαταστήσω!)

Advertisement:

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(Έχω ήδη έναν διαχειριστή στυλ χρήστη, επιτρέψτε μου να τον εγκαταστήσω!)

Advertisement:

// ==UserScript==
// @name         Poki Ad Skip Tool
// @namespace    https://greasyfork.org/users/poki-ad-skip
// @version      1.0
// @description  A JavaScript tool that modifies PokiSDK ad callbacks to skip advertisement flows in browser games.
// @author       YourName
// @match        *://*.poki.com/*
// @match        *://*.poki-cdn.com/*
// @grant        none
// @license      MIT
// ==/UserScript==

(function() {
    'use strict';

    function injectBypass() {
        if (window.PokiSDK) {
            console.log("PokiSDK detected. Applying ad bypass...");

            try {
                Object.defineProperty(window.PokiSDK, 'rewardedBreak', {
                    get: function() {
                        return function() {
                            console.log("Rewarded ad requested -> Auto-rewarding.");
                            return Promise.resolve(true);
                        };
                    },
                    set: function() {},
                    configurable: true
                });

                Object.defineProperty(window.PokiSDK, 'commercialBreak', {
                    get: function() {
                        return function() {
                            console.log("Commercial ad requested -> Auto-skipping.");
                            return Promise.resolve();
                        };
                    },
                    set: function() {},
                    configurable: true
                });

            } catch (e) {
                window.PokiSDK.rewardedBreak = function() {
                    return Promise.resolve(true);
                };

                window.PokiSDK.commercialBreak = function() {
                    return Promise.resolve();
                };
            }

            return true;
        }

        return false;
    }

    const interval = setInterval(() => {
        if (injectBypass()) {
            clearInterval(interval);
        }
    }, 50);

})();