PolyWarriors launch trailer: Promo tools game card (player, 16:9 + vertical downloads, poster, caption, share) and the public games card plays it; poster replaces the coming-soon art
Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
@@ -10,7 +10,8 @@
|
||||
var ribbon = g.season ? '<span class="ribbon">Limited time · ends ' + esc(g.season.ends) + '</span>' : soon ? '<span class="ribbon soon">' + esc(g.opens) + '</span>' : '';
|
||||
var play = g.live && g.open ? '<a class="btn" href="' + esc(g.open) + '" target="_blank" rel="noopener">Play</a>' : '<span class="btn" aria-disabled="true">' + esc(g.opens || 'Opens soon') + '</span>';
|
||||
var site = g.host ? '<span class="host">' + esc(g.host) + '</span>' : '';
|
||||
return '<div class="gcard"><div class="art">' + (g.art ? '<img src="' + esc(g.art) + '" alt="" loading="lazy"' + (g.artPos ? ' style="object-position:' + esc(g.artPos) + ' center"' : '') + '>' : '') + ribbon + '</div>' +
|
||||
var art = g.video ? '<video controls playsinline preload="none" poster="' + esc(g.poster || g.art || '') + '" src="' + esc(g.video) + '" style="width:100%;height:100%;object-fit:cover;display:block;background:#000"></video>' : (g.art ? '<img src="' + esc(g.art) + '" alt="" loading="lazy"' + (g.artPos ? ' style="object-position:' + esc(g.artPos) + ' center"' : '') + '>' : '');
|
||||
return '<div class="gcard"><div class="art">' + art + ribbon + '</div>' +
|
||||
'<div class="body"><span class="tag">' + esc(g.tag || '') + '</span><h3>' + esc(g.name) + '</h3><p>' + esc(g.blurb || '') + '</p>' +
|
||||
(g.pays ? '<div class="pays">Pays: <b>' + esc(g.pays) + '</b></div>' : '') +
|
||||
'<div class="row">' + play + site + '</div></div></div>';
|
||||
|
||||
@@ -289,6 +289,9 @@ window.IAPPromo = (function () {
|
||||
{ name: 'Friendly post', text: 'If you like small games that actually pay something, this is the page I send people. Eight games, all free, all paying POL on Polygon for first clears, levels and daily puzzles. Pick one: {L}' },
|
||||
{ name: 'Telegram or WhatsApp line', text: 'All the games that pay POL, one page, free to play: {L}' }] },
|
||||
{ slug: 'polywarriors', name: 'PolyWarriors', link: 'https://www.polywarriors.com/?ref=', img: 'https://www.polywarriors.com/og-polywarriors.jpg', sub: 'cyberpunk battler with NFT warrior cards',
|
||||
// launch trailer (2026-10-12, Marty approved): 16:9 + 9:16 cuts and a poster on Spaces; the caption carries the member's link
|
||||
video: { base: 'https://coolify-saasytop.nyc3.digitaloceanspaces.com/promo/', file: 'polywarriors-trailer.mp4', portrait: 'polywarriors-trailer-portrait.mp4', poster: 'polywarriors-trailer.jpg', best: 'landscape for Facebook, X and YouTube; vertical for Shorts, Reels and TikTok',
|
||||
cap: 'PolyWarriors just opened: a free cyberpunk fighting game. Recruit warriors born with their own traits and rarity, beat 24 arena rivals, duel other members. First wins pay Polygon to your wallet and your first warrior mints free as an NFT. {L} #PolyWarriors #Polygon #NFT #gaming' },
|
||||
posts: [
|
||||
{ name: 'Short post', text: 'PolyWarriors is a free cyberpunk battler. Recruit warriors that are each born with their own traits and rarity, fight through 24 arena rivals, and challenge other members in duels that play out while you are away. Your first win over each rival pays Polygon to the wallet on your InstantAdPay account, and your first warrior mints to your wallet as an NFT, free. {L}' },
|
||||
{ name: 'Friendly post', text: 'I have been playing PolyWarriors, a turn-based fighting game with a cyberpunk look. Every warrior is one of a kind, you can mint yours, fuse three of a kind into something rarer, and battle other members. Free to play, and it pays Polygon for first wins: {L}' },
|
||||
@@ -336,6 +339,13 @@ window.IAPPromo = (function () {
|
||||
[linkBtn('https://x.com/intent/tweet?text=' + enc(posts[0].text), 'X'), linkBtn('https://www.facebook.com/sharer/sharer.php?u=' + enc(link), 'Facebook'), linkBtn('https://t.me/share/url?url=' + enc(link) + '&text=' + enc(hook), 'Telegram'), linkBtn('https://wa.me/?text=' + enc(posts[0].text), 'WhatsApp')].forEach(b => sh.appendChild(b));
|
||||
const gi = $('gmImg'); gi.hidden = true; gi.onload = () => { if (gi.dataset.want === g.img) gi.hidden = false; }; gi.onerror = () => { gi.hidden = true; }; gi.dataset.want = g.img; gi.src = g.img; // hidden until the new game's image loads (no stale picture) $('gmImg').alt = g.name; $('gmImgOpen').href = g.img;
|
||||
$('gmImgCopy').onclick = async () => { try { await navigator.clipboard.writeText(g.img); status('Image URL copied.', 'ok'); } catch (e) { status('Copy failed.', 'bad'); } };
|
||||
const gv = $('gmVideo'); if (gv) { gv.innerHTML = ''; gv.hidden = !g.video;
|
||||
if (g.video) { const v = g.video, cap = v.cap.replace('{L}', link); const d = document.createElement('div'); d.className = 'promo-block';
|
||||
d.innerHTML = '<div class="pb-head"><span class="lab">Trailer</span> <span class="muted small">Best on: ' + esc(v.best) + '</span></div><video controls playsinline preload="none" poster="' + v.base + v.poster + '" src="' + v.base + v.file + '" style="width:100%;max-width:480px;border-radius:12px;display:block;margin:8px auto;background:#000"></video><div class="pb-text">' + esc(cap) + '</div>';
|
||||
const row = document.createElement('div'); row.className = 'pb-actions';
|
||||
row.appendChild(linkBtn(v.base + v.file, 'Download 16:9')); if (v.portrait) row.appendChild(linkBtn(v.base + v.portrait, 'Download vertical')); row.appendChild(linkBtn(v.base + v.poster, 'Poster image')); row.appendChild(copyBtn(cap, 'Copy caption'));
|
||||
[linkBtn('https://x.com/intent/tweet?text=' + enc(cap), 'X'), linkBtn('https://www.facebook.com/sharer/sharer.php?u=' + enc(link), 'Facebook'), linkBtn('https://t.me/share/url?url=' + enc(link) + '&text=' + enc(cap.replace(link, '').trim()), 'Telegram'), linkBtn('https://wa.me/?text=' + enc(cap), 'WhatsApp')].forEach(b => row.appendChild(b));
|
||||
d.appendChild(row); gv.appendChild(d); } }
|
||||
const pp = $('gmPosts'); pp.innerHTML = '';
|
||||
for (const p of posts) pp.appendChild(block(p.text, '<span class="lab">' + esc(p.name) + '</span>', [linkBtn('https://x.com/intent/tweet?text=' + enc(p.text), 'X'), linkBtn('https://t.me/share/url?url=' + enc(link) + '&text=' + enc(p.text.replace(link, '').trim()), 'Telegram'), linkBtn('https://wa.me/?text=' + enc(p.text), 'WhatsApp')]));
|
||||
}
|
||||
|
||||
+1
-1
@@ -78,6 +78,6 @@
|
||||
<div class="small">Advertising services with a performance referral program. Not an investment product; no income guarantees.</div>
|
||||
</footer>
|
||||
</div>
|
||||
<script src="/assets/common.js?v=20261007a"></script><script src="/assets/games-page.js?v=20261011a"></script>
|
||||
<script src="/assets/common.js?v=20261007a"></script><script src="/assets/games-page.js?v=20261012b"></script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
+2
-1
@@ -790,6 +790,7 @@
|
||||
<div class="promo-block"><div class="pb-head"><span class="lab">Share image</span> <span class="muted small">1200×630, for posts and link previews</span></div>
|
||||
<img id="gmImg" alt="" style="max-width:100%;height:auto;border-radius:10px;display:block;margin:8px 0">
|
||||
<div class="pb-actions"><a class="btn small sec" id="gmImgOpen" href="#" target="_blank" rel="noopener">Open image</a> <button class="btn small sec" id="gmImgCopy" type="button">Copy image URL</button></div></div>
|
||||
<div id="gmVideo" hidden></div>
|
||||
<div class="card-head" style="margin-top:14px"><h3>Posts</h3><span class="sub">your link is already in them</span></div>
|
||||
<div id="gmPosts"></div>
|
||||
</div>
|
||||
@@ -1150,7 +1151,7 @@
|
||||
</div>
|
||||
<script src="/assets/common.js?v=20261007a"></script><script src="/assets/welcome.js?v=20260923b"></script>
|
||||
<script src="/assets/wallet.js?v=20260911a"></script>
|
||||
<script src="/assets/promo.js?v=20261012a"></script>
|
||||
<script src="/assets/promo.js?v=20261012b"></script>
|
||||
<script src="/assets/my.js?v=20261011a"></script>
|
||||
<script src="/assets/chat.js?v=20260907l"></script>
|
||||
</body>
|
||||
|
||||
@@ -1567,7 +1567,7 @@ function GAMES() {
|
||||
art: SW_URL() + '/og-spellwheel.jpg?v=1', play: '/api/my/spellwheel', pays: 'POL for levels, chapters and daily puzzles', soon: { opens: '2026-10-10', label: 'Opens Saturday, Oct 10' } },
|
||||
// PolyWarriors (Marty 2026-10-05: "put Poly Warriors there as well, saying that it's coming next Monday")
|
||||
{ slug: 'polywarriors', name: 'PolyWarriors', tag: 'Cyberpunk fighting', blurb: 'Turn-based fights with collectible low-poly warriors. Recruit fighters born with rare traits, climb the arena, challenge other members, and mint your warriors as NFTs.',
|
||||
art: '/assets/games/polywarriors-soon.jpg?v=1', play: '/api/my/polywarriors', pays: 'POL for first wins over arena rivals', soon: { opens: '2026-10-12', label: 'Opens Monday, Oct 12' } },
|
||||
art: 'https://coolify-saasytop.nyc3.digitaloceanspaces.com/promo/polywarriors-trailer.jpg', video: 'https://coolify-saasytop.nyc3.digitaloceanspaces.com/promo/polywarriors-trailer.mp4', play: '/api/my/polywarriors', pays: 'POL for first wins over arena rivals', soon: { opens: '2026-10-12', label: 'Opens Monday, Oct 12' } }, // live 10-12: trailer poster + 16:9 trailer on the public games page
|
||||
]);
|
||||
}
|
||||
// each game's member perk (the $5 welcome offer, 2026-10-05) shown on its card
|
||||
@@ -3454,7 +3454,7 @@ const server = http.createServer(async (req, res) => {
|
||||
const soon = !!(g.soon && day < g.soon.opens), preSeason = !!(g.season && day < g.season.start);
|
||||
const isLive = !soon && !preSeason && live.has(g.slug);
|
||||
if (!isLive && !soon && !preSeason) continue; // not live and no date: not announced yet
|
||||
out.push({ slug: g.slug, name: g.name, tag: g.tag, blurb: g.blurb, pays: g.pays, art: /^https?:/.test(g.art) ? g.art : 'https://instantadpay.com' + g.art, artPos: g.artPos || 'center', live: isLive,
|
||||
out.push({ slug: g.slug, name: g.name, tag: g.tag, blurb: g.blurb, pays: g.pays, art: /^https?:/.test(g.art) ? g.art : 'https://instantadpay.com' + g.art, artPos: g.artPos || 'center', live: isLive, video: isLive && g.video ? g.video : null,
|
||||
opens: soon ? g.soon.label : preSeason ? 'Opens ' + lbl(g.season.start) : null, season: g.season && isLive ? { ends: lbl(g.season.end, true) } : null, open: S[g.slug] ? S[g.slug].open : null, host: S[g.slug] ? S[g.slug].host : null });
|
||||
}
|
||||
return json(res, 200, { games: out }, { 'Access-Control-Allow-Origin': '*', 'Cache-Control': 'public, max-age=300' });
|
||||
|
||||
Reference in New Issue
Block a user