diff --git a/site/i18n/de.js b/site/i18n/de.js index 150a6db..4b0b5d7 100644 --- a/site/i18n/de.js +++ b/site/i18n/de.js @@ -2856,6 +2856,7 @@ "puzzles.euro_trip":"Euro-Trip", "puzzles.every_internet_starts_with_one_tube":"Jedes Internet beginnt mit einer Röhre.", "puzzles.every_link_n_g_or_more":"Jeder Link {n}G oder mehr", +"puzzles.every_star_in_this_pack_is":"Alle Sterne in diesem Paket gehören dir.", "puzzles.fat_pipes_only":"Nur dicke Rohre", "puzzles.flash_boys":"Flash Boys", "puzzles.for_architects_who_sleep_through_backhoes":"Für Architekten, die die Baggersaison verschlafen.", @@ -2878,6 +2879,7 @@ "puzzles.n_1_club":"N-1-Club", "puzzles.n_1_connect_everything_first":"N-1: erst alles verbinden", "puzzles.n_g_links":"{n}G-Links", +"puzzles.n_stars_left_in_this_pack":{"one":"Noch {n} ⭐ in diesem Paket","other":"Noch {n} ⭐ in diesem Paket"}, "puzzles.n_week_streak":{"one":"{n} Woche in Folge","other":"{n} Wochen in Folge"}, "puzzles.new_zealand_is_far_from_everything":"Neuseeland ist weit weg von allem. Genau das ist der Witz, und das Problem.", "puzzles.next_pack_unlocks_at_n":"Nächstes Paket, {pack}, ab {n}⭐", @@ -2923,6 +2925,7 @@ "puzzles.size":"Größe", "puzzles.small_calm_network_builds":"Kleine, entspannte Netzbauten", "puzzles.smorgasbord":"Smörgåsbord", +"puzzles.so_close_one_more_link_and":"Fast: noch ein Link, und kein Bagger kann dir was.", "puzzles.speed_runs":"Speedruns", "puzzles.spent_x":"Ausgegeben {x}", "puzzles.spent_x_of_y":"Ausgegeben {x} / {y}", diff --git a/site/i18n/es.js b/site/i18n/es.js index ef5b2cf..0b717d2 100644 --- a/site/i18n/es.js +++ b/site/i18n/es.js @@ -2854,6 +2854,7 @@ "puzzles.euro_trip":"Euro Trip", "puzzles.every_internet_starts_with_one_tube":"Todo internet empieza con un tubo.", "puzzles.every_link_n_g_or_more":"Cada enlace de {n}G o más", +"puzzles.every_star_in_this_pack_is":"Todas las estrellas de este paquete son tuyas.", "puzzles.fat_pipes_only":"Solo tuberías gordas", "puzzles.flash_boys":"Flash Boys", "puzzles.for_architects_who_sleep_through_backhoes":"Para arquitectos que duermen tranquilos en temporada de retroexcavadoras.", @@ -2876,6 +2877,7 @@ "puzzles.n_1_club":"Club N-1", "puzzles.n_1_connect_everything_first":"N-1: primero conéctalo todo", "puzzles.n_g_links":"enlaces de {n}G", +"puzzles.n_stars_left_in_this_pack":{"one":"Queda {n} ⭐ en este paquete","other":"Quedan {n} ⭐ en este paquete"}, "puzzles.n_week_streak":{"one":"{n} semana seguida","other":"{n} semanas seguidas"}, "puzzles.new_zealand_is_far_from_everything":"Nueva Zelanda está lejos de todo. Esa es la gracia, y el problema.", "puzzles.next_pack_unlocks_at_n":"El siguiente pack, {pack}, se desbloquea con {n}⭐", @@ -2921,6 +2923,7 @@ "puzzles.size":"Tamaño", "puzzles.small_calm_network_builds":"Redes pequeñas y tranquilas", "puzzles.smorgasbord":"Smörgåsbord", +"puzzles.so_close_one_more_link_and":"Casi: un enlace más y ninguna retroexcavadora podrá contigo.", "puzzles.speed_runs":"Contrarreloj", "puzzles.spent_x":"Gastado {x}", "puzzles.spent_x_of_y":"Gastado {x} / {y}", diff --git a/site/i18n/fr.js b/site/i18n/fr.js index 8af1595..28f4001 100644 --- a/site/i18n/fr.js +++ b/site/i18n/fr.js @@ -2854,6 +2854,7 @@ "puzzles.euro_trip":"Euro Trip", "puzzles.every_internet_starts_with_one_tube":"Tout internet commence par un tube.", "puzzles.every_link_n_g_or_more":"Chaque lien à {n}G ou plus", +"puzzles.every_star_in_this_pack_is":"Toutes les étoiles de ce pack sont à toi.", "puzzles.fat_pipes_only":"Gros tuyaux uniquement", "puzzles.flash_boys":"Flash Boys", "puzzles.for_architects_who_sleep_through_backhoes":"Pour les architectes qui dorment pendant la saison des pelleteuses.", @@ -2876,6 +2877,7 @@ "puzzles.n_1_club":"Club N-1", "puzzles.n_1_connect_everything_first":"N-1 : relie d’abord tout", "puzzles.n_g_links":"liens {n}G", +"puzzles.n_stars_left_in_this_pack":{"one":"Encore {n} ⭐ dans ce pack","other":"Encore {n} ⭐ dans ce pack"}, "puzzles.n_week_streak":{"one":"{n} semaine d’affilée","other":"{n} semaines d’affilée"}, "puzzles.new_zealand_is_far_from_everything":"La Nouvelle-Zélande est loin de tout. C’est tout l’intérêt, et tout le problème.", "puzzles.next_pack_unlocks_at_n":"Prochain pack, {pack}, à {n}⭐", @@ -2921,6 +2923,7 @@ "puzzles.size":"Taille", "puzzles.small_calm_network_builds":"Petits réseaux, tranquillement", "puzzles.smorgasbord":"Smörgåsbord", +"puzzles.so_close_one_more_link_and":"Presque : encore un lien et aucune pelleteuse ne pourra rien contre toi.", "puzzles.speed_runs":"Contre la montre", "puzzles.spent_x":"Dépensé {x}", "puzzles.spent_x_of_y":"Dépensé {x} / {y}", diff --git a/site/i18n/it.js b/site/i18n/it.js index d36d2bd..009e74f 100644 --- a/site/i18n/it.js +++ b/site/i18n/it.js @@ -2854,6 +2854,7 @@ "puzzles.euro_trip":"Euro Trip", "puzzles.every_internet_starts_with_one_tube":"Ogni internet comincia con un tubo.", "puzzles.every_link_n_g_or_more":"Ogni link da {n}G o più", +"puzzles.every_star_in_this_pack_is":"Tutte le stelle di questo pacchetto sono tue.", "puzzles.fat_pipes_only":"Solo tubi grossi", "puzzles.flash_boys":"Flash Boys", "puzzles.for_architects_who_sleep_through_backhoes":"Per architetti che dormono sonni tranquilli nella stagione delle ruspe.", @@ -2876,6 +2877,7 @@ "puzzles.n_1_club":"Club N-1", "puzzles.n_1_connect_everything_first":"N-1: prima collega tutto", "puzzles.n_g_links":"link da {n}G", +"puzzles.n_stars_left_in_this_pack":{"one":"Ancora {n} ⭐ in questo pacchetto","other":"Ancora {n} ⭐ in questo pacchetto"}, "puzzles.n_week_streak":{"one":"{n} settimana di fila","other":"{n} settimane di fila"}, "puzzles.new_zealand_is_far_from_everything":"La Nuova Zelanda è lontana da tutto. È proprio questo il bello, e il problema.", "puzzles.next_pack_unlocks_at_n":"Il prossimo pacchetto, {pack}, si sblocca a {n}⭐", @@ -2921,6 +2923,7 @@ "puzzles.size":"Taglia", "puzzles.small_calm_network_builds":"Piccole reti, con calma", "puzzles.smorgasbord":"Smörgåsbord", +"puzzles.so_close_one_more_link_and":"Ci sei quasi: ancora un link e nessuna ruspa può toccarti.", "puzzles.speed_runs":"Corse contro il tempo", "puzzles.spent_x":"Speso {x}", "puzzles.spent_x_of_y":"Speso {x} / {y}", diff --git a/site/i18n/pt.js b/site/i18n/pt.js index d96b22d..0c148b8 100644 --- a/site/i18n/pt.js +++ b/site/i18n/pt.js @@ -2854,6 +2854,7 @@ "puzzles.euro_trip":"Euro Trip", "puzzles.every_internet_starts_with_one_tube":"Toda internet começa com um tubo.", "puzzles.every_link_n_g_or_more":"Todo link com {n}G ou mais", +"puzzles.every_star_in_this_pack_is":"Todas as estrelas deste pacote são suas.", "puzzles.fat_pipes_only":"Só tubos grossos", "puzzles.flash_boys":"Flash Boys", "puzzles.for_architects_who_sleep_through_backhoes":"Para arquitetos que dormem tranquilos na temporada das retroescavadeiras.", @@ -2876,6 +2877,7 @@ "puzzles.n_1_club":"Clube N-1", "puzzles.n_1_connect_everything_first":"N-1: conecte tudo primeiro", "puzzles.n_g_links":"links de {n}G", +"puzzles.n_stars_left_in_this_pack":{"one":"Falta {n} ⭐ neste pacote","other":"Faltam {n} ⭐ neste pacote"}, "puzzles.n_week_streak":{"one":"{n} semana seguida","other":"{n} semanas seguidas"}, "puzzles.new_zealand_is_far_from_everything":"A Nova Zelândia fica longe de tudo. Essa é a graça, e o problema.", "puzzles.next_pack_unlocks_at_n":"O próximo pacote, {pack}, abre com {n}⭐", @@ -2921,6 +2923,7 @@ "puzzles.size":"Tamanho", "puzzles.small_calm_network_builds":"Redes pequenas, com calma", "puzzles.smorgasbord":"Smörgåsbord", +"puzzles.so_close_one_more_link_and":"Quase lá: mais um link e nenhuma retroescavadeira te alcança.", "puzzles.speed_runs":"Contra o relógio", "puzzles.spent_x":"Gasto {x}", "puzzles.spent_x_of_y":"Gasto {x} / {y}", diff --git a/src/game/60-features/92-puzzles.js b/src/game/60-features/92-puzzles.js index 01f4b13..79cc1a9 100644 --- a/src/game/60-features/92-puzzles.js +++ b/src/game/60-features/92-puzzles.js @@ -56,6 +56,14 @@ function pzEval(){const P=S.pz,ls=S.links,cs=P.cities,spend=pzSpend(); const weak=conn?units.filter(u=>{const g=pzComp(ls,u,cs[0]);return !cs.every(c=>g.has(c));}):[]; const n1=conn&&units.length>0&&!weak.length,cheap=!P.budget||spend<=P.budget; return {marks,conn,tw,goal,spend,cheap,n1,weak,stars:goal?1+(cheap?1:0)+(n1?1:0):0};} +// Two stars, and one more link within budget would survive any cut? Then the third star is close. Tries every route +// between the puzzle's cities at the smallest allowed size, so the nudge is true, not a guess. +function pzOneMore(e){const P=S.pz;if(e.stars!==2||!e.cheap||e.n1)return false;const cs=[...P.cities,...P.via],tier=P.minG?1:0,cs0=P.cities[0]; + for(const a of cs)for(const b of cs){if(a>=b)continue;for(const r of pzRoutes(a,b)){if((P.noSub&&r.sub)||subWaveWhy(tier,r.km,r.sub))continue; + const div=!r.sub&&S.links.some(l=>edgeKey(l)===edgeKey({a,b})&&!l.cable),cost=pzLinkCost(r,tier,div)+(S.pops[a]?0:pzPopCost(a))+(S.pops[b]?0:pzPopCost(b)); + if(e.spend+cost>P.budget)continue;const ls=[...S.links,{id:'pz?',a,b,cable:r.cab,trench:r.cab?'cab:'+r.cab:'pz?'}];if(P.ring&&!pzRingOk(ls))continue; + if([...new Set(ls.map(pzUnit))].every(u=>{const g=pzComp(ls,u,cs0);return P.cities.every(c=>g.has(c));}))return true;}} + return false;} // ---------- the weekly puzzle: the same for everyone, seeded by the ISO week like the weekly challenge ---------- function pzWeekKey(dt){const {y,w}=isoWeek(dt);return `${y}-W${String(w).padStart(2,'0')}`;} function pzPrevKey(key){const m=/^(\d{4})-W(\d{2})$/.exec(key);if(!m)return null;return pzWeekKey(new Date(+m[1],0,4+(+m[2]-2)*7));} diff --git a/src/game/95-modals/95-puzzles.js b/src/game/95-modals/95-puzzles.js index 9a1599b..bd0092b 100644 --- a/src/game/95-modals/95-puzzles.js +++ b/src/game/95-modals/95-puzzles.js @@ -22,7 +22,7 @@ function pzRender(){const el=$('pzBox');if(!pzOn()){el.hidden=true;return;}el.hi const sp=fmt$(e.spend); h+=P.budget?`
${tr('puzzles.spent_x_of_y',{x:sp,y:fmt$(P.budget)})}${e.cheap?'✓':'✗'}
` :`
${tr('puzzles.spent_x',{x:sp})}${tr('puzzles.no_budget_star_on_the_house')}
`; - h+=!e.conn?`
🛡 ${tr('puzzles.n_1_connect_everything_first')}
`:e.n1?`
🛡 ${tr('puzzles.survives_any_single_cut')}
`:`
⚠️ ${tr('puzzles.one_cut_splits_it_where',{where:pzUnitName(e.weak[0])})}
`; + h+=!e.conn?`
🛡 ${tr('puzzles.n_1_connect_everything_first')}
`:e.n1?`
🛡 ${tr('puzzles.survives_any_single_cut')}
`:`
⚠️ ${tr('puzzles.one_cut_splits_it_where',{where:pzUnitName(e.weak[0])})}${pzOneMore(e)?`
${tr('puzzles.so_close_one_more_link_and')}`:''}
`; h+=`
${btn('↶ '+tr('puzzles.undo'),'pzUndo',{},'ghost sm',!(UI.pzHist&&UI.pzHist.length))}${btn(tr('puzzles.reset'),'pzReset',{},'ghost sm',!S.links.length&&!Object.keys(S.pops).length)}${btn(UI.pzFrom==='game'?tr('puzzles.back_to_my_network'):tr('puzzles.back_to_the_title'),'pzLeave',{},'ghost sm')}
`; if(h!==UI._pzh){UI._pzh=h;morph(el,h);}} function pzPanel(sel){const head=(eb,name,facts)=>`
${eb}

