Ads overview
Show your own ads inside Playgent games — video or a display banner. One extra script, your own demand, no changes to your embed.
How it works
Ads are configured on your Player in the Hub and run as a separate, optional layer over the game. You enable ads on the player, set your demand once, and copy the embed snippet — which now includes a single extra line that loads the ads runtime. Your Playgent.init() call is unchanged.
Because the demand lives on the player (not in the snippet), rotating an ad unit or swapping a tag in the Hub goes live on every embed already on your site the next time you publish — no re-pasting.
Set it up in the Hub
- Open your player in the Hub and go to the Ads tab. (Ads are available on the Growth and Enterprise plans.)
- Toggle Enable ads, then for Pre-roll and/or Rewarded choose a format and enter your demand — a video ad (a Google Ad Manager network code + ad unit, or a full VAST tag) or a display banner (a network code + ad unit, with a size like 300×250).
- Save and publish, then copy the embed snippet from the playground.
The snippet you copy looks like this — your normal embed plus one ads line:
<div id="playgent-host-a1b2c"></div>
<script src="https://static.playgent.com/player/v2.js"></script>
<script>
Playgent.init({
containerId: "playgent-host-a1b2c",
game: "sudoku",
mode: "daily",
player: "plyr_acme_blog",
});
</script>
<script src="https://static.playgent.com/ads/v2.js?container=playgent-host-a1b2c"></script>
Paste it once. To change your demand later, edit the player in the Hub and republish — the same pasted snippet picks up the change.
Placements
Two placements are available. Configure either, or both — each takes its own demand.
- Pre-roll — an ad before the game starts, when the player presses Start or first touches the board.
- Rewarded — an ad when the player asks for a hint. The hint is granted after the ad completes.
Each placement can be a video ad or a display banner, chosen independently:
- Video — the game area fades to black with a short message, the video plays with pause / mute / countdown controls, and play resumes when the ad ends, is skipped, or errors.
- Display — the game area fades to black and shows your banner (for example 300×250) with a short countdown, then a Continue button. Play resumes when the player continues, or immediately if no ad fills.
You bring your own demand
Playgent does not supply ad inventory. You connect your own Google Ad Manager (or any VAST-compatible source). A video ad takes either a network code + ad unit or a full VAST tag URL; a display banner takes a network code + ad unit and a size. Whether the inventory is yours directly or sold through a partner, the setup is the same.
Player controls
Video ads render with pause, mute / unmute, and a time-remaining countdown, alongside Google's standard "Ad" attribution and skip controls. They start unmuted by default; on browsers that block unmuted autoplay the ad starts muted and the viewer can unmute with one tap.
Display banners render with a short countdown, then a Continue button that returns the player to the game.
Notes & limits
- Two formats. Each placement is either a video ad or a display banner, chosen per placement.
- Never blocks play. If demand is unfilled, the network is slow, or anything errors, the fail-safe lets play continue (and, for rewarded, still grants the hint).
- No changes to
Playgent.init. Ads are wired entirely through the player config + theads/v2.jsscript, so you can turn them on or off without touching your embed. - Live updates. With the Hub flow, changing demand and republishing updates every embed already on your site — no re-paste.