// core/flags.js (Lane F) — URL flags. The table of record lives in TECH.md; add rows there. export function parseFlags(search = location.search) { const p = new URLSearchParams(search); const on = (k) => p.has(k) && p.get(k) !== '0'; return { stub: on('stub'), fly: on('fly'), dbg: on('dbg'), shots: on('shots'), mute: on('mute'), fakebus: on('fakebus'), localassets: p.get('localassets') !== '0', // ?localassets=0 => empty-manifest boot lvl: p.get('lvl') || null, seed: p.has('seed') ? (parseInt(p.get('seed'), 10) >>> 0) : null, raw: p, }; }