diff --git a/chatbot.js b/chatbot.js
index 040fd2b..27de67f 100644
--- a/chatbot.js
+++ b/chatbot.js
@@ -211,8 +211,8 @@ function passTiersFact() {
if (!t || !t.on) return soon;
const rows = (t.rows || []).filter(r => r.sale);
if (!rows.length) return soon;
- return '- GAME PASS TIERS (on sale, Members > Games > Game Pass at https://instantadpay.com/my#games): beside the $5 weekly Game Pass, ' + rows.map(r => r.name + ' $' + r.usd + ' for ' + r.days + ' days (' + 'paid by a new package of at least $' + r.usd + '): ' + r.perks.join('; ')).join(' | ')
- + '. Each higher pass includes everything below it. Every pass is a Game Pass in all nine games with the SAME daily POL caps (1.50 / 5 POL): a higher pass never pays more POL. Passes run side by side, each with its own end date; no auto-renew; buying again adds the pass length from its end date (or from now if it ended). Every pass is paid by a NEW package purchase of at least its price, made after tapping Get on that pass; the pass starts when it settles, the sponsor and team are paid from the package as usual, and the member keeps the package credits for ads. Credits already held never buy a pass. Nothing earned in a game is taken away when a pass ends.\n';
+ return '- GAME PASS TIERS (on sale, Members > Games > Game Pass at https://instantadpay.com/my#games): beside the $5 weekly Game Pass, ' + rows.map(r => r.name + ' $' + r.usd + ' for ' + r.days + ' days (' + 'paid by the $' + r.usd + ' package, and the member keeps that package’s ad credits): ' + r.perks.join('; ')).join(' | ')
+ + '. Each higher pass includes everything below it. Every pass is a Game Pass in all nine games with the SAME daily POL caps (1.50 / 5 POL): a higher pass never pays more POL. Passes run side by side, each with its own end date; no auto-renew; buying again adds the pass length from its end date (or from now if it ended). Every pass is paid by a NEW package purchase of at least its price, made after tapping Get on that pass (since 2026-10-25 every pass price IS a one-click package amount: $5, $20, $50, $100, $250, so the right package is exactly the price); the pass starts when it settles, the sponsor and team are paid from the package as usual, and the member keeps the package credits for ads. Credits already held never buy a pass. Nothing earned in a game is taken away when a pass ends.\n';
}
// the refuel fact follows the refuelStreak switch: while it is off the assistant says it is not live yet (2026-10-24)
let REFUEL_ON = () => false;
diff --git a/docs/GAME-PASS.md b/docs/GAME-PASS.md
index d07223d..0fa42bb 100644
--- a/docs/GAME-PASS.md
+++ b/docs/GAME-PASS.md
@@ -221,16 +221,18 @@ sales. If the POL rate is unavailable the tick retries next hour.
## Pass tiers: Explorer, Champion, Sovereign, Legend (IAP side, 2026-10-18; restructured 2026-10-22)
Spec: `ultima-rpg/docs/IAP-PASSES-SPEC.md`. Marty approved the safe form on 2026-10-18 (never more POL) and Dallas's new structure
-on 2026-10-22 (prices below, plus Sovereign and the yearly Legend). The weekly pass is unchanged. Everything above weekly stays
+on 2026-10-22 (plus Sovereign and the yearly Legend). On 2026-10-25 Marty set every tier price to an InstantAdPay one-click
+package amount ($5, $10, $20, $50, $100, $250, $500), so the cheapest qualifying package is exactly the pass price and the pass
+comes with that package's ad credits (was $19.99 / $39.99 / $99.99 / $249.99). The weekly pass is unchanged. Everything above weekly stays
switched off for members (`sovTiers` 0) until Marty flips it.
| Tier | Name | Price | Length | In Shards of Valor (each includes everything below) |
|---|---|---|---|---|
| `weekly` | Game Pass | 500 credits ($5) | 7 days | the Game Pass in all nine games, the Sunless Vault, weapons unlocked |
-| `explorer` | Explorer | 1999 ($19.99) | 30 days | weapons, gear, 2 DLC islands |
-| `champion` | Champion | 3999 ($39.99) | 30 days | weapons, gear, 4 DLC islands of your choice, the Druid hero, level cap 30 |
-| `sovereign` | Sovereign | 9999 ($99.99) | 30 days | weapons, gear, all DLC islands, the Necromancer hero, level cap 40 |
-| `legend` | Legend | 24999 ($249.99) | 365 days | weapons, gear, all DLC islands, every hero including the Archer, level cap 40 |
+| `explorer` | Explorer | 2000 ($20, the Activation package) | 30 days | weapons, gear, 2 DLC islands |
+| `champion` | Champion | 5000 ($50, the Builder package) | 30 days | weapons, gear, 4 DLC islands of your choice, the Druid hero, level cap 30 |
+| `sovereign` | Sovereign | 10000 ($100, the Growth package) | 30 days | weapons, gear, all DLC islands, the Necromancer hero, level cap 40 |
+| `legend` | Legend | 25000 ($250, the Leader package) | 365 days | weapons, gear, all DLC islands, every hero including the Archer, level cap 40 |
- **One table**: `gamepass.js` `TIER_DEFS` holds the rank, wire key, display name, settings stem, default price/length and the
member-card list for every tier. Rename a tier there (the card, admin pane, charge label and chatbot all read it).
@@ -247,16 +249,16 @@ switched off for members (`sovTiers` 0) until Marty flips it.
member view). The admin tests them in Admin > Game Pass > Tier test and preview (`GET /api/admin/gamepass/preview`, `POST
/api/admin/gamepass/test-buy | test-cancel | test-comp { tier }`, always the signed-in admin's own account). Short of purchased credits: a
waiting order per tier; a package of at least the tier price fulfils the highest-priced order it covers (one pass per purchase,
- each tx once). Copy names the package that covers the price: $20 (Explorer), $50 (Champion, there is no $40 one), $100
- (Sovereign), $250 (Legend).
+ each tx once). Copy names the package that pays for the pass, which since 2026-10-25 is exactly the price: $20 (Explorer), $50
+ (Champion), $100 (Sovereign), $250 (Legend); the card says the pass comes with that package's ad credits.
- **Renew / expiry**: no auto-renew, no proration. Buying again extends that tier from `max(now, until)` by its length (Legend: 365
days). Tiers run side by side; when a higher one ends the next one shows through. Admin comp takes a tier;
`POST /api/admin/gamepass/revoke { email, tier, why }` ends one tier now (support refunds only, credits are not returned by it).
- **Tournament**: any tier holds a seat; only weekly sales feed the pool unless `passTournamentTierSales` is `1` (then every tier's
sales do).
- **Settings** (defaults): `sovTiers` 0; kill switches `gamePassExplorerEnabled` / `gamePassChampionEnabled` /
- `gamePassSovereignEnabled` / `gamePassLegendEnabled` 1 (a `0` stops one tier); `gamePassExplorerPriceCredits` 1999,
- `gamePassChampionPriceCredits` 3999, `gamePassSovereignPriceCredits` 9999, `gamePassLegendPriceCredits` 24999;
+ `gamePassSovereignEnabled` / `gamePassLegendEnabled` 1 (a `0` stops one tier); `gamePassExplorerPriceCredits` 2000,
+ `gamePassChampionPriceCredits` 5000, `gamePassSovereignPriceCredits` 10000, `gamePassLegendPriceCredits` 25000;
`gamePassExplorerDays` / `gamePassChampionDays` / `gamePassSovereignDays` 30, `gamePassLegendDays` 365;
`passTournamentTierSales` 0. A value saved in the site settings file wins over these defaults.
- **Chatbot**: while `sovTiers` is off the assistant only says more passes are coming soon (no prices, no contents, no date); once
diff --git a/gamepass.js b/gamepass.js
index 095b2cb..554ff57 100644
--- a/gamepass.js
+++ b/gamepass.js
@@ -28,6 +28,9 @@
// 2026-10-22 (Dallas's structure, Marty approved): Explorer $19.99 and Champion $39.99 (30 days), plus Sovereign $99.99 (30 days)
// and Legend $249.99 (365 days, the yearly pass), all in TIER_DEFS below and all behind the same sovTiers switch. The weekly
// pass is unchanged ($5 / 7 days / the same caps). Rank weekly < explorer < champion < sovereign < legend.
+// 2026-10-25 (Marty): every tier price equals an InstantAdPay one-click package, so the cheapest qualifying package is exactly
+// the pass price (no silent overpay): Explorer $20 (was 19.99), Champion $50 (was 39.99), Sovereign $100 (was 99.99), Legend
+// $250 (was 249.99); weekly $5 unchanged. The pass comes with that package's ad credits.
'use strict';
const fs = require('fs');
const path = require('path');
@@ -46,13 +49,13 @@ const KEEP_DAYS = 90; // answered refs and day rows are kept this long
const TIER_DEFS = [
{ key: 'weekly', name: 'Game Pass', set: '', price: 500, days: 7,
perks: ['Higher daily POL caps in every game', 'A seat in the weekly Pass Tournament', 'Extra plays and a perk in each game', 'Shards of Valor: the Sunless Vault and weapons unlocked'] },
- { key: 'explorer', name: 'Explorer', set: 'Explorer', price: 1999, days: 30,
+ { key: 'explorer', name: 'Explorer', set: 'Explorer', price: 2000, days: 30,
perks: ['Everything in the Game Pass, in every game', 'Shards of Valor: weapons and gear unlocked', 'Shards of Valor: 2 bonus islands'] },
- { key: 'champion', name: 'Champion', set: 'Champion', price: 3999, days: 30,
+ { key: 'champion', name: 'Champion', set: 'Champion', price: 5000, days: 30,
perks: ['Everything in Explorer', 'Shards of Valor: 4 bonus islands of your choice', 'Shards of Valor: the Druid hero', 'Shards of Valor: level cap 30'] },
- { key: 'sovereign', name: 'Sovereign', set: 'Sovereign', price: 9999, days: 30,
+ { key: 'sovereign', name: 'Sovereign', set: 'Sovereign', price: 10000, days: 30,
perks: ['Everything in Champion', 'Shards of Valor: every bonus island', 'Shards of Valor: the Necromancer hero', 'Shards of Valor: level cap 40'] },
- { key: 'legend', name: 'Legend', set: 'Legend', price: 24999, days: 365,
+ { key: 'legend', name: 'Legend', set: 'Legend', price: 25000, days: 365,
perks: ['Everything in Sovereign, for a full year', 'Shards of Valor: every bonus island', 'Shards of Valor: every hero, the Archer included', 'Shards of Valor: level cap 40'] },
];
const TIERS = TIER_DEFS.map(d => d.key); // lowest to highest
diff --git a/public/admin.html b/public/admin.html
index c0ff0cf..65bc646 100644
--- a/public/admin.html
+++ b/public/admin.html
@@ -584,7 +584,7 @@
Every pass is paid by a new package purchase of at least its price (since 2026-10-22; credits never buy a pass). The *PriceCredits settings are the pass price in cents. Settings live in Settings › Site settings: gamePassEnabled (1/0), gamePassPriceCredits, gamePassDays, capFreeDaily, capFreeTotal, capPassDaily, capPassTotal, capsStartDate (Central YYYY-MM-DD; empty = caps recorded, not enforced), passTournamentPct, telegramGamesTopicId. Tiers above weekly: sovTiers (1/0, the sale switch for all of them; off = members never see them and the admin tests them in Tier test and preview above, never on the member card), gamePassExplorerEnabled / gamePassChampionEnabled / gamePassSovereignEnabled / gamePassLegendEnabled (0 stops one tier), gamePassExplorerPriceCredits (1999), gamePassChampionPriceCredits (3999), gamePassSovereignPriceCredits (9999), gamePassLegendPriceCredits (24999), gamePassExplorerDays / gamePassChampionDays / gamePassSovereignDays (30), gamePassLegendDays (365), passTournamentTierSales (1 = their sales feed the tournament pool; default 0). Prize POL is paid by the games from their faucets (GET /api/partner/tournament/pending), not from here.
+ Every pass is paid by a new package purchase of at least its price (since 2026-10-22; credits never buy a pass). The *PriceCredits settings are the pass price in cents. Settings live in Settings › Site settings: gamePassEnabled (1/0), gamePassPriceCredits, gamePassDays, capFreeDaily, capFreeTotal, capPassDaily, capPassTotal, capsStartDate (Central YYYY-MM-DD; empty = caps recorded, not enforced), passTournamentPct, telegramGamesTopicId. Tiers above weekly: sovTiers (1/0, the sale switch for all of them; off = members never see them and the admin tests them in Tier test and preview above, never on the member card), gamePassExplorerEnabled / gamePassChampionEnabled / gamePassSovereignEnabled / gamePassLegendEnabled (0 stops one tier), gamePassExplorerPriceCredits (2000), gamePassChampionPriceCredits (5000), gamePassSovereignPriceCredits (10000), gamePassLegendPriceCredits (25000); since 2026-10-25 every tier price equals a one-click package ($5, $20, $50, $100, $250), gamePassExplorerDays / gamePassChampionDays / gamePassSovereignDays (30), gamePassLegendDays (365), passTournamentTierSales (1 = their sales feed the tournament pool; default 0). Prize POL is paid by the games from their faucets (GET /api/partner/tournament/pending), not from here.
diff --git a/public/assets/my.js b/public/assets/my.js
index 0bc359a..56fdd09 100644
--- a/public/assets/my.js
+++ b/public/assets/my.js
@@ -1904,6 +1904,9 @@ function shareLink(ref) { return SHARE_DOMAIN && /^[A-Za-z0-9_]{1,40}$/.test(Str
explorer: ['Everything in the Game Pass, in every game', 'Shards of Valor: up to 4 bonus islands you pick (1 swap a month)', 'Explorer outfits and gear styles for your character'],
champion: ['Everything in Explorer', 'Shards of Valor: every bonus island, now and future', 'Champion outfits and gear styles for your character'],
};
+ // 2026-10-25 (Marty): every pass price equals a one-click package ($5, $20, $50, $100, $250), so the pass comes with exactly that
+ // package's ad credits (the base credits per package, same table as Buy packages; day bonuses can add more)
+ const GP_PKG_CREDITS = { 5: 500, 10: 1000, 20: 2000, 50: 5500, 100: 12000, 250: 32500, 500: 70000 };
const gpLen = d => d >= 365 && d % 365 === 0 ? (d === 365 ? '1 year' : (d / 365) + ' years') : d + ' days';
function renderPassTiers(card, gp, highlight) {
const rows = gp.passes || []; const top = rows.find(r => r.tier === gp.tier);
@@ -1917,6 +1920,7 @@ function shareLink(ref) { return SHARE_DOMAIN && /^[A-Za-z0-9_]{1,40}$/.test(Str
: '
Not on sale right now. Your pass keeps running.';
return '
' + esc(r.name) + '
'
+ '
$' + r.usd + ' for ' + gpLen(r.days) + '
'
+ + '
Comes with the $' + r.package + ' package and its ' + (GP_PKG_CREDITS[r.package] ? GP_PKG_CREDITS[r.package].toLocaleString('en-US') + ' ' : '') + 'ad credits.
'
+ '
' + (r.perks || GP_TIER_PERKS[r.tier] || []).map(x => '- ' + esc(x) + '
').join('') + '
'
+ '
' + (r.active ? 'Active until ' + esc(gpCT(r.until)) + '' : r.waiting ? 'Waiting for a $' + r.package + ' package' : 'Not active') + '
'
+ btn + '
';
diff --git a/public/my.html b/public/my.html
index 8f38f04..90ac978 100644
--- a/public/my.html
+++ b/public/my.html
@@ -1223,7 +1223,7 @@
-
+
diff --git a/qa/sov-passes-local.mjs b/qa/sov-passes-local.mjs
index ffdb375..3c2db7b 100644
--- a/qa/sov-passes-local.mjs
+++ b/qa/sov-passes-local.mjs
@@ -28,7 +28,7 @@ const B = 'http://127.0.0.1:' + PORT;
const SHOTS = process.env.SHOTS || 'D:/tmp/sov-passes'; fs.mkdirSync(SHOTS, { recursive: true });
const SOV = crypto.randomBytes(24).toString('hex'); // throwaway, never printed
const ADMIN_PW = 'localtest', ADMIN_EMAIL = 'qa-admin@example.com', MEMBER = 'qa-sov-member@example.com';
-const SEED_ID = 9001, SEED_CREDITS = 1999 + 9999 + 500; // Explorer + Sovereign, then 500 left (short for a second Explorer)
+const SEED_ID = 9001, SEED_CREDITS = 2000 + 10000 + 500; // Explorer + Sovereign, then 500 left (short for a second Explorer)
const DATA = fs.mkdtempSync(path.join(os.tmpdir(), 'iap-sovpasses-')); fs.mkdirSync(path.join(DATA, 'uploads'));
let fails = 0; const ok = (c, label, extra) => { console.log((c ? 'PASS ' : 'FAIL ') + label + (extra ? ' ' + extra : '')); if (!c) fails++; };
const hide = page => page.evaluate(() => { document.querySelectorAll('.lgate,.iap-welcome,#onboardModal').forEach(m => m.hidden = true); });
@@ -77,8 +77,8 @@ try {
ok(up && /qa stub: position #9001/.test(srvLog), 'local copy up with the seeded position', '');
await api('/api/admin/site', { method: 'PATCH', data: { fraudMaxSignupsPerIpDay: 10, gamePassEnabled: '1' } }, adminH);
const site = (await api('/api/admin/site', null, adminH)).j; const sc = (site && (site.site || site)) || {};
- ok(sc.sovTiers === '0' && Number(sc.gamePassExplorerPriceCredits) === 1999 && Number(sc.gamePassChampionPriceCredits) === 3999 && Number(sc.gamePassExplorerDays) === 30 && sc.passTournamentTierSales === '0', 'defaults: sovTiers 0, Explorer 1999 / Champion 3999 credits, 30 days, passTournamentTierSales 0', JSON.stringify({ sovTiers: sc.sovTiers, e: sc.gamePassExplorerPriceCredits, c: sc.gamePassChampionPriceCredits }));
- ok(Number(sc.gamePassSovereignPriceCredits) === 9999 && Number(sc.gamePassSovereignDays) === 30 && sc.gamePassSovereignEnabled === '1' && Number(sc.gamePassLegendPriceCredits) === 24999 && Number(sc.gamePassLegendDays) === 365 && sc.gamePassLegendEnabled === '1' && Number(sc.gamePassPriceCredits) === 500 && Number(sc.gamePassDays) === 7, 'defaults: Sovereign 9999 / 30 days, Legend 24999 / 365 days (kill switches 1), weekly 500 / 7 unchanged', JSON.stringify({ s: [sc.gamePassSovereignPriceCredits, sc.gamePassSovereignDays], l: [sc.gamePassLegendPriceCredits, sc.gamePassLegendDays] }));
+ ok(sc.sovTiers === '0' && Number(sc.gamePassExplorerPriceCredits) === 2000 && Number(sc.gamePassChampionPriceCredits) === 5000 && Number(sc.gamePassExplorerDays) === 30 && sc.passTournamentTierSales === '0', 'defaults: sovTiers 0, Explorer 2000 / Champion 5000 cents ($20 / $50, 2026-10-25), 30 days, passTournamentTierSales 0', JSON.stringify({ sovTiers: sc.sovTiers, e: sc.gamePassExplorerPriceCredits, c: sc.gamePassChampionPriceCredits }));
+ ok(Number(sc.gamePassSovereignPriceCredits) === 10000 && Number(sc.gamePassSovereignDays) === 30 && sc.gamePassSovereignEnabled === '1' && Number(sc.gamePassLegendPriceCredits) === 25000 && Number(sc.gamePassLegendDays) === 365 && sc.gamePassLegendEnabled === '1' && Number(sc.gamePassPriceCredits) === 500 && Number(sc.gamePassDays) === 7, 'defaults: Sovereign 10000 / 30 days, Legend 25000 / 365 days (kill switches 1), weekly 500 / 7 unchanged', JSON.stringify({ s: [sc.gamePassSovereignPriceCredits, sc.gamePassSovereignDays], l: [sc.gamePassLegendPriceCredits, sc.gamePassLegendDays] }));
const hA = await signIn(ADMIN_EMAIL, 'qaadmin'), hM = await signIn(MEMBER, 'qasovm');
// 1. a member with sovTiers off: weekly only, Explorer refused
@@ -105,7 +105,7 @@ try {
await page.locator('#gpCard').screenshot({ path: path.join(SHOTS, '2-admin-member-card-weekly-only.png') }); await ctx.close(); }
// the admin portal preview: all five tiers with what each includes, every one open to the admin's own account
g = (await api('/api/admin/gamepass/preview', null, adminH)).j;
- ok(g.test === true && g.email === ADMIN_EMAIL && g.tierPreview === true && g.passes.map(x => x.tier).join() === 'weekly,explorer,champion,sovereign,legend' && g.passes.map(x => x.price).join() === '500,1999,3999,9999,24999' && g.passes.every(x => x.open) && g.passes.filter(x => x.tier !== 'weekly').every(x => x.sale === false), 'GET /api/admin/gamepass/preview: all five tiers (500 / 1999 / 3999 / 9999 / 24999), open to the admin, none on sale', JSON.stringify(g.passes.map(x => [x.tier, x.price, x.open, x.sale])));
+ ok(g.test === true && g.email === ADMIN_EMAIL && g.tierPreview === true && g.passes.map(x => x.tier).join() === 'weekly,explorer,champion,sovereign,legend' && g.passes.map(x => x.price).join() === '500,2000,5000,10000,25000' && g.passes.map(x => x.package).join() === '5,20,50,100,250' && g.passes.every(x => x.usd === x.package) && g.passes.every(x => x.open) && g.passes.filter(x => x.tier !== 'weekly').every(x => x.sale === false), 'GET /api/admin/gamepass/preview: all five tiers (500 / 2000 / 5000 / 10000 / 25000, each price = its package), open to the admin, none on sale', JSON.stringify(g.passes.map(x => [x.tier, x.price, x.open, x.sale])));
ok((await api('/api/admin/gamepass/preview', null, hM)).status === 401 && (await api('/api/admin/gamepass/test-buy', { data: { tier: 'explorer' } }, hM)).status === 401, 'tier test endpoints refuse a member session (401)', '');
// test cancel + test comp + end, on the admin's own account
r = await api('/api/admin/gamepass/test-buy', { data: { tier: 'champion' } }, adminH);
@@ -123,7 +123,7 @@ try {
await page.fill('#adEmail', ADMIN_EMAIL); await page.click('#adSend'); await page.waitForSelector('#adVerify:not([hidden])'); await page.click('#adVerify'); await sleep(1200);
const nav = await page.$('.bo-menu [data-pane="gamepass"]'); if (nav) { await nav.click(); await page.waitForSelector('#gpTest [data-gpt-buy="explorer"]', { timeout: 10000 }).catch(() => {}); }
let txt = await page.textContent('#gpTest').catch(() => '');
- ok(/Test \/ preview, admin only/.test(txt) && /hidden from members/.test(txt) && /Sovereign/.test(txt) && /Necromancer/.test(txt) && /Legend/.test(txt) && /\$249\.99/.test(txt) && /for 1 year/.test(txt) && /Archer/.test(txt) && /Druid/.test(txt) && /level cap 30/.test(txt) && /\$19\.99/.test(txt) && /Shards of Valor > Passes/.test(txt) && !/\u2014/.test(txt) && errs.length === 0, 'Admin > Game Pass > Tier test and preview: labelled test/preview, all five tiers with what each includes, no em dashes', errs.join(' | ') || (nav ? '' : 'admin nav not found'));
+ ok(/Test \/ preview, admin only/.test(txt) && /hidden from members/.test(txt) && /Sovereign/.test(txt) && /Necromancer/.test(txt) && /Legend/.test(txt) && /\$250 /.test(txt) && /for 1 year/.test(txt) && /Archer/.test(txt) && /Druid/.test(txt) && /level cap 30/.test(txt) && /\$20 /.test(txt) && !/\.99/.test(txt) && /Shards of Valor > Passes/.test(txt) && !/\u2014/.test(txt) && errs.length === 0, 'Admin > Game Pass > Tier test and preview: labelled test/preview, all five tiers with what each includes, no em dashes', errs.join(' | ') || (nav ? '' : 'admin nav not found'));
await page.locator('#gpTestCard').scrollIntoViewIfNeeded(); await sleep(300);
await page.locator('#gpTestCard').screenshot({ path: path.join(SHOTS, '3-admin-tier-test-panel.png') });
await page.click('#gpTest [data-gpt-buy="explorer"]'); await page.waitForSelector('#dlgOk', { timeout: 5000 });
@@ -164,7 +164,7 @@ try {
const gr = await grant({ memberId: 0, email: ADMIN_EMAIL, game: 'shardsofvalor', kind: 'daily', pol: 0.2, ref: 'qa:1' });
ok(gr.pass === true && gr.allowed === 0.2, 'polgrant: pass true (a boolean) for the Explorer holder', JSON.stringify(gr));
- // 3b. Sovereign (9999 credits, 30 days) and the yearly Legend (24999, 365 days), 2026-10-22: the admin buys Sovereign through the
+ // 3b. Sovereign (10000 cents = $100, 30 days) and the yearly Legend (25000 = $250, 365 days), 2026-10-22: the admin buys Sovereign through the
// real charge, then is short for Legend (waiting order, $250 package) and for a second Explorer; a $250 package settles Legend.
r = await api('/api/admin/gamepass/test-buy', { data: { tier: 'sovereign' } }, adminH);
ok(r.status === 200 && r.j.needPay === true && r.j.tier === 'sovereign' && r.j.package === 100, 'admin Sovereign (sovTiers off, testing): a waiting order for a $100 package, credits untouched', JSON.stringify(r.j));
@@ -174,7 +174,7 @@ try {
r = await api('/api/admin/gamepass/test-buy', { data: { tier: 'explorer' } }, adminH);
ok(r.status === 200 && r.j.needPay === true && r.j.tier === 'explorer' && /package of \$20 or more/.test(r.j.message), 'a second Explorer -> waiting order, "package of $20 or more"', JSON.stringify({ needPay: r.j.needPay, payUrl: r.j.payUrl, msg: r.j.message }));
r = await api('/api/admin/gamepass/test-buy', { data: { tier: 'legend' } }, adminH);
- ok(r.status === 200 && r.j.needPay === true && r.j.tier === 'legend' && r.j.price === 24999 && r.j.payUrl === '/my?from=gamepass&tier=legend#buy' && /package of \$250 or more/.test(r.j.message), 'Legend: waiting order, "package of $250 or more", payUrl with tier', JSON.stringify({ needPay: r.j.needPay, payUrl: r.j.payUrl, msg: r.j.message }));
+ ok(r.status === 200 && r.j.needPay === true && r.j.tier === 'legend' && r.j.price === 25000 && r.j.payUrl === '/my?from=gamepass&tier=legend#buy' && /package of \$250 or more/.test(r.j.message), 'Legend: waiting order, "package of $250 or more", payUrl with tier', JSON.stringify({ needPay: r.j.needPay, payUrl: r.j.payUrl, msg: r.j.message }));
let dv = (await api('/api/dev/gamepass-purchase', { data: { cents: 10000, email: ADMIN_EMAIL } })).j;
ok(dv && dv.order && dv.order.tier === 'explorer' && dv.order.until === ex.until + 30 * 86400000, 'a $100 package fulfils the waiting Explorer (extends it from its end), never Legend', JSON.stringify(dv));
g = (await api('/api/admin/gamepass/preview', null, adminH)).j;
@@ -193,8 +193,8 @@ try {
// 4. Admin > Game Pass: the tier table
const st = (await api('/api/admin/gamepass/stats', null, adminH)).j;
- ok(st.tiers && st.tiers.explorer.active === 0 && st.tiers.explorer.soldTotal === 2 && st.tiers.explorer.usdTotal === 39.98 && st.tiers.explorer.waitingOrders === 0 && st.tierSales === false, 'admin stats: Explorer 2 sold ($39.98: credits + the $100 package order), not counted active (the account is at Legend); sale switch off', JSON.stringify(st.tiers.explorer));
- ok(st.tiers.sovereign && st.tiers.sovereign.active === 0 && st.tiers.sovereign.soldTotal === 1 && st.tiers.sovereign.usdTotal === 99.99 && st.tiers.legend.active === 1 && st.tiers.legend.soldTotal === 1 && st.tiers.legend.usdTotal === 249.99 && st.tiers.legend.waitingOrders === 0 && st.settings.tiers.legend.days === 365 && st.settings.tiers.sovereign.sale === false, 'admin stats: Sovereign 1 sold ($99.99), Legend 1 active + 1 sold ($249.99), not on sale', JSON.stringify({ s: st.tiers.sovereign, l: st.tiers.legend }));
+ ok(st.tiers && st.tiers.explorer.active === 0 && st.tiers.explorer.soldTotal === 2 && st.tiers.explorer.usdTotal === 40 && st.tiers.explorer.waitingOrders === 0 && st.tierSales === false, 'admin stats: Explorer 2 sold ($40: credits + the $100 package order), not counted active (the account is at Legend); sale switch off', JSON.stringify(st.tiers.explorer));
+ ok(st.tiers.sovereign && st.tiers.sovereign.active === 0 && st.tiers.sovereign.soldTotal === 1 && st.tiers.sovereign.usdTotal === 100 && st.tiers.legend.active === 1 && st.tiers.legend.soldTotal === 1 && st.tiers.legend.usdTotal === 250 && st.tiers.legend.waitingOrders === 0 && st.settings.tiers.legend.days === 365 && st.settings.tiers.sovereign.sale === false, 'admin stats: Sovereign 1 sold ($100), Legend 1 active + 1 sold ($250), not on sale', JSON.stringify({ s: st.tiers.sovereign, l: st.tiers.legend }));
{ const ctx = await browser.newContext({ viewport: { width: 1280, height: 1000 } }); const page = await ctx.newPage(); const errs = []; page.on('pageerror', e => errs.push(String(e)));
await page.goto(B + '/admin', { waitUntil: 'networkidle' });
await page.fill('#adEmail', ADMIN_EMAIL); await page.click('#adSend'); await page.waitForSelector('#adVerify:not([hidden])'); await page.click('#adVerify'); await sleep(1200);
diff --git a/qa/sov-passes-store.cjs b/qa/sov-passes-store.cjs
index 51c8566..0614162 100644
--- a/qa/sov-passes-store.cjs
+++ b/qa/sov-passes-store.cjs
@@ -4,7 +4,7 @@
// extend from max(now, until), side-by-side expiry, highest active tier wins, the sovTiers switch (off refuses, admin may buy),
// waiting orders per tier fulfilled by a big-enough package (each tx once, highest price first), the same caps for every tier
// (no extra POL), comp and revoke, admin stats per tier (each account once at its top tier, Central week/month). Exit 1 on failure.
-// 2026-10-22: section 10 adds Sovereign (9999 / 30 days) and the yearly Legend (24999 / 365 days): rank, off-switch refusal,
+// 2026-10-22: section 10 adds Sovereign (10000 / 30 days) and the yearly Legend (25000 / 365 days; prices = packages since 2026-10-25): rank, off-switch refusal,
// buy, short -> waiting order ($100 / $250 package), extend from max(now, until), kill switches, comp/revoke, flag payload, stats.
'use strict';
const fs = require('fs'); const os = require('os'); const path = require('path');
@@ -55,7 +55,7 @@ async function buyX(email, payer, now, tier, opts) {
ok(v.passes.length === 1 && v.passes[0].tier === 'weekly' && v.show === true && v.tierPreview === false, 'sovTiers off: a member sees only the weekly pass', JSON.stringify(v.passes.map(x => x.tier)));
v = gp.view('admin@x.com', T0); ok(v.passes.length === 1 && !v.tierPreview, 'the member view (GET /api/my/gamepass) is the same for the admin account: weekly only (2026-10-25)', JSON.stringify(v.passes.map(x => x.tier)));
v = gp.view('admin@x.com', T0, { preview: true }); // Admin > Game Pass > Tier test and preview
- ok(v.passes.map(x => x.tier).join() === 'weekly,explorer,champion,sovereign,legend' && v.tierPreview === true && v.passes.slice(1).every(x => x.open === true) && v.passes.map(x => x.price).join() === '500,1999,3999,9999,24999' && v.passes.map(x => x.days).join() === '7,30,30,30,365' && v.passes.map(x => x.package).join() === '5,20,50,100,250', 'sovTiers off: the admin sees all five (preview), prices 500 / 1999 / 3999 / 9999 / 24999, days 7 / 30 / 30 / 30 / 365, packages $5 / $20 / $50 / $100 / $250', JSON.stringify(v.passes));
+ ok(v.passes.map(x => x.tier).join() === 'weekly,explorer,champion,sovereign,legend' && v.tierPreview === true && v.passes.slice(1).every(x => x.open === true) && v.passes.map(x => x.price).join() === '500,2000,5000,10000,25000' && v.passes.map(x => x.days).join() === '7,30,30,30,365' && v.passes.map(x => x.package).join() === '5,20,50,100,250', 'sovTiers off: the admin sees all five (preview), prices 500 / 2000 / 5000 / 10000 / 25000, days 7 / 30 / 30 / 30 / 365, packages $5 / $20 / $50 / $100 / $250', JSON.stringify(v.passes));
r = await buyX('admin@x.com', paid, T0, 'explorer', { preview: true });
ok(r.ok && r.tier === 'explorer' && r.until === T0 + 30 * DAY && r.days === 30, 'sovTiers off: the admin can buy Explorer (testing)', JSON.stringify(r));
r = await buyX('a@x.com', paid, T0); // tier missing = weekly
@@ -69,15 +69,15 @@ async function buyX(email, payer, now, tier, opts) {
// 3. on: each tier extends only itself; buying again extends from max(now, until)
charged = null; r = await buyX('b@x.com', async (price, label) => { charged = { price, label }; return { ok: true }; }, T0, 'explorer');
- ok(r.ok && r.until === T0 + 30 * DAY && charged.price === 1999 && charged.label === 'Explorer pass (30 days)', 'sovTiers on: Explorer charges 1999 credits, 30 days', JSON.stringify(charged));
+ ok(r.ok && r.until === T0 + 30 * DAY && charged.price === 2000 && charged.label === 'Explorer pass (30 days)', 'sovTiers on: Explorer charges 2000 credits, 30 days', JSON.stringify(charged));
let rec = passes.get('b@x.com');
- ok(rec.tiers.explorer.until === T0 + 30 * DAY && !rec.tiers.weekly && !rec.tiers.champion && rec.until === 0 && rec.bought[0].tier === 'explorer' && rec.bought[0].usd === 19.99, 'only the Explorer tier moved; legacy until (weekly) stays 0; bought row has tier + $19.99', JSON.stringify(rec));
+ ok(rec.tiers.explorer.until === T0 + 30 * DAY && !rec.tiers.weekly && !rec.tiers.champion && rec.until === 0 && rec.bought[0].tier === 'explorer' && rec.bought[0].usd === 20, 'only the Explorer tier moved; legacy until (weekly) stays 0; bought row has tier + $20', JSON.stringify(rec));
r = await buyX('b@x.com', paid, T0 + 10 * DAY, 'explorer');
ok(r.until === T0 + 60 * DAY, 'Explorer again while active: extends from its until (+30 days, nothing lost)', new Date(r.until).toISOString());
r = await buyX('c@x.com', paid, T0, 'champion'); ok(r.ok && r.until === T0 + 30 * DAY, 'Champion: 30 days', '');
r = await buyX('c@x.com', paid, T0 + 45 * DAY, 'champion');
ok(r.until === T0 + 75 * DAY, 'Champion again after it ended: extends from now', new Date(r.until).toISOString());
- charged = null; await buyX('c2@x.com', async (price) => { charged = price; return { ok: true }; }, T0, 'champion'); ok(charged === 3999, 'Champion charges 3999 credits', String(charged));
+ charged = null; await buyX('c2@x.com', async (price) => { charged = price; return { ok: true }; }, T0, 'champion'); ok(charged === 5000, 'Champion charges 5000 credits', String(charged));
// 4. side by side: Champion over Explorer, then Explorer shows through; weekly underneath
await buyX('d@x.com', paid, T0, 'weekly'); // weekly to T0+7
@@ -104,7 +104,7 @@ async function buyX(email, payer, now, tier, opts) {
const ordE = r.order;
r = await buyX('p@x.com', short, T0, 'explorer'); ok(r.order === ordE, 'same tier again reuses its waiting order', '');
r = await buyX('p@x.com', short, T0, 'champion'); const ordC = r.order;
- ok(r.needPay && r.order !== ordE && r.package === 50 && /package of \$50 or more/.test(r.message), 'Champion short: its own waiting order; copy names the $50 package (there is no $40 one)', r.message);
+ ok(r.needPay && r.order !== ordE && r.package === 50 && /package of \$50 or more/.test(r.message), 'Champion short: its own waiting order; copy names the $50 package (exactly the price since 2026-10-25)', r.message);
r = await buyX('p@x.com', short, T0, 'weekly');
ok(r.payUrl === '/my?from=gamepass#buy' && /package of \$5 or more/.test(r.message), 'weekly short: payUrl and copy exactly as before', r.payUrl);
let ev = await gp.onEvent({ type: 'Purchase', priceCents: 500, tx: '0xa1', ts: T0 + 60000, devEmail: 'p@x.com' });
@@ -148,7 +148,7 @@ async function buyX(email, payer, now, tier, opts) {
await buyX('s5@x.com', short, NOW, 'champion');
const st = gp.adminStats(NOW); const S = st.tiers;
ok(S.weekly.active === 1 && S.explorer.active === 2 && S.champion.active === 1, 'active counts each account once at its top tier (s1 = explorer, not weekly)', JSON.stringify({ w: S.weekly.active, e: S.explorer.active, c: S.champion.active }));
- ok(S.weekly.soldWeek === 2 && S.explorer.soldWeek === 0 && S.explorer.soldMonth === 1 && S.champion.soldWeek === 1 && S.champion.soldMonth === 1 && S.champion.soldTotal === 2 && S.champion.usdTotal === 79.98, 'Central week (from Mon 00:00) and month (from the 1st 00:00) boundaries', JSON.stringify({ w: [S.weekly.soldWeek, S.weekly.soldMonth], e: [S.explorer.soldWeek, S.explorer.soldMonth], c: [S.champion.soldWeek, S.champion.soldMonth, S.champion.soldTotal, S.champion.usdTotal] }));
+ ok(S.weekly.soldWeek === 2 && S.explorer.soldWeek === 0 && S.explorer.soldMonth === 1 && S.champion.soldWeek === 1 && S.champion.soldMonth === 1 && S.champion.soldTotal === 2 && S.champion.usdTotal === 100, 'Central week (from Mon 00:00) and month (from the 1st 00:00) boundaries', JSON.stringify({ w: [S.weekly.soldWeek, S.weekly.soldMonth], e: [S.explorer.soldWeek, S.explorer.soldMonth], c: [S.champion.soldWeek, S.champion.soldMonth, S.champion.soldTotal, S.champion.usdTotal] }));
ok(S.champion.renewals30d === 1 && S.weekly.renewals30d === 0, 'renewals30d: a second Champion purchase by a Champion holder', String(S.champion.renewals30d));
ok(S.weekly.expiring7d === 2 && S.explorer.comped === 1 && S.champion.waitingOrders === 1, 'expiring7d (weekly passes ending in 7 Central days), comped, waiting orders per tier', JSON.stringify({ exp: S.weekly.expiring7d, comped: S.explorer.comped, wait: S.champion.waitingOrders }));
ok(st.passes.active === 4 && st.passes.soldTotal === 5 && st.passes.comped === 1 && st.passes.waitingOrders === 1, 'the existing all-tier passes block still adds up', JSON.stringify(st.passes));
@@ -158,13 +158,13 @@ async function buyX(email, payer, now, tier, opts) {
ok(rows.sales === 2 && rows.salesUsd === 10, 'passTournamentTierSales off: only the 2 weekly sales ($10) feed the pool', JSON.stringify({ sales: rows.sales, usd: rows.salesUsd }));
SC.passTournamentTierSales = '1';
const rows2 = await gp.runTournament(Date.parse('2026-11-03T18:00:00Z'), { force: true });
- ok(rows2.sales === 3 && rows2.salesUsd === 49.99, 'passTournamentTierSales on: the Champion renewal ($39.99) is added', JSON.stringify({ sales: rows2.sales, usd: rows2.salesUsd }));
- // 10. Sovereign ($99.99 / 30 days) and Legend ($249.99 / 365 days), 2026-10-22 (Dallas's structure)
+ ok(rows2.sales === 3 && rows2.salesUsd === 60, 'passTournamentTierSales on: the Champion renewal ($50) is added', JSON.stringify({ sales: rows2.sales, usd: rows2.salesUsd }));
+ // 10. Sovereign ($100 / 30 days) and Legend ($250 / 365 days), 2026-10-22 (Dallas's structure); prices = packages since 2026-10-25
for (const k of [...passes.keys()]) passes.delete(k); for (const k of [...orders.keys()]) orders.delete(k);
delete SC.passTournamentTierSales; SC.sovTiers = '0';
ok(gp.TIERS.join() === 'weekly,explorer,champion,sovereign,legend' && gp.TIER_NAMES.sovereign === 'Sovereign' && gp.TIER_NAMES.legend === 'Legend', 'rank: weekly < explorer < champion < sovereign < legend; names from the one table', gp.TIERS.join());
const C0 = gp.cfg().tiers;
- ok(C0.weekly.price === 500 && C0.weekly.days === 7 && C0.explorer.price === 1999 && C0.champion.price === 3999 && C0.sovereign.price === 9999 && C0.sovereign.days === 30 && C0.legend.price === 24999 && C0.legend.days === 365 && !C0.sovereign.sale && !C0.legend.sale && C0.weekly.sale, 'defaults: weekly 500/7 (unchanged), Sovereign 9999/30, Legend 24999/365; sovTiers off = not on sale, weekly on sale', JSON.stringify(C0));
+ ok(C0.weekly.price === 500 && C0.weekly.days === 7 && C0.explorer.price === 2000 && C0.champion.price === 5000 && C0.sovereign.price === 10000 && C0.sovereign.days === 30 && C0.legend.price === 25000 && C0.legend.days === 365 && !C0.sovereign.sale && !C0.legend.sale && C0.weekly.sale, 'defaults: weekly 500/7 (unchanged), Sovereign 10000/30, Legend 25000/365; sovTiers off = not on sale, weekly on sale', JSON.stringify(C0));
// off switch: members refused, nothing written, nothing charged; the weekly pass still sells
charged = null; const spy = async (price, label) => { charged = { price, label }; return { ok: true }; };
r = await buyX('m@x.com', spy, T0, 'sovereign'); ok(r.error === 'The Sovereign pass is not open yet.' && !charged, 'sovTiers off: Sovereign refused for a member, nothing charged', JSON.stringify(r));
@@ -174,15 +174,15 @@ async function buyX(email, payer, now, tier, opts) {
v = gp.view('m@x.com', T0); ok(v.passes.map(x => x.tier).join() === 'weekly' && !v.tierPreview, 'sovTiers off: the member still sees only the weekly pass', JSON.stringify(v.passes.map(x => x.tier)));
charged = null; r = await buyX('m@x.com', spy, T0); ok(r.ok && r.tier === 'weekly' && charged.price === 500 && charged.label === 'Game Pass (7 days)' && r.until === T0 + 7 * DAY, 'sovTiers off: the weekly Game Pass sells exactly as before', JSON.stringify(charged));
charged = null; r = await buyX('adm@x.com', spy, T0, 'legend', { preview: true });
- ok(r.ok && r.tier === 'legend' && r.days === 365 && r.until === T0 + 365 * DAY && charged.price === 24999 && charged.label === 'Legend pass (365 days)', 'sovTiers off: the admin can buy Legend (testing): 24999 credits, 365 days', JSON.stringify({ r, charged }));
+ ok(r.ok && r.tier === 'legend' && r.days === 365 && r.until === T0 + 365 * DAY && charged.price === 25000 && charged.label === 'Legend pass (365 days)', 'sovTiers off: the admin can buy Legend (testing): 25000 credits, 365 days', JSON.stringify({ r, charged }));
SC.sovTiers = '1';
// buy with enough purchased credits
charged = null; r = await buyX('sv@x.com', spy, T0, 'sovereign');
- ok(r.ok && r.tier === 'sovereign' && r.days === 30 && r.until === T0 + 30 * DAY && charged.price === 9999 && charged.label === 'Sovereign pass (30 days)', 'sovTiers on: Sovereign charges 9999 credits, 30 days', JSON.stringify(charged));
+ ok(r.ok && r.tier === 'sovereign' && r.days === 30 && r.until === T0 + 30 * DAY && charged.price === 10000 && charged.label === 'Sovereign pass (30 days)', 'sovTiers on: Sovereign charges 10000 credits, 30 days', JSON.stringify(charged));
rec = passes.get('sv@x.com');
- ok(rec.tiers.sovereign.until === T0 + 30 * DAY && !rec.tiers.weekly && !rec.tiers.legend && rec.until === 0 && rec.bought[0].tier === 'sovereign' && rec.bought[0].usd === 99.99 && rec.bought[0].cents === 9999 && rec.bought[0].via === 'package', 'only the Sovereign tier moved; bought row has tier, $99.99, a 9999-cent package', JSON.stringify(rec));
+ ok(rec.tiers.sovereign.until === T0 + 30 * DAY && !rec.tiers.weekly && !rec.tiers.legend && rec.until === 0 && rec.bought[0].tier === 'sovereign' && rec.bought[0].usd === 100 && rec.bought[0].cents === 10000 && rec.bought[0].via === 'package', 'only the Sovereign tier moved; bought row has tier, $100, a 10000-cent package', JSON.stringify(rec));
charged = null; r = await buyX('lg@x.com', spy, T0, 'legend');
- ok(r.ok && r.until === T0 + 365 * DAY && charged.price === 24999 && passes.get('lg@x.com').bought[0].usd === 249.99, 'sovTiers on: Legend charges 24999 credits, a YEAR (365 days), $249.99 row', JSON.stringify(charged));
+ ok(r.ok && r.until === T0 + 365 * DAY && charged.price === 25000 && passes.get('lg@x.com').bought[0].usd === 250, 'sovTiers on: Legend charges 25000 credits, a YEAR (365 days), $250 row', JSON.stringify(charged));
// extend: from max(now, until)
r = await buyX('lg@x.com', paid, T0 + 100 * DAY, 'legend'); ok(r.until === T0 + 730 * DAY, 'Legend again while active: +365 days from its end (nothing lost)', new Date(r.until).toISOString());
r = await buyX('sv@x.com', paid, T0 + 10 * DAY, 'sovereign'); ok(r.until === T0 + 60 * DAY, 'Sovereign again while active: +30 days from its end', new Date(r.until).toISOString());
@@ -203,7 +203,7 @@ async function buyX(email, payer, now, tier, opts) {
ok(gs.allowed === 1.5 && gs.pass === true, 'polgrant: a Legend holder is capped at 1.50 on daily play, pass: true (a boolean)', JSON.stringify(gs));
// waiting orders: a $50 package does not cover Sovereign, $100 does; $100 does not cover Legend, $250 does
r = await buyX('wo@x.com', short, T0, 'sovereign');
- ok(r.needPay && r.tier === 'sovereign' && r.payUrl === '/my?from=gamepass&tier=sovereign#buy' && r.package === 100 && /package of \$100 or more/.test(r.message) && r.price === 9999, 'Sovereign short: waiting order, payUrl with tier, "$100 package"', r.message);
+ ok(r.needPay && r.tier === 'sovereign' && r.payUrl === '/my?from=gamepass&tier=sovereign#buy' && r.package === 100 && /package of \$100 or more/.test(r.message) && r.price === 10000, 'Sovereign short: waiting order, payUrl with tier, "$100 package"', r.message);
const ordS = r.order;
r = await buyX('wo@x.com', short, T0, 'legend'); const ordL = r.order;
ok(r.needPay && r.order !== ordS && r.package === 250 && /package of \$250 or more/.test(r.message) && r.payUrl === '/my?from=gamepass&tier=legend#buy', 'Legend short: its own waiting order, "$250 package"', r.message);
@@ -242,14 +242,14 @@ async function buyX(email, payer, now, tier, opts) {
const st2 = gp.adminStats(T0 + DAY); const S2 = st2.tiers;
ok(Object.keys(S2).join() === 'weekly,explorer,champion,sovereign,legend' && S2.sovereign.name === 'Sovereign' && S2.legend.name === 'Legend', 'admin stats carry all five tiers by name', Object.keys(S2).join());
ok(S2.legend.active >= 3 && S2.legend.comped === 1 && S2.sovereign.comped === 1 && S2.legend.soldTotal >= 4 && S2.sovereign.soldTotal >= 4, 'admin stats: Legend/Sovereign active, sold and comped counted', JSON.stringify({ l: S2.legend, s: S2.sovereign }));
- ok(st2.settings.tiers.legend.days === 365 && st2.settings.tiers.sovereign.price === 9999, 'admin settings block shows Legend 365 days, Sovereign 9999', '');
+ ok(st2.settings.tiers.legend.days === 365 && st2.settings.tiers.sovereign.price === 10000, 'admin settings block shows Legend 365 days, Sovereign 10000', '');
// tournament: Legend/Sovereign sales stay out of the pool unless passTournamentTierSales
for (const k of [...passes.keys()]) passes.delete(k);
const wkT = Date.parse('2026-11-10T18:00:00Z');
await buyX('t1@x.com', paid, wkT, 'weekly'); await buyX('t2@x.com', paid, wkT, 'legend'); await buyX('t3@x.com', paid, wkT, 'sovereign');
let tr = await gp.runTournament(wkT, { force: true }); ok(tr.sales === 1 && tr.salesUsd === 5, 'passTournamentTierSales default off: Sovereign/Legend sales do not feed the pool', JSON.stringify({ s: tr.sales, u: tr.salesUsd }));
SC.passTournamentTierSales = '1';
- tr = await gp.runTournament(wkT, { force: true }); ok(tr.sales === 3 && tr.salesUsd === 354.98, 'passTournamentTierSales on: Legend ($249.99) and Sovereign ($99.99) are added', JSON.stringify({ s: tr.sales, u: tr.salesUsd }));
+ tr = await gp.runTournament(wkT, { force: true }); ok(tr.sales === 3 && tr.salesUsd === 355, 'passTournamentTierSales on: Legend ($250) and Sovereign ($100) are added', JSON.stringify({ s: tr.sales, u: tr.salesUsd }));
delete SC.passTournamentTierSales;
try { fs.rmSync(dataDir, { recursive: true, force: true }); } catch (e) {}
diff --git a/server.js b/server.js
index 2fb25c8..6f3beaf 100644
--- a/server.js
+++ b/server.js
@@ -789,14 +789,15 @@ function siteConfig() {
geoTier2: '', // empty = built-in default (rest of Western/Central Europe, JP, KR, SG, HK, TW, IL, Gulf, ZA, BR, MX, AR, CL, CO ...); tier 3 = everything else
// Game Pass (2026-10-16, docs/GAME-PASS.md): off until Marty flips it; caps apply from capsStartDate (Central), before it polgrant allows everything and only records
gamePassEnabled: '0', gamePassPriceCredits: 500, gamePassDays: 7, capFreeDaily: 0.30, capFreeTotal: 2.0, capPassDaily: 1.50, capPassTotal: 5.0, capsStartDate: '', passTournamentPct: 5,
- // Explorer ($20) and Champion ($40) monthly passes beside the weekly one (2026-10-18, ultima-rpg docs/IAP-PASSES-SPEC.md): islands and looks
+ // Explorer and Champion monthly passes beside the weekly one (2026-10-18, ultima-rpg docs/IAP-PASSES-SPEC.md): islands and looks
// in Shards of Valor, never power, never more POL (same caps as the weekly pass). sovTiers = the sale switch for both (off: only ADMIN_EMAIL
// sees and can buy them, for testing; holders keep their pass). gamePass
Enabled '0' stops one tier alone. passTournamentTierSales '1'
// would add their sales to the Pass Tournament pool (off = the pool exactly as before).
// 2026-10-22 (Dallas's structure, Marty approved): Explorer $19.99 / Champion $39.99 for 30 days, plus Sovereign $99.99 for 30 days and
// Legend $249.99 for 365 days (the yearly pass), all behind sovTiers. Names, perks and the rank live in gamepass.js TIER_DEFS.
- sovTiers: '0', gamePassExplorerEnabled: '1', gamePassExplorerPriceCredits: 1999, gamePassExplorerDays: 30, gamePassChampionEnabled: '1', gamePassChampionPriceCredits: 3999, gamePassChampionDays: 30,
- gamePassSovereignEnabled: '1', gamePassSovereignPriceCredits: 9999, gamePassSovereignDays: 30, gamePassLegendEnabled: '1', gamePassLegendPriceCredits: 24999, gamePassLegendDays: 365, passTournamentTierSales: '0',
+ // 2026-10-25 (Marty): prices = the one-click packages: Explorer $20, Champion $50, Sovereign $100, Legend $250 (cents below).
+ sovTiers: '0', gamePassExplorerEnabled: '1', gamePassExplorerPriceCredits: 2000, gamePassExplorerDays: 30, gamePassChampionEnabled: '1', gamePassChampionPriceCredits: 5000, gamePassChampionDays: 30,
+ gamePassSovereignEnabled: '1', gamePassSovereignPriceCredits: 10000, gamePassSovereignDays: 30, gamePassLegendEnabled: '1', gamePassLegendPriceCredits: 25000, gamePassLegendDays: 365, passTournamentTierSales: '0',
supportTelegramChat: '1289244227', // help desk pings: Marty's PRIVATE chat only (a positive user id; group/channel ids are refused). Sent with telegramBotToken, Hermes bot as fallback
supportTemplates: '', // help desk saved replies, JSON [{name, body}] (Admin > Support > Saved replies); empty = the built-in set
telegramGamesChatId: '', telegramGamesTopicId: '661565', // Game Achievements topic for the weekly Pass Tournament post (chat blank = the shared echo chat)