${name}

${facts?`
${facts}
`:''}
`; @@ -56,17 +56,21 @@ function pzLinkModal(a,b,keep){const kb=pzKind(b); h+=`
${PZ_TIERS.map(i=>{const why=subWaveWhy(i,r.km,r.sub),c=pzLinkCost(r,i,div)+pop;return ``;}).join('')}
`; openModal(h);} // ---------- results ---------- -function pzLine(e){return e.stars>=3?tr('puzzles.a_backhoe_walks_into_your_network'):!e.n1&&!e.cheap?tr('puzzles.it_works_finance_and_the_backhoe'):!e.n1?tr('puzzles.one_backhoe_away_from_a_very'):tr('puzzles.rock_solid_and_gold_plated_the');} +function pzLine(e){return e.stars>=3?tr('puzzles.a_backhoe_walks_into_your_network'):!e.n1&&!e.cheap?tr('puzzles.it_works_finance_and_the_backhoe'):!e.n1?(pzOneMore(e)?tr('puzzles.so_close_one_more_link_and'):tr('puzzles.one_backhoe_away_from_a_very')):tr('puzzles.rock_solid_and_gold_plated_the');} +// Stars still to win in this puzzle's pack, from the progress just saved. +function pzPackLeft(P){const d=pzDef(P.id);if(!d)return null;const p=pzLoad(),xs=PZ.filter(x=>x.pack===d.pack);return xs.length*3-xs.reduce((a,x)=>a+((p.s[x.id]||{}).st|0),0);} function pzConfetti(){if(!animOn())return '';const cols=['#FF4F9A','#FFD23F','#22C47A','#2F8CFF','#FF8A3D','#7B61FF'];let h=''; for(let i=0;i<28;i++)h+=``; return ``;} -function pzResults(e,prev){const P=S.pz,nx=P.id==='weekly'?null:pzNextDef(); +function pzResults(e,prev){const P=S.pz,nx=P.id==='weekly'?null:pzNextDef(),left=pzPackLeft(P),done=e.stars>=3; const row=(ok,l,v)=>`
${ok?'⭐':'☆'} ${l}${v}
`; const stars=[0,1,2].map(i=>`⭐`).join(''); openModal(`
${e.stars>=3?pzConfetti():''}
${tr('puzzles.puzzle_solved')}

${esc(pzName(pzDef(P.id)||P))}

-
${stars}

${pzLine(e)}

+
${stars}

${pzLine(e)}

${left==null?'':`

${left?trn('puzzles.n_stars_left_in_this_pack',left):tr('puzzles.every_star_in_this_pack_is')}

`} ${row(true,tr('puzzles.goal'),tr('puzzles.connected'))}${row(e.cheap,tr('puzzles.budget'),P.budget?tr('puzzles.spent_x_of_y',{x:fmt$(e.spend),y:fmt$(P.budget)}):tr('puzzles.on_the_house'))}${row(e.n1,'N-1',e.n1?tr('puzzles.survives_any_single_cut'):tr('puzzles.one_cut_splits_it'))} -
${nx?btn(tr('puzzles.next_puzzle'),'pzStart',{id:nx.id},'pink big'):btn(tr('puzzles.more_puzzles'),'puzzleMenu',{},'pink big')}${e.stars<3?btn(tr('puzzles.retry_for_3_stars'),'pzRetry',{},''):''}${btn(tr('common.share_2cd9'),'pzShare',{},'')}${btn(tr('puzzles.keep_building'),'closeModal',{},'ghost')}
`); +
${nx?btn(tr('puzzles.next_puzzle')+(done?' →':''),'pzStart',{id:nx.id},'pink big pznext'):btn(tr('puzzles.more_puzzles'),'puzzleMenu',{},'pink big pznext')}${!done?btn(tr('puzzles.retry_for_3_stars'),'pzRetry',{},''):''}${btn(tr('common.share_2cd9'),'pzShare',{},done?'ghost':'')}${btn(tr('puzzles.keep_building'),'closeModal',{},'ghost')}
`); + // Three stars: Next is the one big obvious tap (and the keyboard's default). + if(done){const b=document.querySelector('#modalCard .pznext');if(b)try{b.focus({preventScroll:true});}catch(_){}} for(let i=prev;i{sfx('star');haptic(15);},Math.max(0,i-prev)*450+150); if(e.stars>=3&&prev<3)setTimeout(()=>sfx('fanfare'),(3-prev)*450+250);} // ---------- the list ---------- diff --git a/src/i18n/en.js b/src/i18n/en.js index dd1cac2..17189f0 100644 --- a/src/i18n/en.js +++ b/src/i18n/en.js @@ -2855,6 +2855,7 @@ "puzzles.euro_trip":"Euro Trip", "puzzles.every_internet_starts_with_one_tube":"Every internet starts with one tube.", "puzzles.every_link_n_g_or_more":"Every link {n}G or more", +"puzzles.every_star_in_this_pack_is":"Every star in this pack is yours.", "puzzles.fat_pipes_only":"Fat Pipes Only", "puzzles.flash_boys":"Flash Boys", "puzzles.for_architects_who_sleep_through_backhoes":"For architects who sleep through backhoe season.", @@ -2877,6 +2878,7 @@ "puzzles.n_1_club":"N-1 Club", "puzzles.n_1_connect_everything_first":"N-1: connect everything first", "puzzles.n_g_links":"{n}G links", +"puzzles.n_stars_left_in_this_pack":{"one":"{n} ⭐ left in this pack","other":"{n} ⭐ left in this pack"}, "puzzles.n_week_streak":{"one":"{n} week in a row","other":"{n} weeks in a row"}, "puzzles.new_zealand_is_far_from_everything":"New Zealand is far from everything. That is the point, and the problem.", "puzzles.next_pack_unlocks_at_n":"Next pack, {pack}, unlocks at {n}⭐", @@ -2922,6 +2924,7 @@ "puzzles.size":"Size", "puzzles.small_calm_network_builds":"Small, calm network builds", "puzzles.smorgasbord":"Smörgåsbord", +"puzzles.so_close_one_more_link_and":"So close: one more link and a backhoe can't touch you.", "puzzles.speed_runs":"Speed Runs", "puzzles.spent_x":"Spent {x}", "puzzles.spent_x_of_y":"Spent {x} / {y}", diff --git a/src/styles/70-puzzles.css b/src/styles/70-puzzles.css index 8a12495..eeedbe3 100644 --- a/src/styles/70-puzzles.css +++ b/src/styles/70-puzzles.css @@ -19,6 +19,10 @@ body.pz #hud .chip:not(.brand):not(.speed),body.pz #hud .speed button:not(#muteB .scn.lock{opacity:.5} .pzres{position:relative}.pzstars{display:flex;justify-content:center;gap:10px;margin:10px 0 2px} .pzbig{font-size:46px;filter:grayscale(1);opacity:.3}.pzbig.on{filter:none;opacity:1} +.pzleft{text-align:center;font-weight:900;font-size:13px;margin:2px 0 0;color:var(--ink2)} +.btns.pzdone .pznext{flex:1 1 100%;font-size:22px;padding:10px 18px 8px;animation:pznudge 1.8s ease-in-out 1.6s infinite} +@keyframes pznudge{50%{transform:translateY(-2px);box-shadow:0 5px 0 var(--ink)}} +@media (prefers-reduced-motion:reduce){.btns.pzdone .pznext{animation:none}} .pzbig.pop{animation:pzpop .5s cubic-bezier(.3,1.6,.5,1) var(--d) both} @keyframes pzpop{0%{transform:scale(0) rotate(-40deg);opacity:0}100%{transform:scale(1) rotate(0);opacity:1}} .pzconf{position:absolute;inset:-16px;pointer-events:none;overflow:hidden;z-index:2} diff --git a/tests/puzzles.test.js b/tests/puzzles.test.js index 4337d52..d96acea 100644 --- a/tests/puzzles.test.js +++ b/tests/puzzles.test.js @@ -411,3 +411,37 @@ test('phone sheet: 40 px touch targets, pinned actions, and goal chips with a cl assert.ok(ev("[...document.querySelectorAll('#pzBox button')].every(b=>b.classList.contains('b'))"), 'every sheet button is a .b the rule sizes'); assert.deepEqual(errors, []); }); + +test('results pull you on: Next is the big tap after three stars, stars left in the pack, and a nudge when 3 stars are one link away', () => { + const { ev, errors } = load(); + ev("localStorage.removeItem('sot-puzzles');pzBegin(pzDef('braces'))"); + build(ev, REF.braces.one); + let card = ev("document.getElementById('modalCard').textContent"); + assert.equal(evalP(ev).stars, 2); + assert.match(card, /So close: one more link and a backhoe can't touch you\./, 'Dublin to New York would do it, within budget'); + assert.match(ev("document.getElementById('pzBox').textContent"), /So close/); + assert.match(card, /10 ⭐ left in this pack/, '4 puzzles × 3 stars, 2 won'); + assert.ok(ev("!!document.querySelector('#modalCard [data-act=pzRetry]')")); + assert.ok(!ev("document.querySelector('#modalCard .btns.cta').classList.contains('pzdone')")); + build(ev, [['dub', 'nyc', 'havf']]); + card = ev("document.getElementById('modalCard').textContent"); + assert.match(card, /9 ⭐ left in this pack/); + assert.ok(ev("document.querySelector('#modalCard .btns.cta').classList.contains('pzdone')"), 'three stars: the big Next layout'); + assert.ok(ev("document.activeElement===document.querySelector('#modalCard .pznext')"), 'the big button has the focus'); + assert.equal(ev("document.querySelector('#modalCard [data-act=pzRetry]')"), null, 'no retry after three stars'); + assert.match(ev("document.querySelector('#modalCard .pznext').textContent"), /More puzzles/, 'the last pack points back to the list'); + ev("pzBegin(pzDef('eurotrip'))");build(ev, REF.eurotrip.three); + assert.match(ev("document.querySelector('#modalCard .pznext').textContent"), /Next puzzle →/); + assert.equal(ev("document.activeElement.dataset.act"), 'pzStart'); + // No nudge when no single link fits the budget: an over-budget gold plate is not "close". + ev("pzBegin(pzDef('braces'));S.pz.budget=245000"); + build(ev, REF.braces.one); + assert.equal(evalP(ev).stars, 2); + assert.doesNotMatch(ev("document.getElementById('modalCard').textContent"), /So close/); + assert.match(ev("document.getElementById('modalCard').textContent"), /One backhoe away/); + // A finished pack says so. + ev("localStorage.setItem('sot-puzzles',JSON.stringify({s:{sharks:{st:3},braces:{st:3},nofra:{st:3},fatpipes:{st:2}}}));pzBegin(pzDef('fatpipes'))"); + build(ev, REF.fatpipes.three); + assert.match(ev("document.getElementById('modalCard').textContent"), /Every star in this pack is yours/); + assert.deepEqual(errors, []); +});