diff --git a/.github/workflows/publish-vscode-extension.yml b/.github/workflows/publish-vscode-extension.yml index ac9a60a..0b0c5e4 100644 --- a/.github/workflows/publish-vscode-extension.yml +++ b/.github/workflows/publish-vscode-extension.yml @@ -12,7 +12,7 @@ on: extension: description: Which extension type: choice - options: [api-client, aura, auto-rename-tag, blast-radius, code-guard, codesnap, docker, document-viewer, env, error-lens, garden, git-graph, hotspots, live-server, live-values, mcp-studio, mongodb, npm-intellisense, path-intellisense, pets, port-manager, rewind, todo-tree, wrapped] + options: [api-client, aura, auto-rename-tag, blast-radius, code-guard, codesnap, docker, document-viewer, env, error-lens, garden, git-graph, hotspots, live-server, live-values, mcp-studio, mongodb, neon-getaway, npm-intellisense, path-intellisense, pets, port-manager, rewind, todo-tree, wrapped] default: live-server target: description: Where to publish diff --git a/extensions/neon-getaway/.gitignore b/extensions/neon-getaway/.gitignore new file mode 100644 index 0000000..13cda25 --- /dev/null +++ b/extensions/neon-getaway/.gitignore @@ -0,0 +1,5 @@ +out/ +dist/ +bundle/ +node_modules/ +.vscode-test/ diff --git a/extensions/neon-getaway/.vscodeignore b/extensions/neon-getaway/.vscodeignore new file mode 100644 index 0000000..bcaa433 --- /dev/null +++ b/extensions/neon-getaway/.vscodeignore @@ -0,0 +1,11 @@ +src/** +test/** +out/** +dist/** +node_modules/** +tsconfig.json +**/*.map +.gitignore +.vscode-test/** +media/readme/** +test/harness.html diff --git a/extensions/neon-getaway/CHANGELOG.md b/extensions/neon-getaway/CHANGELOG.md new file mode 100644 index 0000000..cc42ef8 --- /dev/null +++ b/extensions/neon-getaway/CHANGELOG.md @@ -0,0 +1,12 @@ +# Changelog + +## 1.0.0 + +First release of Neon Getaway, an open-world driving game in VS Code. + +- Solara Bay: four districts, traffic in lanes, people on the sidewalks, the sea, a pier and 20 hidden mixtapes. +- Take any car with E. Arcade handling with handbrake drifts, and four cars to buy at Rico's Garage. +- Wanted stars, police that chase you through the streets, losing them, the spray shop, and getting busted. +- Six story jobs, a street race, taxi fares, a minimap and a city map. +- A synthwave radio and engine sounds made live with Web Audio. +- Your code pays: $25 of in-game cash for each saved file, up to $1,000 a day. diff --git a/extensions/neon-getaway/LICENSE b/extensions/neon-getaway/LICENSE new file mode 100644 index 0000000..dc4f037 --- /dev/null +++ b/extensions/neon-getaway/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2026 FlightCoders + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/extensions/neon-getaway/README.md b/extensions/neon-getaway/README.md new file mode 100644 index 0000000..fa0eab4 --- /dev/null +++ b/extensions/neon-getaway/README.md @@ -0,0 +1,56 @@ +# Neon Getaway: Open World Driving Game + +**A neon open-world driving game, right inside VS Code.** Take any car, drift through Solara Bay at night, outrun the cops, pull off the jobs, and spend the cash your coding earns. + +A four-star police chase at night: a purple sports car at 214 km/h with police cars and flashing lights behind it, the Fresh Coat Spray shop, the minimap, $12,450 and four wanted stars + +Press **Ctrl+Alt+G** (**Cmd+Alt+G** on Mac), or click **🚀 Neon Getaway** in the status bar. + +## A whole city to drive + +Solara Bay has four districts: the towers of **Neon Heights**, the palms of **Palm Shore**, the warehouses of **Dockside** and the streets of **Old Town**. Traffic drives its lanes and turns at junctions, people walk the sidewalks, and the sea glitters around a city of neon rooftops. + +Drifting a sports car through a Neon Heights junction at night, tyre marks behind it, neon-edged rooftops and a helipad, on the Special Delivery job with 1:14 left + +- **Take any car.** Walk up to one and press **E**. Parked, passing, even a police car, if you dare. +- **Drive it like you stole it.** Arcade handling, top speeds over 250 km/h, and **Space** for handbrake drifts that leave tyre marks. +- **Four cars to buy** at Rico's Garage: the Bolt Compact, the Pulse GT muscle car, the Vapor S and the Hyperion supercar. + +## Cops, stars and getting away + +Steal a car in front of a cop, speed past one, or ram one, and you're **wanted**: up to five stars. More stars bring more police, and they hunt you through the streets. Get out of sight long enough and they lose you. Or pay for a fresh coat at the spray shop. Stop next to a cop and you're **busted**: a fine, and back to the station. + +## Jobs to pull off + +Six story jobs for **Rico** the mechanic and **Nova** the getaway driver: a timed delivery, a car to "borrow", a getaway from the bank, a street race against the Street Kings and **The Big Score**. Between jobs, take taxi fares and hunt for **20 hidden mixtapes**. + +The Solara Bay map: four districts, Rico's Garage, Police HQ, the spray shop, Solara Savings, the race start and the pier + +## Your code pays + +Every file you save in VS Code earns **$25** of in-game cash, up to $1,000 a day. The status bar shows what's waiting, so a good day of work buys you a supercar. + +Rico's Garage: the Hyperion supercar for $9,000, with bars for top speed, acceleration and handling + +## Controls + +| Key | | +|---|---| +| **W A S D** or arrows | Drive or walk | +| **Space** | Handbrake: drift! | +| **E** | Get in or out of a car | +| **Enter** or **F** | Start a job, open the garage, spray shop, taxi fares | +| **Shift** | Run | +| **Tab** | City map | +| **R** · **M** · **H** | Radio station · sound on/off · horn | +| **Esc** or **P** | Pause | + +## Good to know + +- **Free, offline, no account.** No ads, no tracking, nothing sent anywhere. Your progress is saved in VS Code. +- **Sound** is a synthwave radio and engine made live by the game. It starts only after you press a key, and **M** turns it off (or set `neonGetaway.sound` to false). +- **No weapons, no gore.** People always dive out of the way. +- **Settings:** `neonGetaway.statusBar` (the status bar button), `neonGetaway.paycheck` (cash for saving files), `neonGetaway.sound`. +- **Start over** with *Neon Getaway: Start Over* in the Command Palette. + +Made by [FlightCoders](https://flightcoders.com). MIT licensed. diff --git a/extensions/neon-getaway/media/audio.js b/extensions/neon-getaway/media/audio.js new file mode 100644 index 0000000..67cc8fb --- /dev/null +++ b/extensions/neon-getaway/media/audio.js @@ -0,0 +1,116 @@ +/* Neon Getaway sound: an engine, sirens, effects and two synthwave radio stations, all made with Web Audio (no files). */ +(function (root) { + 'use strict'; + const NOTE = n => 440 * Math.pow(2, (n - 69) / 12); + const STATIONS = [ + { name: 'Solara FM', bpm: 104, chords: [[57, 60, 64], [53, 57, 60], [48, 52, 55], [55, 59, 62]], arp: [0, 1, 2, 1, 0, 2, 1, 2], lead: 0.9 }, + { name: 'Night Drive 88', bpm: 86, chords: [[50, 53, 57], [46, 50, 53], [53, 57, 60], [48, 52, 55]], arp: [0, 2, 1, 2, 0, 1, 2, 1], lead: 0.6 }, + ]; + + function Audio() { + this.ctx = null; this.on = true; this.station = 0; this.radioOn = true; + } + Audio.prototype.start = function () { + if (this.ctx || !this.on) return; + const AC = root.AudioContext || root.webkitAudioContext; + if (!AC) return; + const ctx = this.ctx = new AC(); + this.master = ctx.createGain(); this.master.gain.value = 0.55; this.master.connect(ctx.destination); + this.music = ctx.createGain(); this.music.gain.value = 0.16; this.music.connect(this.master); + // engine: two detuned saws through a low-pass filter + this.eng = ctx.createGain(); this.eng.gain.value = 0; this.eng.connect(this.master); + this.engF = ctx.createBiquadFilter(); this.engF.type = 'lowpass'; this.engF.frequency.value = 500; this.engF.connect(this.eng); + this.o1 = ctx.createOscillator(); this.o1.type = 'sawtooth'; this.o1.connect(this.engF); this.o1.start(); + this.o2 = ctx.createOscillator(); this.o2.type = 'square'; this.o2.detune.value = -1200; this.o2.connect(this.engF); this.o2.start(); + // siren + this.sir = ctx.createGain(); this.sir.gain.value = 0; this.sir.connect(this.master); + this.so = ctx.createOscillator(); this.so.type = 'triangle'; this.so.frequency.value = 700; this.so.connect(this.sir); this.so.start(); + const n = ctx.createBuffer(1, ctx.sampleRate, ctx.sampleRate), d = n.getChannelData(0); + for (let i = 0; i < d.length; i++) d[i] = Math.random() * 2 - 1; + this.noise = n; + this.nextBeat = ctx.currentTime + 0.1; this.beat = 0; + }; + Audio.prototype.setOn = function (on) { + this.on = on; + if (this.ctx) this.master.gain.setTargetAtTime(on ? 0.55 : 0, this.ctx.currentTime, 0.05); + else if (on) this.start(); + }; + Audio.prototype.nextStation = function () { + if (!this.radioOn) { this.radioOn = true; this.station = 0; } + else if (this.station < STATIONS.length - 1) this.station++; + else this.radioOn = false; + return this.radioOn ? STATIONS[this.station].name : 'Radio off'; + }; + Audio.prototype.stationName = function () { return this.radioOn ? STATIONS[this.station].name : 'Radio off'; }; + + Audio.prototype.blip = function (freq, len, type, vol, when) { + if (!this.ctx) return; + const c = this.ctx, t = when || c.currentTime, o = c.createOscillator(), g = c.createGain(); + o.type = type || 'square'; o.frequency.value = freq; + g.gain.setValueAtTime(vol || 0.2, t); g.gain.exponentialRampToValueAtTime(0.0001, t + len); + o.connect(g); g.connect(this.master); o.start(t); o.stop(t + len + 0.02); + }; + Audio.prototype.hit = function (len, vol, freq, when, dest) { + if (!this.ctx) return; + const c = this.ctx, t = when || c.currentTime, s = c.createBufferSource(), f = c.createBiquadFilter(), g = c.createGain(); + s.buffer = this.noise; f.type = freq > 3000 ? 'highpass' : 'lowpass'; f.frequency.value = freq || 800; + g.gain.setValueAtTime(vol, t); g.gain.exponentialRampToValueAtTime(0.0001, t + len); + s.connect(f); f.connect(g); g.connect(dest || this.master); s.start(t); s.stop(t + len + 0.02); + }; + Audio.prototype.fx = function (name, power) { + if (!this.ctx) return; + const t = this.ctx.currentTime; + if (name === 'crash') this.hit(0.35, Math.min(0.5, (power || 200) / 900), 900); + else if (name === 'cash') { this.blip(988, 0.08, 'square', 0.12); this.blip(1319, 0.18, 'square', 0.12, t + 0.08); } + else if (name === 'tape') [784, 988, 1175, 1568].forEach((f, i) => this.blip(f, 0.12, 'triangle', 0.16, t + i * 0.07)); + else if (name === 'checkpoint') this.blip(1046, 0.12, 'triangle', 0.18); + else if (name === 'passed') [523, 659, 784, 1046].forEach((f, i) => this.blip(f, 0.32, 'sawtooth', 0.1, t + i * 0.11)); + else if (name === 'failed' || name === 'busted') [392, 330, 262].forEach((f, i) => this.blip(f, 0.34, 'sawtooth', 0.1, t + i * 0.16)); + else if (name === 'wanted') { this.blip(660, 0.14, 'square', 0.12); this.blip(880, 0.2, 'square', 0.12, t + 0.12); } + else if (name === 'horn') { this.blip(392, 0.32, 'square', 0.13); this.blip(494, 0.32, 'square', 0.09); } + else if (name === 'door') this.hit(0.08, 0.2, 2200); + }; + + /** Called every frame. speed 0..1 of the car's top speed (null on foot); siren 0..1 by the nearest cop's distance. */ + Audio.prototype.update = function (speed, throttle, siren, music) { + if (!this.ctx) return; + const c = this.ctx, t = c.currentTime; + const driving = speed != null; + this.eng.gain.setTargetAtTime(driving ? 0.05 + 0.05 * throttle : 0, t, 0.08); + if (driving) { + const f = 38 + speed * 120 + throttle * 14; + this.o1.frequency.setTargetAtTime(f, t, 0.06); this.o2.frequency.setTargetAtTime(f * 2.01, t, 0.06); + this.engF.frequency.setTargetAtTime(380 + speed * 1300, t, 0.08); + } + this.sir.gain.setTargetAtTime(siren * 0.07, t, 0.1); + this.so.frequency.setTargetAtTime(Math.floor(t * 2.2) % 2 ? 960 : 720, t, 0.04); + this.music.gain.setTargetAtTime(music && this.radioOn ? 0.16 : 0, t, 0.3); + if (!(music && this.radioOn)) { this.nextBeat = t + 0.1; return; } + // The radio: a little synthwave sequencer, scheduled a moment ahead. + const st = STATIONS[this.station], sixteenth = 60 / st.bpm / 4; + while (this.nextBeat < t + 0.15) { + const b = this.beat, when = this.nextBeat, bar = Math.floor(b / 16) % st.chords.length, chord = st.chords[bar], s16 = b % 16; + if (s16 % 4 === 0) this.kick(when); + if (s16 % 4 === 2) this.hit(0.05, 0.07, 7000, when, this.music); + if (s16 === 4 || s16 === 12) this.hit(0.16, 0.12, 1800, when, this.music); + if (s16 % 2 === 0) this.tone(NOTE(chord[0] - 24), sixteenth * 1.8, 'sawtooth', 0.32, when, 600); + this.tone(NOTE(chord[st.arp[s16 % 8]] + 12), sixteenth * 0.9, 'square', 0.07 * st.lead, when, 2600); + if (s16 === 0) chord.forEach(n => this.tone(NOTE(n), sixteenth * 15, 'sawtooth', 0.05, when, 1400)); + this.nextBeat += sixteenth; this.beat++; + } + }; + Audio.prototype.kick = function (t) { + const c = this.ctx, o = c.createOscillator(), g = c.createGain(); + o.frequency.setValueAtTime(140, t); o.frequency.exponentialRampToValueAtTime(40, t + 0.14); + g.gain.setValueAtTime(0.7, t); g.gain.exponentialRampToValueAtTime(0.0001, t + 0.2); + o.connect(g); g.connect(this.music); o.start(t); o.stop(t + 0.22); + }; + Audio.prototype.tone = function (freq, len, type, vol, t, cut) { + const c = this.ctx, o = c.createOscillator(), g = c.createGain(), f = c.createBiquadFilter(); + o.type = type; o.frequency.value = freq; f.type = 'lowpass'; f.frequency.value = cut; + g.gain.setValueAtTime(0.0001, t); g.gain.linearRampToValueAtTime(vol, t + 0.01); g.gain.exponentialRampToValueAtTime(0.0001, t + len); + o.connect(f); f.connect(g); g.connect(this.music); o.start(t); o.stop(t + len + 0.03); + }; + + root.NGAudio = Audio; +})(typeof self !== 'undefined' ? self : this); diff --git a/extensions/neon-getaway/media/engine.js b/extensions/neon-getaway/media/engine.js new file mode 100644 index 0000000..fcf6819 --- /dev/null +++ b/extensions/neon-getaway/media/engine.js @@ -0,0 +1,833 @@ +/* + * Neon Getaway: the game itself, with no drawing. The city, cars, traffic, people, police, missions and money. + * Runs in the VS Code webview (window.NG) and in Node for the tests (require). + */ +(function (root, factory) { + if (typeof module === 'object' && module.exports) module.exports = factory(); + else root.NG = factory(); +})(typeof self !== 'undefined' ? self : this, function () { + 'use strict'; + + // ------------------------------------------------------------------ basics + + const T = 32; // world pixels per tile + const TILE = { WATER: 0, SAND: 1, ROAD: 2, WALK: 3, BUILD: 4, GRASS: 5, TREE: 6, LOT: 7, PIER: 8 }; + const W = 128, H = 128; + const ROADS = []; for (let p = 10; p <= 118; p += 12) ROADS.push(p); // each road line is 2 tiles: p and p+1 + const ROAD_MIN = ROADS[0], ROAD_MAX = ROADS[ROADS.length - 1] + 1; + const DIRS = [[1, 0], [0, 1], [-1, 0], [0, -1]]; // E S W N + const PED_TILES = new Set([TILE.WALK, TILE.LOT, TILE.GRASS, TILE.SAND, TILE.PIER]); + + const clamp = (v, a, b) => (v < a ? a : v > b ? b : v); + const wrapAngle = a => { while (a > Math.PI) a -= 2 * Math.PI; while (a < -Math.PI) a += 2 * Math.PI; return a; }; + const dist = (ax, ay, bx, by) => Math.hypot(ax - bx, ay - by); + + /** mulberry32: a small seeded random generator, so every player gets the same city. */ + function rng(seed) { + let s = seed >>> 0; + return () => { + s = (s + 0x6D2B79F5) >>> 0; + let t = s; + t = Math.imul(t ^ (t >>> 15), t | 1); + t ^= t + Math.imul(t ^ (t >>> 7), t | 61); + return ((t ^ (t >>> 14)) >>> 0) / 4294967296; + }; + } + const pick = (r, list) => list[Math.floor(r() * list.length)]; + + const MODELS = { + compact: { name: 'Bolt Compact', max: 430, accel: 330, brake: 760, turn: 3.2, grip: 0.8, len: 34, wid: 17, price: 0, colors: ['#4cdcf2', '#f7d154', '#ff6b9a', '#9ad16f', '#e9e4dc'] }, + muscle: { name: 'Pulse GT', max: 545, accel: 410, brake: 780, turn: 2.85, grip: 0.76, len: 40, wid: 19, price: 1500, colors: ['#ff4f6d', '#f39a2b', '#1c1c28'] }, + sports: { name: 'Vapor S', max: 635, accel: 490, brake: 860, turn: 3.25, grip: 0.84, len: 38, wid: 18, price: 4000, colors: ['#b79bff', '#68f4d1', '#ff3fa4'] }, + super: { name: 'Hyperion', max: 725, accel: 570, brake: 920, turn: 3.35, grip: 0.87, len: 40, wid: 19, price: 9000, colors: ['#fdf05a', '#ffffff', '#ff7b2e'] }, + taxi: { name: 'City Cab', max: 440, accel: 320, brake: 760, turn: 3.0, grip: 0.8, len: 36, wid: 18, price: 0, colors: ['#ffd33d'] }, + van: { name: 'Haul Van', max: 360, accel: 240, brake: 640, turn: 2.4, grip: 0.82, len: 42, wid: 20, price: 0, colors: ['#d9dde4', '#5b6b8c', '#7f5539'] }, + police: { name: 'Patrol Interceptor', max: 590, accel: 470, brake: 860, turn: 3.05, grip: 0.84, len: 40, wid: 19, price: 0, colors: ['#10131c'] }, + }; + const GARAGE = ['compact', 'muscle', 'sports', 'super']; + + // ------------------------------------------------------------------ the city + + const DISTRICTS = [ + { name: 'Neon Heights', tall: [5, 12], parks: 0.08, lots: 0.08, roof: ['#2a2350', '#1f2a4f', '#2f2046'], neon: ['#ff3fa4', '#4cdcf2', '#b79bff'] }, + { name: 'Palm Shore', tall: [1, 3], parks: 0.28, lots: 0.12, roof: ['#3d3358', '#4a3a52', '#2f3f55'], neon: ['#ffd35c', '#ff7b9c', '#68f4d1'] }, + { name: 'Dockside', tall: [2, 4], parks: 0.05, lots: 0.3, roof: ['#32323e', '#3a3328', '#2c3238'], neon: ['#f39a2b', '#fdf05a', '#4cdcf2'] }, + { name: 'Old Town', tall: [2, 5], parks: 0.16, lots: 0.12, roof: ['#3b2a30', '#2d3a34', '#3a3245'], neon: ['#68f4d1', '#ff6b6b', '#ffd35c'] }, + ]; + const districtAt = (tx, ty) => DISTRICTS[(tx >= W / 2 ? 1 : 0) + (ty >= H / 2 ? 2 : 0)]; + + /** Block (i, j) spans tiles ROADS[i]+2 .. ROADS[i+1]-1; its 8x8 inside starts one tile in. */ + const blockOrigin = (i, j) => [ROADS[i] + 3, ROADS[j] + 3]; + const SPECIAL = { + garage: [4, 4, "Rico's Garage", '#68f4d1'], + police: [2, 6, 'Police HQ', '#4c8dff'], + spray: [6, 2, 'Fresh Coat Spray', '#ff3fa4'], + bank: [1, 1, 'Solara Savings', '#ffd35c'], + raceStart: [7, 6, 'Race Start', '#fdf05a'], + }; + + function makeCity(seed = 1986) { + const r = rng(seed); + const tiles = new Uint8Array(W * H).fill(TILE.WALK); + const set = (x, y, t) => { if (x >= 0 && y >= 0 && x < W && y < H) tiles[y * W + x] = t; }; + const get = (x, y) => (x < 0 || y < 0 || x >= W || y >= H ? TILE.WATER : tiles[y * W + x]); + for (let y = 0; y < H; y++) for (let x = 0; x < W; x++) { + const edge = Math.min(x, y, W - 1 - x, H - 1 - y); + if (edge < 5) set(x, y, TILE.WATER); else if (edge < 8) set(x, y, TILE.SAND); + } + for (const p of ROADS) for (let k = ROAD_MIN; k <= ROAD_MAX; k++) { + set(p, k, TILE.ROAD); set(p + 1, k, TILE.ROAD); set(k, p, TILE.ROAD); set(k, p + 1, TILE.ROAD); + } + + const buildings = [], parked = [], trees = [], poi = {}, lots = []; + const special = {}; + for (const [key, [i, j]] of Object.entries(SPECIAL)) special[`${i},${j}`] = key; + + const addBuilding = (x, y, w, h, d, extra) => { + for (let yy = y; yy < y + h; yy++) for (let xx = x; xx < x + w; xx++) set(xx, yy, TILE.BUILD); + buildings.push(Object.assign({ x, y, w, h, floors: Math.round(d.tall[0] + r() * (d.tall[1] - d.tall[0])), roof: pick(r, d.roof), neon: pick(r, d.neon), seed: Math.floor(r() * 1e9) }, extra || {})); + }; + + for (let i = 0; i < ROADS.length - 1; i++) for (let j = 0; j < ROADS.length - 1; j++) { + const [ox, oy] = blockOrigin(i, j); + const d = districtAt(ox + 4, oy + 4); + const key = special[`${i},${j}`]; + if (key) { + const [, , label, colour] = SPECIAL[key]; + if (key === 'raceStart') { // an open plaza + for (let yy = 0; yy < 8; yy++) for (let xx = 0; xx < 8; xx++) set(ox + xx, oy + yy, TILE.LOT); + } else { + addBuilding(ox, oy, 8, 5, d, { label, neon: colour, special: key, floors: key === 'bank' ? 14 : 4 }); + for (let yy = 5; yy < 8; yy++) for (let xx = 0; xx < 8; xx++) set(ox + xx, oy + yy, TILE.LOT); + } + poi[key] = { x: (ox + 4) * T, y: (oy + 6.5) * T, label, colour }; + continue; + } + const roll = r(); + if (roll < d.parks) { // a park with trees + for (let yy = 0; yy < 8; yy++) for (let xx = 0; xx < 8; xx++) set(ox + xx, oy + yy, TILE.GRASS); + for (let n = 0; n < 7; n++) { + const tx = ox + 1 + Math.floor(r() * 6), ty = oy + 1 + Math.floor(r() * 6); + if (get(tx, ty) === TILE.GRASS && (tx - ox) % 3 !== 2) { set(tx, ty, TILE.TREE); trees.push([tx, ty]); } + } + } else if (roll < d.parks + d.lots) { // a parking lot + for (let yy = 0; yy < 8; yy++) for (let xx = 0; xx < 8; xx++) set(ox + xx, oy + yy, TILE.LOT); + lots.push({ x: (ox + 4) * T, y: (oy + 4) * T, district: d.name }); + for (let row = 0; row < 2; row++) for (let n = 0; n < 4; n++) if (r() < 0.55) { + const model = r() < 0.12 ? 'muscle' : r() < 0.1 ? 'van' : 'compact'; + parked.push({ model, x: (ox + 1 + n * 2) * T, y: (oy + 1.5 + row * 5) * T, a: Math.PI / 2 + (row ? Math.PI : 0), color: pick(r, MODELS[model].colors) }); + } + } else { // buildings with alleys between them + const plan = pick(r, [[[0, 0, 8, 8]], [[0, 0, 4, 8], [5, 0, 3, 8]], [[0, 0, 8, 4], [0, 5, 8, 3]], [[0, 0, 4, 4], [5, 0, 3, 4], [0, 5, 4, 3], [5, 5, 3, 3]]]); + for (const [x, y, w, h] of plan) addBuilding(ox + x, oy + y, w, h, d); + } + } + + // The pier: a boardwalk out over the water from the south beach, where the boat leaves. + const px = ROADS[5] + 6; + for (let y = ROAD_MAX + 1; y < H - 1; y++) for (let x = px; x < px + 4; x++) set(x, y, TILE.PIER); + poi.pier = { x: (px + 2) * T, y: (H - 3) * T, label: 'The Pier', colour: '#4cdcf2' }; + poi.busStop = { x: (ROADS[4] + 2.5) * T, y: (ROADS[5] - 0.5) * T, label: 'Bus stop', colour: '#e9e4dc' }; + // A Vapor S waits in a Palm Shore lot for the "Hot Wheels" job. + const palm = lots.find(l => l.district === 'Palm Shore') || lots[0]; + poi.lotPalm = { x: palm.x, y: palm.y, label: 'Palm Shore lot', colour: '#b79bff' }; + poi.taxi = [poi.busStop, { x: (ROADS[7] + 2.5) * T, y: (ROADS[2] - 0.5) * T }, { x: (ROADS[2] + 2.5) * T, y: (ROADS[7] - 0.5) * T }] + .map((p, n) => ({ x: p.x, y: p.y, label: `Taxi stand ${n + 1}`, colour: '#ffd33d' })); + + // Twenty cassette tapes, hidden on sidewalks, in parks and on the beach. + const tapes = []; + for (let guard = 0; tapes.length < 20 && guard < 20000; guard++) { + const tx = 6 + Math.floor(r() * (W - 12)), ty = 6 + Math.floor(r() * (H - 12)); + const t = get(tx, ty); + if ((t === TILE.WALK || t === TILE.GRASS || t === TILE.SAND) && tapes.every(p => Math.abs(p.tx - tx) + Math.abs(p.ty - ty) > 14)) + tapes.push({ id: tapes.length, tx, ty, x: (tx + 0.5) * T, y: (ty + 0.5) * T }); + } + + const city = { + seed, W, H, T, tiles, buildings, parked, trees, poi, lots, tapes, + get, tileAtPx: (x, y) => get(Math.floor(x / T), Math.floor(y / T)), + isRoadTile: (x, y) => get(x, y) === TILE.ROAD, + districtAtPx: (x, y) => districtAt(x / T, y / T).name, + }; + return city; + } + + const solid = t => t === TILE.WATER || t === TILE.BUILD || t === TILE.TREE; + const slow = t => t === TILE.SAND || t === TILE.GRASS; + + /** Does a circle at (x, y) touch a wall, a building, a tree or the sea? */ + function hitsSolid(city, x, y, r) { + const x0 = Math.floor((x - r) / T), x1 = Math.floor((x + r) / T), y0 = Math.floor((y - r) / T), y1 = Math.floor((y + r) / T); + for (let ty = y0; ty <= y1; ty++) for (let tx = x0; tx <= x1; tx++) { + if (!solid(city.get(tx, ty))) continue; + const cx = clamp(x, tx * T, tx * T + T), cy = clamp(y, ty * T, ty * T + T); + if ((x - cx) ** 2 + (y - cy) ** 2 < r * r) return true; + } + return false; + } + + /** Nothing solid on the straight line between two points. */ + function lineOfSight(city, ax, ay, bx, by) { + const d = dist(ax, ay, bx, by), n = Math.ceil(d / 20); + for (let k = 1; k < n; k++) if (solid(city.tileAtPx(ax + (bx - ax) * k / n, ay + (by - ay) * k / n))) return false; + return true; + } + + // Road network: intersections are a 10 x 10 grid of nodes. + const nodeXY = (i, j) => [(ROADS[i] + 1) * T, (ROADS[j] + 1) * T]; + function nearestNode(x, y) { + let bi = 0, bj = 0, best = Infinity; + for (let i = 0; i < ROADS.length; i++) for (let j = 0; j < ROADS.length; j++) { + const [nx, ny] = nodeXY(i, j), d = Math.abs(nx - x) + Math.abs(ny - y); + if (d < best) { best = d; bi = i; bj = j; } + } + return [bi, bj]; + } + /** A point on the roads, nearest to (x, y): where you respawn and where traffic appears. */ + function nearestRoadPoint(city, x, y) { + const tx = Math.floor(x / T), ty = Math.floor(y / T); + for (let r = 0; r < 40; r++) for (let dy = -r; dy <= r; dy++) for (let dx = -r; dx <= r; dx++) { + if (Math.max(Math.abs(dx), Math.abs(dy)) !== r) continue; + if (city.isRoadTile(tx + dx, ty + dy)) return [(tx + dx + 0.5) * T, (ty + dy + 0.5) * T]; + } + return [nodeXY(0, 0)[0], nodeXY(0, 0)[1]]; + } + + // ------------------------------------------------------------------ vehicles + + let nextId = 1; + function makeCar(kind, model, x, y, a, color) { + const m = MODELS[model]; + return { id: nextId++, kind, model, x, y, a: a || 0, vx: 0, vy: 0, f: 0, color: color || m.colors[0], dir: 0, v: 0, pending: null, lastNode: '', stun: 0, honk: 0, stuck: 0, reverse: 0, wp: null, wpAt: 0, siren: kind === 'police', drift: 0 }; + } + const carRadius = c => MODELS[c.model].len * 0.42; + const isDynamic = c => c.kind === 'player' || c.kind === 'police' || c.kind === 'rival' || c.kind === 'loose'; + + /** Two circles along the car: front and back. */ + function carHits(city, c, x, y, a) { + const m = MODELS[c.model], off = m.len * 0.27, rr = m.wid * 0.55, ca = Math.cos(a), sa = Math.sin(a); + return hitsSolid(city, x + ca * off, y + sa * off, rr) || hitsSolid(city, x - ca * off, y - sa * off, rr); + } + + /** + * Arcade car handling. input: throttle -1..1, steer -1..1, handbrake. Returns the impact speed of a crash, if any. + * Forward speed builds with throttle; sideways speed is gripped away each frame (much less with the handbrake: a drift). + */ + function drive(city, c, input, dt) { + const m = MODELS[c.model]; + const off = slow(city.tileAtPx(c.x, c.y)); + const max = m.max * (off ? 0.55 : 1); + // Turn the car first. Its velocity doesn't turn with it: whatever is now sideways is the slide that grip removes. + const f0 = c.vx * Math.cos(c.a) + c.vy * Math.sin(c.a); + const speedFactor = clamp(Math.abs(f0) / 160, 0, 1) * (1 - 0.3 * clamp((Math.abs(f0) - max * 0.6) / max, 0, 1)); + const newA = c.a + (input.steer || 0) * m.turn * speedFactor * dt * (f0 >= 0 ? 1 : -1) * (input.handbrake ? 1.4 : 1); + if (!carHits(city, c, c.x, c.y, newA)) c.a = newA; + const ca = Math.cos(c.a), sa = Math.sin(c.a); + let f = c.vx * ca + c.vy * sa; + let s = -c.vx * sa + c.vy * ca; + const th = input.throttle || 0; + if (th > 0) f += f < -5 ? m.brake * dt : m.accel * th * dt * (1 - 0.55 * clamp(f / max, 0, 1)); + else if (th < 0) f -= f > 5 ? m.brake * dt : m.accel * 0.6 * dt; + else f -= Math.sign(f) * Math.min(Math.abs(f), 140 * dt); + if (off) f *= 1 - 0.9 * dt; + if (input.handbrake) f *= Math.pow(0.986, dt * 60); + f = clamp(f, -max * 0.4, max); + + const keep = input.handbrake ? Math.pow(0.955, dt * 60) : Math.pow(1 - m.grip, dt * 60); + s *= keep; + c.drift = Math.abs(s) > 110 ? Math.abs(s) : 0; + c.vx = ca * f - sa * s; + c.vy = sa * f + ca * s; + c.f = f; + return moveCar(city, c, dt); + } + + function moveCar(city, c, dt) { + let impact = 0; + const steps = Math.max(1, Math.ceil(Math.hypot(c.vx, c.vy) * dt / 10)); + const h = dt / steps; + for (let k = 0; k < steps; k++) { + const nx = c.x + c.vx * h; + if (carHits(city, c, nx, c.y, c.a)) { impact = Math.max(impact, Math.abs(c.vx)); c.vx *= -0.25; } else c.x = nx; + const ny = c.y + c.vy * h; + if (carHits(city, c, c.x, ny, c.a)) { impact = Math.max(impact, Math.abs(c.vy)); c.vy *= -0.25; } else c.y = ny; + } + return impact; + } + + /** Steering a computer-driven car toward a point, around walls. */ + function steerTo(city, c, tx, ty, dt, opts) { + const o = opts || {}; + const speed = Math.hypot(c.vx, c.vy); + if (c.reverse > 0) { + c.reverse -= dt; + return { throttle: -1, steer: c.revSteer || 1, handbrake: false }; + } + let diff = wrapAngle(Math.atan2(ty - c.y, tx - c.x) - c.a); + const look = 42 + speed * 0.22; + const probe = a => !hitsSolid(city, c.x + Math.cos(c.a + a) * look, c.y + Math.sin(c.a + a) * look, 10); + if (!probe(0)) diff += probe(0.6) ? 0.9 : probe(-0.6) ? -0.9 : 0; + const steer = clamp(diff * 2.4, -1, 1); + let throttle = Math.abs(diff) > 1.7 ? 0.35 : (o.cap != null ? o.cap : 1); + const d = dist(c.x, c.y, tx, ty); + if (o.slowNear && d < 110 && Math.abs(diff) > 0.5) throttle = Math.min(throttle, 0.45); + if (speed < 25 && throttle > 0.3) c.stuck += dt; else c.stuck = Math.max(0, c.stuck - dt * 2); + if (c.stuck > 1.1) { c.stuck = 0; c.reverse = 0.8; c.revSteer = diff > 0 ? -1 : 1; } + return { throttle, steer, handbrake: Math.abs(diff) > 1.2 && speed > 260 }; + } + + /** Where a computer driver should head next to reach (tx, ty): straight there if it can see it, else along the roads. */ + function routeTo(city, c, tx, ty, now) { + if (dist(c.x, c.y, tx, ty) < 900 && lineOfSight(city, c.x, c.y, tx, ty)) { c.wp = null; return [tx, ty]; } + const [gi, gj] = nearestNode(tx, ty); + const reached = c.wp && dist(c.x, c.y, ...nodeXY(c.wp[0], c.wp[1])) < 55; + if (!c.wp || reached || now - c.wpAt > 5) { + let [i, j] = reached ? c.wp : nearestNode(c.x, c.y); + if (reached || dist(c.x, c.y, ...nodeXY(i, j)) < 55) { // at an intersection: one block closer to the target + const di = gi - i, dj = gj - j; + if (di && (Math.abs(di) >= Math.abs(dj) || !dj)) i += Math.sign(di); else if (dj) j += Math.sign(dj); + } + c.wp = [i, j]; c.wpAt = now; + } + if (c.wp[0] === gi && c.wp[1] === gj && dist(c.x, c.y, ...nodeXY(gi, gj)) < 55) return [tx, ty]; + return nodeXY(c.wp[0], c.wp[1]); + } + + // Traffic drives in lanes: right-hand traffic, so southbound uses a road's left tile and northbound its right one. + const laneCoord = (dir, line) => (dir === 0 ? (line + 1.5) * T : dir === 2 ? (line + 0.5) * T : dir === 1 ? (line + 0.5) * T : (line + 1.5) * T); + const roadLineAt = tile => ROADS.find(p => tile === p || tile === p + 1); + + function placeTraffic(city, r, cx, cy, minD, maxD) { + for (let k = 0; k < 60; k++) { + const horizontal = r() < 0.5, line = pick(r, ROADS); + const along = ROAD_MIN + 1 + Math.floor(r() * (ROAD_MAX - ROAD_MIN - 1)); + if (roadLineAt(along) !== undefined) continue; // not in an intersection + const dir = horizontal ? (r() < 0.5 ? 0 : 2) : (r() < 0.5 ? 1 : 3); + const x = horizontal ? (along + 0.5) * T : laneCoord(dir, line); + const y = horizontal ? laneCoord(dir, line) : (along + 0.5) * T; + const d = dist(x, y, cx, cy); + if (d < minD || d > maxD) continue; + const model = r() < 0.15 ? 'taxi' : r() < 0.12 ? 'van' : r() < 0.1 ? 'muscle' : 'compact'; + const car = makeCar('traffic', model, x, y, dir * Math.PI / 2, pick(r, MODELS[model].colors)); + car.dir = dir; car.v = 120; car.cruise = 150 + r() * 80; + return car; + } + return null; + } + + function trafficStep(w, c, dt) { + if (c.stun > 0) { c.stun -= dt; c.v = 0; return; } + const [dx, dy] = DIRS[c.dir]; + let target = c.cruise; + for (const o of w.cars) { // keep a gap to whatever's ahead in the lane + if (o === c) continue; + const rx = o.x - c.x, ry = o.y - c.y, ahead = rx * dx + ry * dy, side = Math.abs(rx * -dy + ry * dx); + if (ahead > 0 && ahead < 78 && side < 16) target = Math.min(target, ahead < 46 ? 0 : c.cruise * (ahead - 46) / 32); + } + if (!w.player.car) { + const rx = w.player.x - c.x, ry = w.player.y - c.y, ahead = rx * dx + ry * dy, side = Math.abs(rx * -dy + ry * dx); + if (ahead > 0 && ahead < 60 && side < 16) target = 0; + } + c.v += clamp(target - c.v, -520 * dt, 220 * dt); + if (c.v < 1 && target === 0) c.honk += dt; else c.honk = 0; + const step = c.v * dt; + // Intersections: decide once, then turn into the new lane when we reach it. + const fx = Math.floor((c.x + dx * 22) / T), fy = Math.floor((c.y + dy * 22) / T); + const vl = roadLineAt(fx), hl = roadLineAt(fy); + if (vl !== undefined && hl !== undefined && c.pending == null && c.lastNode !== `${vl},${hl}`) { + const ok = d => d !== (c.dir + 2) % 4 && city_road_beyond(w.city, vl, hl, d); + const straight = ok(c.dir) ? [c.dir, c.dir] : []; + const options = [...straight, (c.dir + 1) % 4, (c.dir + 3) % 4].filter(ok); + const nd = options.length ? pick(w.rand, options) : (c.dir + 2) % 4; + c.lastNode = `${vl},${hl}`; + if (nd !== c.dir) c.pending = { dir: nd, at: laneCoord(nd, nd % 2 ? vl : hl), vl, hl }; + } + c.x += dx * step; c.y += dy * step; + if (c.pending) { + const p = c.pending, uturn = p.dir === (c.dir + 2) % 4; + const passed = uturn || (dx ? (c.x - p.at) * dx >= 0 : (c.y - p.at) * dy >= 0); + if (passed) { + if (!uturn) { if (dx) c.x = p.at; else c.y = p.at; } + c.dir = p.dir; c.pending = null; + if (DIRS[c.dir][0]) c.y = laneCoord(c.dir, p.hl); else c.x = laneCoord(c.dir, p.vl); // into the new lane + } + } + c.a = c.dir * Math.PI / 2; + c.vx = dx * c.v; c.vy = dy * c.v; + } + function city_road_beyond(city, vl, hl, d) { + const x = d === 0 ? vl + 2 : d === 2 ? vl - 1 : vl, y = d === 1 ? hl + 2 : d === 3 ? hl - 1 : hl; + return city.isRoadTile(x, y); + } + + // ------------------------------------------------------------------ people + + function makePed(r, x, y) { + return { id: nextId++, x, y, a: r() * Math.PI * 2, speed: 34 + r() * 22, dodge: 0, shout: 0, look: Math.floor(r() * 6), turn: 1 + r() * 3 }; + } + function pedStep(w, p, dt) { + p.shout = Math.max(0, p.shout - dt); + if (p.dodge > 0) { // diving out of the way: people always get clear + p.dodge -= dt; + const nx = p.x + Math.cos(p.da) * 240 * dt, ny = p.y + Math.sin(p.da) * 240 * dt; + if (!hitsSolid(w.city, nx, ny, 6)) { p.x = nx; p.y = ny; } + return; + } + for (const c of w.cars) { + const sp = Math.hypot(c.vx, c.vy); + if (sp < 90) continue; + const rx = p.x - c.x, ry = p.y - c.y, d = Math.hypot(rx, ry); + const toward = (rx * c.vx + ry * c.vy) / (d * sp + 1e-6); + if (d < 46 + sp * 0.12 && toward > 0.55) { + const side = Math.sign(rx * -c.vy + ry * c.vx) || 1; + p.da = Math.atan2(c.vy, c.vx) + side * Math.PI / 2; p.dodge = 0.45; p.shout = 1.6; + if (c.kind === 'player') w.emit('nearMiss'); + return; + } + } + p.turn -= dt; + const nx = p.x + Math.cos(p.a) * p.speed * dt, ny = p.y + Math.sin(p.a) * p.speed * dt; + if (p.turn < 0 || !PED_TILES.has(w.city.tileAtPx(nx, ny)) || hitsSolid(w.city, nx, ny, 6)) { + p.a = Math.floor(w.rand() * 4) * Math.PI / 2 + (w.rand() - 0.5) * 0.3; p.turn = 1.5 + w.rand() * 4; + } else { p.x = nx; p.y = ny; } + } + function placePed(w, cx, cy, minD, maxD) { + for (let k = 0; k < 80; k++) { + const a = w.rand() * Math.PI * 2, d = minD + w.rand() * (maxD - minD), x = cx + Math.cos(a) * d, y = cy + Math.sin(a) * d; + if (w.city.tileAtPx(x, y) === TILE.WALK && !hitsSolid(w.city, x, y, 7)) return makePed(w.rand, x, y); + } + return null; + } + + // ------------------------------------------------------------------ missions + + const MISSIONS = [ + { id: 'wheels', title: 'Fresh Off the Bus', from: 'Rico', start: 'busStop', reward: 250, + intro: "Welcome to Solara Bay, kid. You need wheels. Grab one, then come see me at the garage.", + steps: [{ type: 'enterCar', text: 'Find a car: walk up to one and press E.' }, { type: 'goto', poi: 'garage', car: true, text: "Drive to Rico's Garage." }] }, + { id: 'delivery', title: 'Special Delivery', from: 'Rico', start: 'garage', reward: 450, + intro: "A client at the pier wants this package. Don't ask what's in it. Don't be late.", + steps: [{ type: 'goto', poi: 'pier', car: true, timer: 75, text: 'Deliver the package to the pier before time runs out.' }] }, + { id: 'hotwheels', title: 'Hot Wheels', from: 'Rico', start: 'garage', reward: 900, + intro: 'There\'s a Vapor S sitting in a Palm Shore lot. Its owner owes me. Bring it here.', + steps: [{ type: 'stealCar', model: 'sports', poi: 'lotPalm', stars: 2, text: 'Take the Vapor S from the Palm Shore lot.' }, { type: 'goto', poi: 'garage', model: 'sports', text: 'The alarm called the cops. Bring the Vapor S to the garage.' }] }, + { id: 'getaway', title: 'The Getaway', from: 'Nova', start: 'garage', reward: 1600, + intro: "I'm Nova. I need a driver who doesn't panic. Pick me up at Solara Savings. Keep the engine running.", + steps: [{ type: 'goto', poi: 'bank', car: true, text: 'Pick Nova up outside Solara Savings.' }, { type: 'heat', stars: 3, text: 'The alarm is ringing. Lose the cops!' }, { type: 'goto', poi: 'garage', car: true, text: 'Bring Nova back to the garage.' }] }, + { id: 'kings', title: 'Street Kings', from: 'Nova', start: 'raceStart', reward: 2200, + intro: "The Street Kings think they own these roads. Prove them wrong.", + steps: [{ type: 'race', text: 'Win the race: hit every checkpoint before the Street Kings.' }] }, + { id: 'bigscore', title: 'The Big Score', from: 'Rico & Nova', start: 'garage', reward: 6000, + intro: 'One last job, then we all disappear. The boat leaves from the pier. Don\'t miss it.', + steps: [{ type: 'goto', poi: 'bank', car: true, text: 'Pick up the crew at Solara Savings.' }, { type: 'heat', stars: 4, text: 'Four stars. Lose them!' }, { type: 'goto', poi: 'pier', car: true, timer: 100, text: 'Make it to the boat at the pier before it leaves!' }] }, + ]; + const RACE = [[7, 6], [7, 2], [3, 2], [3, 7], [8, 8], [8, 6]]; // intersections, then back to the start + + // ------------------------------------------------------------------ the world + + const STAR_COPS = [0, 1, 2, 4, 6, 8]; + const NEW_SAVE = () => ({ v: 1, cash: 300, owned: ['compact'], car: 'compact', story: 0, tapes: [], bestRace: 0, stats: { missions: 0, busted: 0, escapes: 0, nearMisses: 0, distance: 0, topSpeed: 0, taxis: 0, paychecks: 0 } }); + + function createWorld(save, opts) { + const o = opts || {}; + const city = makeCity(o.seed); + const s = Object.assign(NEW_SAVE(), save || {}); + s.stats = Object.assign(NEW_SAVE().stats, (save && save.stats) || {}); + const rand = rng(o.randSeed || 4242); + const w = { + city, rand, save: s, t: 0, events: [], cars: [], peds: [], wanted: { stars: 0, unseen: 0, seen: false, lastRam: -9 }, + player: { x: city.poi.busStop.x, y: city.poi.busStop.y - 20, a: -Math.PI / 2, vx: 0, vy: 0, car: null, busted: 0 }, + mission: null, job: null, race: null, toastCool: 0, + emit(type, data) { w.events.push(Object.assign({ type }, data || {})); }, + }; + for (const p of city.parked) w.cars.push(makeCar('parked', p.model, p.x, p.y, p.a, p.color)); + // Your own car waits at the garage. + const g = city.poi.garage; + const own = makeCar('parked', s.car, g.x, g.y, 0, MODELS[s.car].colors[0]); + own.owned = true; w.cars.push(own); + for (let n = 0; n < 34; n++) { const c = placeTraffic(city, rand, w.player.x, w.player.y, 160, 1500); if (c) w.cars.push(c); } + for (let n = 0; n < 40; n++) { const p = placePed(w, w.player.x, w.player.y, 40, 1100); if (p) w.peds.push(p); } + return w; + } + + const playerPos = w => (w.player.car ? [w.player.car.x, w.player.car.y] : [w.player.x, w.player.y]); + const playerSpeed = w => (w.player.car ? Math.hypot(w.player.car.vx, w.player.car.vy) : Math.hypot(w.player.vx, w.player.vy)); + + function addCash(w, n, why) { w.save.cash = Math.max(0, w.save.cash + n); w.emit('cash', { amount: n, why }); } + function toast(w, text, kind) { w.emit('toast', { text, kind: kind || 'info' }); } + + function setStars(w, n, why) { + const before = w.wanted.stars; + w.wanted.stars = clamp(Math.max(n, 0), 0, 5); + if (w.wanted.stars > before) { w.wanted.unseen = 0; w.emit('wanted', { stars: w.wanted.stars, why }); } + } + + function copSees(w) { + const [x, y] = playerPos(w); + return w.cars.some(c => c.kind === 'police' && dist(c.x, c.y, x, y) < 720 && (dist(c.x, c.y, x, y) < 220 || lineOfSight(w.city, c.x, c.y, x, y))); + } + + /** E: get into the nearest car, or out of yours. */ + function toggleCar(w) { + const p = w.player; + if (p.car) { + const c = p.car; + if (Math.hypot(c.vx, c.vy) > 160) return toast(w, 'Slow down before you jump out!'); + const side = [c.a + Math.PI / 2, c.a - Math.PI / 2].map(a => [c.x + Math.cos(a) * 26, c.y + Math.sin(a) * 26]).find(([x, y]) => !hitsSolid(w.city, x, y, 8)); + if (!side) return toast(w, 'No room to get out here.'); + [p.x, p.y] = side; p.vx = p.vy = 0; + c.kind = 'loose'; p.car = null; + w.emit('exitCar'); + return; + } + let best = null, bd = 50; + for (const c of w.cars) { const d = dist(c.x, c.y, p.x, p.y); if (d < bd) { bd = d; best = c; } } + if (!best) return toast(w, 'No car close enough. Walk up to one.'); + const witnessed = copSees(w); + if (best.kind === 'traffic') { + const ped = makePed(w.rand, best.x + Math.cos(best.a + Math.PI / 2) * 24, best.y + Math.sin(best.a + Math.PI / 2) * 24); + ped.shout = 2.5; ped.dodge = 0.6; ped.da = best.a + Math.PI / 2; w.peds.push(ped); + best.vx = best.vy = 0; + if (witnessed) setStars(w, Math.max(w.wanted.stars, 1), 'Car theft'); + } else if (best.kind === 'police') { + setStars(w, Math.max(w.wanted.stars, 2), 'Stole a police car'); + best.siren = false; + } else if (best.kind === 'parked' && !best.owned && witnessed) setStars(w, Math.max(w.wanted.stars, 1), 'Car theft'); + best.kind = 'player'; best.stun = 0; best.pending = null; + if (best.f === undefined) best.f = 0; + p.car = best; + w.emit('enterCar', { model: best.model, name: MODELS[best.model].name }); + } + + function spawnCops(w, dt) { + const want = STAR_COPS[w.wanted.stars]; + const cops = w.cars.filter(c => c.kind === 'police'); + const [x, y] = playerPos(w); + if (cops.length < want && (w.t - (w.lastCopSpawn || -9)) > 1.4) { + const c = placeTraffic(w.city, w.rand, x, y, 650, 1100); + if (c) { const cop = makeCar('police', 'police', c.x, c.y, c.a); cop.vx = Math.cos(c.a) * 200; cop.vy = Math.sin(c.a) * 200; w.cars.push(cop); w.lastCopSpawn = w.t; } + } + if (cops.length > want) { // they give up: the farthest one drives off first + const far = cops.sort((a, b) => dist(b.x, b.y, x, y) - dist(a.x, a.y, x, y))[0]; + if (dist(far.x, far.y, x, y) > 700 || want === 0) far.leaving = true; + } + void dt; + } + + function copStep(w, c, dt) { + const [px, py] = playerPos(w); + if (c.leaving || w.wanted.stars === 0) { + c.leaving = true; + const inp = steerTo(w.city, c, c.x + Math.cos(c.a) * 300, c.y + Math.sin(c.a) * 300, dt, { cap: 0.6 }); + drive(w.city, c, inp, dt); + return; + } + const lead = w.player.car ? 0.35 : 0; + const [tx, ty] = routeTo(w.city, c, px + (w.player.car ? w.player.car.vx : 0) * lead, py + (w.player.car ? w.player.car.vy : 0) * lead, w.t); + const inp = steerTo(w.city, c, tx, ty, dt, { slowNear: !!c.wp }); + // Right beside a slow or stopped player: box them in and wait, instead of shoving them along. + if (dist(c.x, c.y, px, py) < 95 && playerSpeed(w) < 90) { inp.throttle = Math.hypot(c.vx, c.vy) > 30 ? -1 : 0; inp.handbrake = false; } + drive(w.city, c, inp, dt); + } + + function rivalStep(w, c, dt) { + const r = w.race; + const cp = r.checkpoints[c.cp]; + if (!cp) { c.vx *= 0.95; c.vy *= 0.95; moveCar(w.city, c, dt); return; } + if (dist(c.x, c.y, cp.x, cp.y) < 70) { c.cp++; if (c.cp >= r.checkpoints.length) { c.done = w.t; r.rivalsDone++; } } + const [tx, ty] = routeTo(w.city, c, cp.x, cp.y, w.t); + // A little rubber band keeps the race close. + const ahead = c.cp - r.cp; + const inp = steerTo(w.city, c, tx, ty, dt, { cap: ahead > 0 ? 0.82 : ahead < 0 ? 1 : 0.95, slowNear: !!c.wp }); + drive(w.city, c, inp, dt); + } + + // ------------------------------------------------------------------ missions and jobs + + function poiOf(w, key) { return w.city.poi[key]; } + function startMission(w, idx) { + const m = MISSIONS[idx]; + w.mission = { idx, step: 0, timer: null, startT: w.t }; + w.emit('missionStart', { title: m.title, from: m.from, intro: m.intro }); + enterStep(w); + } + function enterStep(w) { + const m = MISSIONS[w.mission.idx], st = m.steps[w.mission.step]; + w.mission.timer = st.timer || null; + if (st.type === 'heat') setStars(w, st.stars, m.title); + if (st.type === 'stealCar') { + const p = poiOf(w, st.poi); + const car = makeCar('parked', st.model, p.x, p.y, Math.PI / 2, MODELS[st.model].colors[0]); + car.target = true; w.cars.push(car); w.mission.targetCar = car; + } + if (st.type === 'race') startRace(w); + toast(w, st.text, 'mission'); + } + function stepDone(w) { + const m = MISSIONS[w.mission.idx]; + w.mission.step++; + if (w.mission.step >= m.steps.length) { + addCash(w, m.reward, m.title); + w.save.story = Math.max(w.save.story, w.mission.idx + 1); + w.save.stats.missions++; + w.emit('missionPassed', { title: m.title, reward: m.reward }); + if (w.race) endRace(w); + w.mission = null; + return; + } + enterStep(w); + } + function failMission(w, why) { + if (!w.mission) return; + const m = MISSIONS[w.mission.idx]; + w.emit('missionFailed', { title: m.title, why }); + if (w.mission.targetCar && w.mission.targetCar.kind !== 'player') w.cars = w.cars.filter(c => c !== w.mission.targetCar); + if (w.race) endRace(w); + w.mission = null; + } + /** The marker the player is heading for now. */ + function objective(w) { + if (w.mission) { + const st = MISSIONS[w.mission.idx].steps[w.mission.step]; + if (st.type === 'goto') { const p = poiOf(w, st.poi); return { x: p.x, y: p.y, label: p.label, colour: '#fdf05a' }; } + if (st.type === 'stealCar') { const c = w.mission.targetCar; return { x: c.x, y: c.y, label: MODELS[c.model].name, colour: '#b79bff' }; } + if (st.type === 'race' && w.race) { const c = w.race.checkpoints[w.race.cp]; return c ? { x: c.x, y: c.y, label: `Checkpoint ${w.race.cp + 1}/${w.race.checkpoints.length}`, colour: '#fdf05a' } : null; } + return null; + } + if (w.job) return { x: w.job.x, y: w.job.y, label: 'Drop-off', colour: '#ffd33d' }; + return null; + } + function missionStep(w, dt) { + const mm = w.mission; + if (!mm) return; + const st = MISSIONS[mm.idx].steps[mm.step]; + if (mm.timer != null) { mm.timer -= dt; if (mm.timer <= 0) return failMission(w, 'Out of time'); } + const [x, y] = playerPos(w); + const car = w.player.car; + if (st.type === 'enterCar' && car) return stepDone(w); + if (st.type === 'goto') { + const p = poiOf(w, st.poi); + if (dist(x, y, p.x, p.y) < 70 && (!st.car || car) && (!st.model || (car && car.model === st.model))) { + if (w.wanted.stars > 0 && st.poi === 'garage') { if (!mm.warned) { toast(w, 'Lose the cops first! Rico won\'t open up with cops on your tail.'); mm.warned = true; } return; } + if (car && Math.hypot(car.vx, car.vy) > 120) return; + return stepDone(w); + } + if (st.model && mm.targetCar && mm.targetCar.kind === 'loose' && dist(x, y, mm.targetCar.x, mm.targetCar.y) > 1400) return failMission(w, 'You left the Vapor S behind'); + } + if (st.type === 'stealCar' && car && car === mm.targetCar) { setStars(w, st.stars, 'The alarm'); return stepDone(w); } + if (st.type === 'heat' && w.wanted.stars === 0) { toast(w, 'You lost them.', 'good'); return stepDone(w); } + if (st.type === 'race' && w.race) { + const r = w.race, cp = r.checkpoints[r.cp]; + if (cp && dist(x, y, cp.x, cp.y) < 80) { r.cp++; w.emit('checkpoint', { n: r.cp, of: r.checkpoints.length }); } + if (r.rivalsDone > 0) return failMission(w, 'The Street Kings got there first'); + if (r.cp >= r.checkpoints.length) { + const time = w.t - r.start; + if (!w.save.bestRace || time < w.save.bestRace) w.save.bestRace = Math.round(time * 10) / 10; + return stepDone(w); + } + } + } + function startRace(w) { + const checkpoints = RACE.map(([i, j]) => { const [x, y] = nodeXY(i, j); return { x, y }; }); + const s = poiOf(w, 'raceStart'); + const rivals = []; + for (let n = 0; n < 3; n++) { + const c = makeCar('rival', n === 0 ? 'sports' : 'muscle', s.x - 60 + n * 40, s.y + 30, -Math.PI / 2, ['#ff3fa4', '#f39a2b', '#68f4d1'][n]); + c.cp = 0; rivals.push(c); w.cars.push(c); + } + w.race = { checkpoints, cp: 0, start: w.t, rivals, rivalsDone: 0 }; + } + function endRace(w) { w.cars = w.cars.filter(c => c.kind !== 'rival'); w.race = null; } + + /** Taxi stands: pick up a fare, get them there fast. */ + function startJob(w) { + const [x, y] = playerPos(w); + let dest; + for (let k = 0; k < 50; k++) { + const [i, j] = [Math.floor(w.rand() * ROADS.length), Math.floor(w.rand() * ROADS.length)]; + const [nx, ny] = nodeXY(i, j); + if (dist(nx, ny, x, y) > 900) { dest = [nx, ny]; break; } + } + if (!dest) return; + const far = dist(dest[0], dest[1], x, y); + w.job = { x: dest[0], y: dest[1], timer: Math.round(far / 260 + 12), pay: Math.round(far / 12) }; + toast(w, `Fare: get them to the drop-off in ${w.job.timer}s for $${w.job.pay}.`, 'mission'); + } + function jobStep(w, dt) { + const j = w.job; if (!j) return; + j.timer -= dt; + const [x, y] = playerPos(w); + if (!w.player.car) { w.job = null; return toast(w, 'Your fare walked off.'); } + if (dist(x, y, j.x, j.y) < 70) { addCash(w, j.pay, 'Fare'); w.save.stats.taxis++; w.job = null; return; } + if (j.timer <= 0) { w.job = null; toast(w, 'Too slow: the fare got out.', 'bad'); } + } + + /** Enter / F: start a mission, open the garage, take a fare, or get a paint job, depending on where you are. */ + function action(w) { + const [x, y] = playerPos(w); + const next = MISSIONS[w.save.story]; + if (!w.mission && next && dist(x, y, poiOf(w, next.start).x, poiOf(w, next.start).y) < 80) { + if (w.wanted.stars > 0) return toast(w, 'Lose the cops before starting a job.'); + return startMission(w, w.save.story); + } + if (dist(x, y, w.city.poi.garage.x, w.city.poi.garage.y) < 80 && !w.mission) return w.emit('openGarage'); + if (dist(x, y, w.city.poi.spray.x, w.city.poi.spray.y) < 80 && w.player.car) { + if (!w.wanted.stars) return toast(w, 'Your paint looks fine. Come back when the cops are after you.'); + const price = 250; + if (w.save.cash < price) return toast(w, `A fresh coat costs $${price}.`); + addCash(w, -price, 'Spray job'); w.wanted.stars = 0; w.save.stats.escapes++; + return w.emit('sprayed'); + } + if (!w.mission && !w.job && w.player.car && w.city.poi.taxi.some(t => dist(x, y, t.x, t.y) < 80)) return startJob(w); + } + + /** Buy or choose a car in the garage. Returns an error text, or null. */ + function garagePick(w, model) { + const m = MODELS[model]; if (!m || !GARAGE.includes(model)) return 'Unknown car'; + if (!w.save.owned.includes(model)) { + if (w.save.cash < m.price) return `You need $${m.price}.`; + addCash(w, -m.price, m.name); w.save.owned.push(model); + } + w.save.car = model; + const g = w.city.poi.garage; + w.cars = w.cars.filter(c => !(c.owned && c.kind === 'parked')); + if (w.player.car && w.player.car.owned) { w.cars = w.cars.filter(c => c !== w.player.car); w.player.car = null; [w.player.x, w.player.y] = [g.x, g.y + 30]; } + const car = makeCar('parked', model, g.x, g.y, 0, m.colors[0]); car.owned = true; w.cars.push(car); + w.emit('garage', { model, name: m.name }); + return null; + } + + function busted(w) { + const fine = Math.min(w.save.cash, Math.max(100, Math.round(w.save.cash * 0.1))); + w.save.cash -= fine; w.save.stats.busted++; + failMission(w, 'Busted'); + if (w.job) w.job = null; + if (w.player.car) { w.player.car.kind = 'loose'; w.player.car = null; } + const st = w.city.poi.police; + w.player.x = st.x; w.player.y = st.y + 20; w.player.vx = w.player.vy = 0; + w.wanted.stars = 0; w.player.busted = 0; + w.cars = w.cars.filter(c => c.kind !== 'police'); + w.emit('busted', { fine }); + } + + // ------------------------------------------------------------------ one tick + + /** + * Advance the world by dt seconds. input: up/down/left/right/handbrake/sprint booleans, and the one-shot presses + * enter (E) and action (Enter/F). Returns the events of this tick. + */ + function step(w, input, dt) { + dt = Math.min(dt, 1 / 20); + w.t += dt; + w.events = []; + const p = w.player, inp = input || {}; + if (inp.enter) toggleCar(w); + if (inp.action) action(w); + + if (p.car) { + const c = p.car; + const impact = drive(w.city, c, { throttle: (inp.up ? 1 : 0) - (inp.down ? 1 : 0), steer: (inp.right ? 1 : 0) - (inp.left ? 1 : 0), handbrake: !!inp.handbrake }, dt); + if (impact > 140) w.emit('crash', { power: impact }); + const sp = Math.hypot(c.vx, c.vy); + w.save.stats.distance += sp * dt / T * 3; // a tile is about 3 m + w.save.stats.topSpeed = Math.max(w.save.stats.topSpeed, Math.round(sp / T * 3 * 3.6)); + if (c.drift) w.emit('drift', { amount: c.drift }); + // Speeding past a cop who can see you. + if (!w.wanted.stars && sp > MODELS[c.model].max * 0.88 && w.cars.some(o => o.kind === 'police' && dist(o.x, o.y, c.x, c.y) < 380 && lineOfSight(w.city, o.x, o.y, c.x, c.y))) setStars(w, 1, 'Speeding'); + } else { + const sp = inp.sprint ? 190 : 120; + p.vx = ((inp.right ? 1 : 0) - (inp.left ? 1 : 0)) * sp; + p.vy = ((inp.down ? 1 : 0) - (inp.up ? 1 : 0)) * sp; + if (p.vx && p.vy) { p.vx *= 0.7071; p.vy *= 0.7071; } + if (p.vx || p.vy) p.a = Math.atan2(p.vy, p.vx); + const nx = p.x + p.vx * dt; if (!hitsSolid(w.city, nx, p.y, 7) && !w.cars.some(c => dist(c.x, c.y, nx, p.y) < carRadius(c) * 0.8)) p.x = nx; + const ny = p.y + p.vy * dt; if (!hitsSolid(w.city, p.x, ny, 7) && !w.cars.some(c => dist(c.x, c.y, p.x, ny) < carRadius(c) * 0.8)) p.y = ny; + } + + spawnCops(w, dt); + for (const c of w.cars) { + if (c.kind === 'traffic') trafficStep(w, c, dt); + else if (c.kind === 'police') copStep(w, c, dt); + else if (c.kind === 'rival') rivalStep(w, c, dt); + else if (c.kind === 'loose') { drive(w.city, c, { throttle: 0, steer: 0 }, dt); c.vx *= Math.pow(0.4, dt); c.vy *= Math.pow(0.4, dt); if (Math.hypot(c.vx, c.vy) < 5) { c.vx = c.vy = 0; c.kind = 'parked'; c.abandoned = !c.owned; } } + } + + // Car-to-car bumps. + for (let i = 0; i < w.cars.length; i++) { + const a = w.cars[i]; + for (let k = i + 1; k < w.cars.length; k++) { + const b = w.cars[k]; + if (!isDynamic(a) && !isDynamic(b)) continue; + const rr = carRadius(a) + carRadius(b), dx = b.x - a.x, dy = b.y - a.y; + if (Math.abs(dx) > rr || Math.abs(dy) > rr) continue; + const d = Math.hypot(dx, dy); + if (d >= rr || d === 0) continue; + const nx = dx / d, ny = dy / d, overlap = rr - d; + const ad = isDynamic(a), bd = isDynamic(b); + const push = ad && bd ? 0.5 : 1; + if (ad) { a.x -= nx * overlap * push; a.y -= ny * overlap * push; } + if (bd) { b.x += nx * overlap * push; b.y += ny * overlap * push; } + const rel = (a.vx - b.vx) * nx + (a.vy - b.vy) * ny; + if (rel > 0) { + const j = rel * 0.65; + if (ad) { a.vx -= nx * j * (bd ? 1 : 1.4); a.vy -= ny * j * (bd ? 1 : 1.4); } + if (bd) { b.vx += nx * j; b.vy += ny * j; } + if (b.kind === 'traffic' || b.kind === 'parked') b.stun = 1.4; + if (a.kind === 'traffic' || a.kind === 'parked') a.stun = 1.4; + const playerHit = a === p.car || b === p.car; + if (playerHit && rel > 120) { + w.emit('crash', { power: rel }); + const other = a === p.car ? b : a; + if (other.kind === 'police' && w.t - w.wanted.lastRam > 2.5) { w.wanted.lastRam = w.t; setStars(w, Math.max(2, w.wanted.stars + 1), 'Rammed a cop'); } + else if (other.kind !== 'police' && rel > 200 && copSees(w)) setStars(w, Math.max(1, w.wanted.stars), 'Reckless driving'); + } + } + } + } + + // People. + for (const ped of w.peds) pedStep(w, ped, dt); + const [px, py] = playerPos(w); + w.peds = w.peds.filter(q => dist(q.x, q.y, px, py) < 1300); + while (w.peds.length < 40) { const q = placePed(w, px, py, 700, 1200); if (!q) break; w.peds.push(q); } + // Traffic stays around you. + w.cars = w.cars.filter(c => !((c.kind === 'traffic' || (c.kind === 'police' && c.leaving)) && dist(c.x, c.y, px, py) > 1700)); + let loose = w.cars.filter(c => (c.kind === 'loose' || (c.kind === 'parked' && c.abandoned))); + if (loose.length > 25) { const far = loose.sort((a, b) => dist(b.x, b.y, px, py) - dist(a.x, a.y, px, py))[0]; w.cars = w.cars.filter(c => c !== far); } + const traffic = w.cars.reduce((n, c) => n + (c.kind === 'traffic'), 0); + if (traffic < 34) { const c = placeTraffic(w.city, w.rand, px, py, 750, 1500); if (c && !w.cars.some(o => dist(o.x, o.y, c.x, c.y) < 60)) w.cars.push(c); } + + // Wanted: the cops lose you when none of them has seen you for a while. + if (w.wanted.stars > 0) { + w.wanted.seen = copSees(w); + if (w.wanted.seen) w.wanted.unseen = 0; else w.wanted.unseen += dt; + if (w.wanted.unseen > 7 + w.wanted.stars * 2.5) { w.wanted.stars = 0; w.save.stats.escapes++; w.emit('escaped'); } + // Busted: stopped with a cop right next to you. + const close = w.cars.some(c => c.kind === 'police' && !c.leaving && dist(c.x, c.y, px, py) < (p.car ? 62 : 40)); + if (close && playerSpeed(w) < 40) { p.busted += dt; if (p.busted > (p.car ? 2.2 : 1)) busted(w); } else p.busted = Math.max(0, p.busted - dt); + } else { w.wanted.unseen = 0; w.wanted.seen = false; p.busted = 0; } + + missionStep(w, dt); + jobStep(w, dt); + + // Cassette tapes. + for (const tp of w.city.tapes) if (!w.save.tapes.includes(tp.id) && dist(tp.x, tp.y, px, py) < 30) { + w.save.tapes.push(tp.id); addCash(w, 100, 'Tape'); + w.emit('tape', { got: w.save.tapes.length, of: w.city.tapes.length }); + } + return w.events; + } + + /** Money earned while coding (the extension sends it in). */ + function paycheck(w, amount) { + if (!(amount > 0)) return; + addCash(w, Math.round(amount), 'Paycheck'); + w.save.stats.paychecks += Math.round(amount); + } + + return { + T, TILE, W, H, ROADS, MODELS, GARAGE, MISSIONS, DISTRICTS, STAR_COPS, NEW_SAVE, + rng, makeCity, hitsSolid, lineOfSight, nearestRoadPoint, nodeXY, nearestNode, makeCar, drive, steerTo, routeTo, + createWorld, step, toggleCar, action, garagePick, startMission, objective, paycheck, setStars, playerPos, playerSpeed, copSees, carRadius, + }; +}); diff --git a/extensions/neon-getaway/media/game.css b/extensions/neon-getaway/media/game.css new file mode 100644 index 0000000..b650a6a --- /dev/null +++ b/extensions/neon-getaway/media/game.css @@ -0,0 +1,2 @@ +html, body { margin: 0; height: 100%; overflow: hidden; background: #07081a; } +canvas { display: block; outline: none; image-rendering: auto; } diff --git a/extensions/neon-getaway/media/game.js b/extensions/neon-getaway/media/game.js new file mode 100644 index 0000000..59fc2aa --- /dev/null +++ b/extensions/neon-getaway/media/game.js @@ -0,0 +1,709 @@ +/* Neon Getaway: drawing, input, menus and saving. The rules live in engine.js (window.NG). */ +(function () { + 'use strict'; + const NG = window.NG, T = NG.T, TILE = NG.TILE; + const vscode = typeof acquireVsCodeApi === 'function' ? acquireVsCodeApi() : { postMessage() {}, getState() {}, setState() {} }; + const canvas = document.getElementById('game'); + const ctx = canvas.getContext('2d'); + const audio = new window.NGAudio(); + + // ---------------------------------------------------------------- state + + let world = NG.createWorld(); + let mode = 'title'; // title | play | pause | garage | map + let menuIndex = 0, garageIndex = 0; + let soundSetting = true, firstKey = false, showHelp = true; + const cam = { x: world.player.x, y: world.player.y, zoom: 1 }; + const toasts = [], banners = [], floaters = [], skid = [], sparks = []; + let cashShown = world.save.cash, lastSave = 0, dirty = false, lastDistrict = '', districtTimer = 0, flash = 0; + let W = 0, H = 0, DPR = 1; + + function resize() { + DPR = Math.min(window.devicePixelRatio || 1, 2); + W = window.innerWidth; H = window.innerHeight; + canvas.width = Math.round(W * DPR); canvas.height = Math.round(H * DPR); + canvas.style.width = W + 'px'; canvas.style.height = H + 'px'; + } + window.addEventListener('resize', resize); resize(); + + // ---------------------------------------------------------------- input + + const keys = new Set(); + const pressed = new Set(); + const KEYMAP = { ArrowUp: 'up', KeyW: 'up', ArrowDown: 'down', KeyS: 'down', ArrowLeft: 'left', KeyA: 'left', ArrowRight: 'right', KeyD: 'right', Space: 'handbrake', ShiftLeft: 'sprint', ShiftRight: 'sprint' }; + window.addEventListener('keydown', e => { + if (['Tab', 'Space', 'ArrowUp', 'ArrowDown', 'ArrowLeft', 'ArrowRight'].includes(e.code)) e.preventDefault(); + if (!firstKey) { firstKey = true; if (soundSetting) audio.start(); } + if (!e.repeat) pressed.add(e.code); + keys.add(e.code); + }); + window.addEventListener('keyup', e => keys.delete(e.code)); + window.addEventListener('blur', () => { keys.clear(); if (mode === 'play') mode = 'pause'; }); + const held = name => Object.entries(KEYMAP).some(([code, n]) => n === name && keys.has(code)); + const hit = (...codes) => codes.some(c => pressed.has(c)); + + // ---------------------------------------------------------------- messages from VS Code + + window.addEventListener('message', ev => { + const m = ev.data || {}; + if (m.type === 'init') { + world = NG.createWorld(m.save || null); + soundSetting = m.sound !== false; audio.setOn(soundSetting && firstKey); + showHelp = !(m.save && m.save.stats && m.save.stats.missions > 0); + cashShown = world.save.cash; + Object.assign(cam, { x: world.player.x, y: world.player.y }); + if (m.paycheck > 0) payday(m.paycheck); + } + if (m.type === 'paycheck' && m.amount > 0) payday(m.amount); + }); + function payday(amount) { + NG.paycheck(world, amount); + banner(`YOUR CODE PAID OUT +$${amount.toLocaleString('en')}`, '#68f4d1', 3.2); + audio.fx('cash'); saveNow(); vscode.postMessage({ type: 'paid', amount }); + } + function saveNow() { vscode.postMessage({ type: 'save', save: world.save }); lastSave = performance.now(); dirty = false; } + + // ---------------------------------------------------------------- messages on screen + + function toast(text, kind) { toasts.push({ text, kind: kind || 'info', t: 5.5 }); while (toasts.length > 3) toasts.shift(); } + function banner(text, colour, t, sub) { banners.length = 0; banners.push({ text, colour, t: t || 2.6, life: t || 2.6, sub }); } + function floater(text, colour) { floaters.push({ text, colour, t: 1.4 }); } + + function handle(events) { + for (const e of events) { + switch (e.type) { + case 'toast': toast(e.text, e.kind); break; + case 'cash': if (e.amount > 0) { floater(`+$${e.amount.toLocaleString('en')}`, '#68f4d1'); audio.fx('cash'); } else floater(`-$${(-e.amount).toLocaleString('en')}`, '#ff6b8a'); dirty = true; break; + case 'enterCar': toast(e.name); audio.fx('door'); break; + case 'exitCar': audio.fx('door'); break; + case 'crash': flash = Math.min(0.5, e.power / 900); addSparks(); audio.fx('crash', e.power); break; + case 'wanted': banner('WANTED', '#ff3fa4', 1.8, e.why); audio.fx('wanted'); break; + case 'escaped': banner('YOU LOST THEM', '#68f4d1', 2.4); dirty = true; break; + case 'busted': banner('BUSTED', '#4c8dff', 3.4, `Fined $${e.fine.toLocaleString('en')}`); audio.fx('busted'); dirty = true; break; + case 'missionStart': banner(e.title.toUpperCase(), '#fdf05a', 3.2, `${e.from}: "${e.intro}"`); break; + case 'missionPassed': banner('MISSION PASSED', '#68f4d1', 3.6, `${e.title} +$${e.reward.toLocaleString('en')}`); audio.fx('passed'); saveNow(); break; + case 'missionFailed': banner('MISSION FAILED', '#ff6b8a', 3, e.why); audio.fx('failed'); break; + case 'checkpoint': audio.fx('checkpoint'); break; + case 'tape': banner(`TAPE ${e.got} OF ${e.of}`, '#b79bff', 2.2, 'A lost mixtape. +$100'); audio.fx('tape'); saveNow(); break; + case 'nearMiss': world.save.stats.nearMisses++; break; + case 'sprayed': banner('FRESH PAINT', '#ff3fa4', 2.2, 'The cops have no idea who you are.'); break; + case 'openGarage': mode = 'garage'; garageIndex = Math.max(0, NG.GARAGE.indexOf(world.save.car)); break; + case 'garage': toast(`Your ${e.name} is waiting outside.`, 'good'); saveNow(); break; + } + } + } + + // ---------------------------------------------------------------- the loop + + let last = performance.now(), acc = 0, titleT = 0; + function frame(now) { + const dt = Math.min(0.1, (now - last) / 1000); last = now; + update(dt); + draw(dt); + pressed.clear(); + requestAnimationFrame(frame); + } + + function update(dt) { + if (hit('KeyM')) { soundSetting = !soundSetting; audio.setOn(soundSetting); toast(soundSetting ? 'Sound on' : 'Sound off'); vscode.postMessage({ type: 'sound', on: soundSetting }); } + if (mode === 'title') { + titleT += dt; + if (hit('Enter', 'Space', 'KeyE')) { mode = 'play'; if (soundSetting) audio.start(); } + return; + } + if (mode === 'pause') return updatePause(); + if (mode === 'garage') return updateGarage(); + if (mode === 'map') { if (hit('Tab', 'Escape', 'KeyP')) mode = 'play'; return; } + if (showHelp && hit('Enter', 'KeyF', 'KeyE', 'Escape')) { showHelp = false; pressed.clear(); } // closing the card does nothing else + if (hit('Escape', 'KeyP')) { mode = 'pause'; menuIndex = 0; return; } + if (hit('Tab')) { mode = 'map'; return; } + if (hit('KeyR')) toast(`📻 ${audio.nextStation()}`); + if (hit('KeyH') && world.player.car) audio.fx('horn'); + + acc += dt; + const input = { up: held('up'), down: held('down'), left: held('left'), right: held('right'), handbrake: held('handbrake'), sprint: held('sprint'), enter: hit('KeyE'), action: hit('Enter', 'KeyF') }; + while (acc >= 1 / 60) { + handle(NG.step(world, input, 1 / 60)); + input.enter = input.action = false; + acc -= 1 / 60; + } + effects(dt); + const car = world.player.car; + const speed = car ? Math.hypot(car.vx, car.vy) / NG.MODELS[car.model].max : null; + let siren = 0; + if (world.wanted.stars) for (const c of world.cars) if (c.kind === 'police') siren = Math.max(siren, 1 - Math.hypot(c.x - cam.x, c.y - cam.y) / 900); + audio.update(speed, held('up') ? 1 : 0, Math.max(0, siren), !!car); + if (dirty && performance.now() - lastSave > 4000) saveNow(); + else if (performance.now() - lastSave > 20000) saveNow(); + cashShown += (world.save.cash - cashShown) * Math.min(1, dt * 6); + if (Math.abs(world.save.cash - cashShown) < 1) cashShown = world.save.cash; + } + + const PAUSE = ['Resume', 'Garage (at Rico\'s)', 'Controls', 'Sound: on', 'Save game']; + function updatePause() { + if (hit('Escape', 'KeyP')) { mode = 'play'; return; } + if (hit('ArrowUp', 'KeyW')) menuIndex = (menuIndex + PAUSE.length - 1) % PAUSE.length; + if (hit('ArrowDown', 'KeyS')) menuIndex = (menuIndex + 1) % PAUSE.length; + if (hit('Enter', 'Space')) { + if (menuIndex === 0) mode = 'play'; + if (menuIndex === 1) { mode = 'play'; toast("Drive to Rico's Garage (the green marker) and press Enter to buy and change cars."); } + if (menuIndex === 2) { showHelp = true; mode = 'play'; } + if (menuIndex === 3) { soundSetting = !soundSetting; audio.setOn(soundSetting); vscode.postMessage({ type: 'sound', on: soundSetting }); } + if (menuIndex === 4) { saveNow(); toast('Saved.', 'good'); mode = 'play'; } + } + } + function updateGarage() { + if (hit('Escape', 'KeyP', 'Backspace')) { mode = 'play'; return; } + if (hit('ArrowLeft', 'KeyA')) garageIndex = (garageIndex + NG.GARAGE.length - 1) % NG.GARAGE.length; + if (hit('ArrowRight', 'KeyD')) garageIndex = (garageIndex + 1) % NG.GARAGE.length; + if (hit('Enter', 'Space')) { + const err = NG.garagePick(world, NG.GARAGE[garageIndex]); + handle(world.events.splice(0)); + if (err) toast(err, 'bad'); else mode = 'play'; + } + } + + // ---------------------------------------------------------------- effects + + function addSparks() { + const [x, y] = NG.playerPos(world); + for (let i = 0; i < 16; i++) { const a = Math.random() * 6.28, s = 60 + Math.random() * 220; sparks.push({ x, y, vx: Math.cos(a) * s, vy: Math.sin(a) * s, t: 0.4 + Math.random() * 0.3 }); } + } + function effects(dt) { + for (const c of world.cars) { + if (!c.drift && !(c.kind !== 'traffic' && Math.abs(c.f || 0) > 40 && held('handbrake') && c === world.player.car)) continue; + const m = NG.MODELS[c.model], ca = Math.cos(c.a), sa = Math.sin(c.a), back = m.len * 0.32, side = m.wid * 0.38; + for (const sd of [-1, 1]) { + const x = c.x - ca * back - sa * side * sd, y = c.y - sa * back + ca * side * sd; + const prev = c['skid' + sd]; + if (prev && Math.hypot(prev[0] - x, prev[1] - y) < 40) skid.push({ x1: prev[0], y1: prev[1], x2: x, y2: y, t: 14 }); + c['skid' + sd] = [x, y]; + } + } + for (const c of world.cars) if (!c.drift) { c['skid-1'] = null; c.skid1 = null; } + while (skid.length > 700) skid.shift(); + for (const s of skid) s.t -= dt; + while (skid.length && skid[0].t <= 0) skid.shift(); + for (const s of sparks) { s.x += s.vx * dt; s.y += s.vy * dt; s.vx *= 0.9; s.vy *= 0.9; s.t -= dt; } + for (let i = sparks.length - 1; i >= 0; i--) if (sparks[i].t <= 0) sparks.splice(i, 1); + for (const t of toasts) t.t -= dt; + while (toasts.length && toasts[0].t <= 0) toasts.shift(); + for (const b of banners) b.t -= dt; + if (banners.length && banners[0].t <= 0) banners.shift(); + for (const f of floaters) f.t -= dt; + while (floaters.length && floaters[0].t <= 0) floaters.shift(); + flash = Math.max(0, flash - dt * 1.6); + const [px, py] = NG.playerPos(world); + const d = world.city.districtAtPx(px, py); + if (d !== lastDistrict) { lastDistrict = d; districtTimer = 3; } else districtTimer -= dt; + } + + // ---------------------------------------------------------------- the city, drawn once into chunks + + const CHUNK = 16, chunks = new Map(); + const COL = { [TILE.WATER]: '#0a1736', [TILE.SAND]: '#4b3f3c', [TILE.ROAD]: '#1b1d29', [TILE.WALK]: '#2b2d3c', [TILE.BUILD]: '#11121b', [TILE.GRASS]: '#13301f', [TILE.TREE]: '#13301f', [TILE.LOT]: '#22242f', [TILE.PIER]: '#4a3326' }; + const isRoadLine = t => NG.ROADS.includes(t) || NG.ROADS.includes(t - 1); + + function chunkCanvas(cx, cy) { + const key = cx + ',' + cy; + let c = chunks.get(key); + if (c) { chunks.delete(key); chunks.set(key, c); return c; } + c = document.createElement('canvas'); c.width = c.height = CHUNK * T; + const g = c.getContext('2d'), city = world.city, x0 = cx * CHUNK, y0 = cy * CHUNK; + for (let ty = 0; ty < CHUNK; ty++) for (let tx = 0; tx < CHUNK; tx++) { + const X = x0 + tx, Y = y0 + ty, t = city.get(X, Y); + g.fillStyle = COL[t]; g.fillRect(tx * T, ty * T, T, T); + if (t === TILE.WATER) { g.fillStyle = '#0f2149'; if ((X + Y) % 3 === 0) g.fillRect(tx * T + 6, ty * T + 12, 14, 2); } + if (t === TILE.SAND && city.get(X, Y + 1) === TILE.WATER) { g.fillStyle = '#8fb7d955'; g.fillRect(tx * T, ty * T + T - 4, T, 4); } + if (t === TILE.SAND && city.get(X, Y - 1) === TILE.WATER) { g.fillStyle = '#8fb7d955'; g.fillRect(tx * T, ty * T, T, 4); } + if (t === TILE.WALK) { g.fillStyle = '#323546'; g.fillRect(tx * T, ty * T, T, 1); g.fillRect(tx * T, ty * T, 1, T); } + if (t === TILE.PIER) { g.fillStyle = '#5c4031'; for (let k = 0; k < 4; k++) g.fillRect(tx * T, ty * T + k * 8, T, 1); } + if (t === TILE.LOT) { g.fillStyle = '#3a3d4d'; if (X % 2 === 0 && (Y % 5 === 1 || Y % 5 === 2)) g.fillRect(tx * T, ty * T + 4, 1, 24); } + if (t === TILE.ROAD) { + const v = isRoadLine(X), h = isRoadLine(Y); + g.fillStyle = '#f7d15488'; + if (v && !h && NG.ROADS.includes(X - 1)) for (let k = 0; k < 2; k++) g.fillRect(tx * T - 1, ty * T + k * 16 + 2, 2, 9); + if (h && !v && NG.ROADS.includes(Y - 1)) for (let k = 0; k < 2; k++) g.fillRect(tx * T + k * 16 + 2, ty * T - 1, 9, 2); + g.fillStyle = '#e9e4dc22'; + if (v && !h) { if (NG.ROADS.includes(X)) g.fillRect(tx * T, ty * T, 2, T); else g.fillRect(tx * T + T - 2, ty * T, 2, T); } + if (h && !v) { if (NG.ROADS.includes(Y)) g.fillRect(tx * T, ty * T, T, 2); else g.fillRect(tx * T, ty * T + T - 2, T, 2); } + // zebra crossings next to intersections + g.fillStyle = '#e9e4dc30'; + if (v && !h && (isRoadLine(Y - 1) || isRoadLine(Y + 1))) for (let k = 0; k < 5; k++) g.fillRect(tx * T + 3 + k * 6, ty * T + 6, 3, 20); + if (h && !v && (isRoadLine(X - 1) || isRoadLine(X + 1))) for (let k = 0; k < 5; k++) g.fillRect(tx * T + 6, ty * T + 3 + k * 6, 20, 3); + } + } + // trees: palms in Palm Shore, round ones elsewhere + for (const [tx, ty] of city.trees) { + if (tx < x0 - 1 || tx > x0 + CHUNK || ty < y0 - 1 || ty > y0 + CHUNK) continue; + const x = (tx - x0 + 0.5) * T, y = (ty - y0 + 0.5) * T; + if (city.districtAtPx(tx * T, ty * T) === 'Palm Shore') { + g.strokeStyle = '#2f9e6b'; g.lineWidth = 4; g.lineCap = 'round'; + for (let k = 0; k < 6; k++) { const a = k * Math.PI / 3 + tx; g.beginPath(); g.moveTo(x, y); g.lineTo(x + Math.cos(a) * 15, y + Math.sin(a) * 15); g.stroke(); } + g.fillStyle = '#6b4a2e'; g.beginPath(); g.arc(x, y, 3, 0, 7); g.fill(); + } else { + g.fillStyle = '#0b2416'; g.beginPath(); g.arc(x + 3, y + 3, 14, 0, 7); g.fill(); + g.fillStyle = '#1f5a36'; g.beginPath(); g.arc(x, y, 14, 0, 7); g.fill(); + g.fillStyle = '#2d7a4a'; g.beginPath(); g.arc(x - 4, y - 4, 7, 0, 7); g.fill(); + } + } + // buildings: rooftops with neon edges + for (const b of city.buildings) { + if (b.x > x0 + CHUNK || b.x + b.w < x0 || b.y > y0 + CHUNK || b.y + b.h < y0) continue; + drawBuilding(g, b, (b.x - x0) * T, (b.y - y0) * T); + } + // street lamps at the corners of every intersection + g.globalCompositeOperation = 'lighter'; + for (const p of NG.ROADS) for (const q of NG.ROADS) for (const [ox, oy] of [[-0.35, -0.35], [2.35, 2.35]]) { + const x = (p + ox - x0) * T, y = (q + oy - y0) * T; + if (x < -80 || y < -80 || x > CHUNK * T + 80 || y > CHUNK * T + 80) continue; + const gr = g.createRadialGradient(x, y, 0, x, y, 70); + gr.addColorStop(0, 'rgba(255,214,150,0.22)'); gr.addColorStop(1, 'rgba(255,214,150,0)'); + g.fillStyle = gr; g.fillRect(x - 70, y - 70, 140, 140); + } + g.globalCompositeOperation = 'source-over'; + chunks.set(key, c); + if (chunks.size > 36) chunks.delete(chunks.keys().next().value); + return c; + } + + function seeded(seed) { let s = seed >>> 0; return () => ((s = (s * 1664525 + 1013904223) >>> 0) / 4294967296); } + function drawBuilding(g, b, x, y) { + const w = b.w * T, h = b.h * T, r = seeded(b.seed); + g.fillStyle = '#05060c'; g.fillRect(x + 5, y + 7, w, h); // shadow + g.fillStyle = b.roof; g.fillRect(x, y, w, h); + g.fillStyle = 'rgba(255,255,255,0.04)'; g.fillRect(x + 6, y + 6, w - 12, h - 12); + // rooftop details: vents, a water tank, and a helipad on tall towers + if (b.floors >= 10 && w >= 160 && h >= 120) { + g.strokeStyle = '#ffffff55'; g.lineWidth = 3; g.beginPath(); g.arc(x + w / 2, y + h / 2, 34, 0, 7); g.stroke(); + g.fillStyle = '#ffffff66'; g.font = 'bold 34px sans-serif'; g.textAlign = 'center'; g.textBaseline = 'middle'; g.fillText('H', x + w / 2, y + h / 2 + 1); + } else { + const n = 2 + Math.floor(r() * 4); + for (let k = 0; k < n; k++) { + const vw = 10 + r() * 22, vh = 10 + r() * 18, vx = x + 10 + r() * (w - vw - 20), vy = y + 10 + r() * (h - vh - 20); + g.fillStyle = 'rgba(0,0,0,0.35)'; g.fillRect(vx + 2, vy + 3, vw, vh); + g.fillStyle = 'rgba(255,255,255,0.12)'; g.fillRect(vx, vy, vw, vh); + } + if (r() < 0.4) { const cx = x + 18 + r() * (w - 36), cy = y + 18 + r() * (h - 36); g.fillStyle = 'rgba(0,0,0,.35)'; g.beginPath(); g.arc(cx + 2, cy + 3, 9, 0, 7); g.fill(); g.fillStyle = '#8a7b6a'; g.beginPath(); g.arc(cx, cy, 9, 0, 7); g.fill(); } + } + // neon outline: a wide soft line, then a bright thin one + const glow = b.floors >= 6 || b.special || r() < 0.55; + if (glow) { + g.strokeStyle = hexA(b.neon, 0.22); g.lineWidth = 7; g.strokeRect(x + 3, y + 3, w - 6, h - 6); + g.strokeStyle = hexA(b.neon, 0.95); g.lineWidth = 1.6; g.strokeRect(x + 3, y + 3, w - 6, h - 6); + } + if (b.label) { + g.font = `800 ${Math.min(28, w / (b.label.length * 0.62))}px "Segoe UI", sans-serif`; g.textAlign = 'center'; g.textBaseline = 'middle'; + g.fillStyle = hexA(b.neon, 0.35); g.fillText(b.label.toUpperCase(), x + w / 2 + 1, y + h / 2 + 2); + g.fillStyle = b.neon; g.fillText(b.label.toUpperCase(), x + w / 2, y + h / 2); + } + } + function hexA(hex, a) { const n = parseInt(hex.slice(1), 16); return `rgba(${n >> 16},${(n >> 8) & 255},${n & 255},${a})`; } + + // ---------------------------------------------------------------- cars and people + + const sprites = new Map(); + function carSprite(c) { + const key = c.model + c.color + (c.kind === 'police' || c.model === 'police'); + let s = sprites.get(key); + if (s) return s; + const m = NG.MODELS[c.model], L = m.len, Wd = m.wid, P = 4; + s = document.createElement('canvas'); s.width = (L + P * 2) * 2; s.height = (Wd + P * 2) * 2; + const g = s.getContext('2d'); g.scale(2, 2); g.translate(P + L / 2, P + Wd / 2); + const police = c.model === 'police'; + rr(g, -L / 2, -Wd / 2, L, Wd, 5); g.fillStyle = police ? '#141824' : c.color; g.fill(); + if (police) { g.fillStyle = '#e9edf5'; g.fillRect(-L * 0.16, -Wd / 2, L * 0.32, Wd); } + // shading, roof and glass + g.fillStyle = 'rgba(255,255,255,0.18)'; rr(g, -L / 2 + 2, -Wd / 2 + 1.5, L - 4, 3, 2); g.fill(); + g.fillStyle = 'rgba(0,0,0,0.25)'; rr(g, -L / 2 + 2, Wd / 2 - 4.5, L - 4, 3, 2); g.fill(); + g.fillStyle = '#0d1422'; rr(g, -L * 0.2, -Wd / 2 + 2.5, L * 0.46, Wd - 5, 3); g.fill(); + g.fillStyle = '#4f6a8f'; rr(g, L * 0.08, -Wd / 2 + 3, L * 0.16, Wd - 6, 2); g.fill(); + g.fillStyle = '#3b4f6e'; rr(g, -L * 0.24, -Wd / 2 + 3.5, L * 0.08, Wd - 7, 1.5); g.fill(); + if (c.model === 'taxi') { g.fillStyle = '#111'; g.fillRect(-2, -3, 6, 6); g.fillStyle = '#fff3a6'; g.fillRect(-1, -2, 4, 4); } + if (c.model === 'muscle' || c.model === 'super') { g.fillStyle = 'rgba(255,255,255,0.5)'; g.fillRect(-L / 2 + 1, -1.5, L - 2, 3); } + // lights + g.fillStyle = '#fff6d8'; g.fillRect(L / 2 - 2.5, -Wd / 2 + 2, 2, 4); g.fillRect(L / 2 - 2.5, Wd / 2 - 6, 2, 4); + g.fillStyle = '#ff2d55'; g.fillRect(-L / 2 + 0.5, -Wd / 2 + 2, 2, 4); g.fillRect(-L / 2 + 0.5, Wd / 2 - 6, 2, 4); + sprites.set(key, s); + return s; + } + function rr(g, x, y, w, h, r) { g.beginPath(); g.moveTo(x + r, y); g.arcTo(x + w, y, x + w, y + h, r); g.arcTo(x + w, y + h, x, y + h, r); g.arcTo(x, y + h, x, y, r); g.arcTo(x, y, x + w, y, r); g.closePath(); } + + const PED_COLOURS = ['#ff6b9a', '#4cdcf2', '#f7d154', '#9ad16f', '#b79bff', '#ff9f43']; + function drawPed(p, now) { + const step = Math.sin(now * 12 + p.id) * (p.dodge > 0 ? 0 : 2.2); + ctx.save(); ctx.translate(p.x, p.y); ctx.rotate(p.dodge > 0 ? p.da : p.a); + ctx.fillStyle = 'rgba(0,0,0,0.35)'; ctx.beginPath(); ctx.ellipse(2, 3, 7, 6, 0, 0, 7); ctx.fill(); + ctx.fillStyle = '#20222e'; ctx.fillRect(-2 + step, -5, 4, 3); ctx.fillRect(-2 - step, 2, 4, 3); + ctx.fillStyle = PED_COLOURS[p.look]; ctx.beginPath(); ctx.ellipse(0, 0, 4.5, 6.5, 0, 0, 7); ctx.fill(); + ctx.fillStyle = '#c79a74'; ctx.beginPath(); ctx.arc(1, 0, 3.4, 0, 7); ctx.fill(); + ctx.restore(); + if (p.shout > 0) { ctx.fillStyle = '#fff'; ctx.font = 'bold 14px "Segoe UI", sans-serif'; ctx.textAlign = 'center'; ctx.fillText('!', p.x, p.y - 14); } + } + function drawPlayerOnFoot(p, now) { + const moving = Math.hypot(p.vx, p.vy) > 1, step = moving ? Math.sin(now * 14) * 2.6 : 0; + ctx.save(); ctx.translate(p.x, p.y); ctx.rotate(p.a); + ctx.fillStyle = 'rgba(104,244,209,0.18)'; ctx.beginPath(); ctx.arc(0, 0, 16, 0, 7); ctx.fill(); + ctx.fillStyle = '#10131c'; ctx.fillRect(-2 + step, -6, 5, 3); ctx.fillRect(-2 - step, 3, 5, 3); + ctx.fillStyle = '#68f4d1'; ctx.beginPath(); ctx.ellipse(0, 0, 5, 7.5, 0, 0, 7); ctx.fill(); + ctx.fillStyle = '#2a1f1a'; ctx.beginPath(); ctx.arc(1, 0, 3.8, 0, 7); ctx.fill(); + ctx.restore(); + } + + // ---------------------------------------------------------------- drawing a frame + + function draw(dt) { + const now = performance.now() / 1000; + ctx.setTransform(DPR, 0, 0, DPR, 0, 0); + ctx.fillStyle = '#07081a'; ctx.fillRect(0, 0, W, H); + if (mode === 'title') return drawTitle(now); + + // camera: ahead of where you're going, and further out at speed + const [px, py] = NG.playerPos(world); + const car = world.player.car, sp = car ? Math.hypot(car.vx, car.vy) : 0; + const base = Math.max(0.55, Math.min(1.25, Math.min(W, H) / 760)); + const look = car ? 0.42 : 0; + cam.x += ((px + (car ? car.vx : 0) * look) - cam.x) * Math.min(1, dt * 4); + cam.y += ((py + (car ? car.vy : 0) * look) - cam.y) * Math.min(1, dt * 4); + cam.zoom += ((base * (1 - Math.min(0.28, sp / 2600))) - cam.zoom) * Math.min(1, dt * 2); + const z = cam.zoom, shake = flash * 10; + ctx.save(); + ctx.translate(W / 2 + (Math.random() - 0.5) * shake, H / 2 + (Math.random() - 0.5) * shake); + ctx.scale(z, z); ctx.translate(-cam.x, -cam.y); + const vw = W / z, vh = H / z, left = cam.x - vw / 2, top = cam.y - vh / 2; + + const S = CHUNK * T; + for (let cy = Math.floor(top / S); cy <= Math.floor((top + vh) / S); cy++) for (let cx = Math.floor(left / S); cx <= Math.floor((left + vw) / S); cx++) { + if (cx < 0 || cy < 0 || cx * CHUNK >= NG.W || cy * CHUNK >= NG.H) continue; + ctx.drawImage(chunkCanvas(cx, cy), cx * S, cy * S); + } + // the sea shimmers + ctx.globalCompositeOperation = 'lighter'; + ctx.strokeStyle = 'rgba(76,220,242,0.08)'; ctx.lineWidth = 2; + for (let y = Math.floor(top / 48) * 48; y < top + vh; y += 48) { + ctx.beginPath(); + for (let x = Math.floor(left / 24) * 24; x < left + vw; x += 24) { + const t = world.city.tileAtPx(x, y); + const yy = y + Math.sin(x * 0.02 + now * 1.4) * 4; + if (t === TILE.WATER) ctx.lineTo(x, yy); else ctx.moveTo(x, yy); + } + ctx.stroke(); + } + ctx.globalCompositeOperation = 'source-over'; + + // tyre marks + for (const s of skid) { ctx.strokeStyle = `rgba(0,0,0,${Math.min(0.5, s.t / 14 * 0.5)})`; ctx.lineWidth = 4; ctx.beginPath(); ctx.moveTo(s.x1, s.y1); ctx.lineTo(s.x2, s.y2); ctx.stroke(); } + + drawMarkers(now); + const inView = (x, y, m) => x > left - m && x < left + vw + m && y > top - m && y < top + vh + m; + for (const p of world.peds) if (inView(p.x, p.y, 30)) drawPed(p, now); + if (!world.player.car) drawPlayerOnFoot(world.player, now); + + // headlights (under the cars), then the cars + ctx.globalCompositeOperation = 'lighter'; + for (const c of world.cars) { + if (!inView(c.x, c.y, 160) || c.kind === 'parked' || Math.hypot(c.vx, c.vy) < 20) continue; + const m = NG.MODELS[c.model], ca = Math.cos(c.a), sa = Math.sin(c.a); + const hx = c.x + ca * m.len * 0.5, hy = c.y + sa * m.len * 0.5; + const gr = ctx.createRadialGradient(hx, hy, 2, hx, hy, 105); + gr.addColorStop(0, 'rgba(255,236,190,0.16)'); gr.addColorStop(0.6, 'rgba(255,236,190,0.05)'); gr.addColorStop(1, 'rgba(255,236,190,0)'); + ctx.fillStyle = gr; ctx.beginPath(); ctx.moveTo(hx, hy); + ctx.arc(hx, hy, 105, c.a - 0.36, c.a + 0.36); ctx.closePath(); ctx.fill(); + } + ctx.globalCompositeOperation = 'source-over'; + for (const c of world.cars) { + if (!inView(c.x, c.y, 60)) continue; + const s = carSprite(c); + ctx.save(); ctx.translate(c.x, c.y); ctx.rotate(c.a); + ctx.fillStyle = 'rgba(0,0,0,0.4)'; ctx.fillRect(-s.width / 4 + 3, -s.height / 4 + 4, s.width / 2 - 2, s.height / 2 - 2); + ctx.drawImage(s, -s.width / 4, -s.height / 4, s.width / 2, s.height / 2); + if (c.kind === 'police' || c.model === 'police') { + const on = Math.floor(now * 8 + c.id) % 2 === 0, lit = c.kind === 'police'; + ctx.fillStyle = lit && on ? '#ff2d55' : '#5a1020'; ctx.fillRect(-3, -7, 5, 6); + ctx.fillStyle = lit && !on ? '#2d7bff' : '#10204a'; ctx.fillRect(-3, 1, 5, 6); + if (lit) { + ctx.globalCompositeOperation = 'lighter'; + const gr = ctx.createRadialGradient(0, 0, 0, 0, 0, 70); + gr.addColorStop(0, on ? 'rgba(255,45,85,0.35)' : 'rgba(45,123,255,0.35)'); gr.addColorStop(1, 'rgba(0,0,0,0)'); + ctx.fillStyle = gr; ctx.fillRect(-70, -70, 140, 140); + ctx.globalCompositeOperation = 'source-over'; + } + } + if (c === world.player.car) { ctx.strokeStyle = 'rgba(104,244,209,0.55)'; ctx.lineWidth = 1.5; ctx.strokeRect(-NG.MODELS[c.model].len / 2 - 3, -NG.MODELS[c.model].wid / 2 - 3, NG.MODELS[c.model].len + 6, NG.MODELS[c.model].wid + 6); } + if (c.target && c !== world.player.car) { ctx.strokeStyle = '#b79bff'; ctx.lineWidth = 2; ctx.beginPath(); ctx.arc(0, 0, 30 + Math.sin(now * 5) * 4, 0, 7); ctx.stroke(); } + if (c.kind === 'traffic' && c.honk > 1.2 && Math.floor(now * 2) % 2) { ctx.rotate(-c.a); ctx.fillStyle = '#fff'; ctx.font = 'bold 11px "Segoe UI", sans-serif'; ctx.textAlign = 'center'; ctx.fillText('HONK', 0, -18); } + ctx.restore(); + } + for (const s of sparks) { ctx.fillStyle = `rgba(255,${180 + Math.random() * 60},90,${s.t * 2})`; ctx.fillRect(s.x, s.y, 3, 3); } + ctx.restore(); + + // night: a vignette, and red/blue when the cops are close + const vg = ctx.createRadialGradient(W / 2, H / 2, Math.min(W, H) * 0.3, W / 2, H / 2, Math.max(W, H) * 0.75); + vg.addColorStop(0, 'rgba(7,8,26,0)'); vg.addColorStop(1, 'rgba(7,8,26,0.65)'); + ctx.fillStyle = vg; ctx.fillRect(0, 0, W, H); + if (world.wanted.stars) { ctx.fillStyle = Math.floor(now * 3) % 2 ? 'rgba(255,45,85,0.05)' : 'rgba(45,123,255,0.05)'; ctx.fillRect(0, 0, W, H); } + if (flash > 0) { ctx.fillStyle = `rgba(255,255,255,${flash * 0.35})`; ctx.fillRect(0, 0, W, H); } + + if (mode !== 'garage' && mode !== 'map') drawHud(now); + if (mode === 'pause') drawPause(); + if (mode === 'garage') drawGarage(now); + if (mode === 'map') drawMap(now); + } + + function drawMarkers(now) { + const pulse = 1 + Math.sin(now * 4) * 0.08; + const ring = (x, y, colour, label, r) => { + ctx.save(); ctx.globalCompositeOperation = 'lighter'; + const gr = ctx.createRadialGradient(x, y, 0, x, y, (r || 34) * pulse * 1.6); + gr.addColorStop(0, hexA(colour, 0.35)); gr.addColorStop(1, hexA(colour, 0)); + ctx.fillStyle = gr; ctx.beginPath(); ctx.arc(x, y, (r || 34) * pulse * 1.6, 0, 7); ctx.fill(); + ctx.restore(); + ctx.strokeStyle = colour; ctx.lineWidth = 3; ctx.beginPath(); ctx.arc(x, y, (r || 34) * pulse, 0, 7); ctx.stroke(); + if (label) { ctx.fillStyle = colour; ctx.font = '800 13px "Segoe UI", sans-serif'; ctx.textAlign = 'center'; ctx.fillText(label, x, y - (r || 34) - 10); } + }; + const poi = world.city.poi; + const next = NG.MISSIONS[world.save.story]; + if (!world.mission && next) ring(poi[next.start].x, poi[next.start].y, '#fdf05a', `★ ${next.title}`, 30); + ring(poi.garage.x, poi.garage.y, '#68f4d1', '', 24); + if (world.wanted.stars) ring(poi.spray.x, poi.spray.y, '#ff3fa4', 'Spray $250', 26); + if (!world.mission && !world.job && world.player.car) for (const t of poi.taxi) ring(t.x, t.y, '#ffd33d', 'Fares', 20); + const o = NG.objective(world); + if (o) ring(o.x, o.y, o.colour, o.label, 36); + // tapes spin + for (const t of world.city.tapes) { + if (world.save.tapes.includes(t.id)) continue; + ctx.save(); ctx.translate(t.x, t.y); ctx.scale(Math.cos(now * 3 + t.id), 1); + ctx.fillStyle = '#b79bff'; rr(ctx, -10, -7, 20, 14, 2); ctx.fill(); + ctx.fillStyle = '#1b1533'; ctx.beginPath(); ctx.arc(-4, 0, 2.6, 0, 7); ctx.arc(4, 0, 2.6, 0, 7); ctx.fill(); + ctx.restore(); + } + } + + // ---------------------------------------------------------------- HUD + + function panel(x, y, w, h) { ctx.fillStyle = 'rgba(10,11,24,0.78)'; rr(ctx, x, y, w, h, 10); ctx.fill(); ctx.strokeStyle = 'rgba(255,255,255,0.08)'; ctx.lineWidth = 1; ctx.stroke(); } + function text(t, x, y, size, colour, align, weight) { ctx.font = `${weight || 700} ${size}px "Segoe UI", Inter, sans-serif`; ctx.textAlign = align || 'left'; ctx.textBaseline = 'alphabetic'; ctx.fillStyle = colour; ctx.fillText(t, x, y); } + function star(x, y, r, filled, colour) { + ctx.beginPath(); + for (let k = 0; k < 10; k++) { const a = -Math.PI / 2 + k * Math.PI / 5, rr2 = k % 2 ? r * 0.45 : r; ctx.lineTo(x + Math.cos(a) * rr2, y + Math.sin(a) * rr2); } + ctx.closePath(); + if (filled) { ctx.fillStyle = colour; ctx.fill(); } else { ctx.strokeStyle = 'rgba(255,255,255,0.28)'; ctx.lineWidth = 1.5; ctx.stroke(); } + } + + function drawHud(now) { + const pad = 16, s = world.save; + // cash and stars, top right under the minimap + const mm = Math.min(190, Math.max(130, W * 0.16)); + drawMinimap(W - mm - pad, pad, mm, now); + text(`$${Math.round(cashShown).toLocaleString('en')}`, W - pad, mm + pad + 34, 28, '#68f4d1', 'right', 800); + const unseen = world.wanted.stars && !world.wanted.seen; + for (let k = 0; k < 5; k++) star(W - pad - 12 - (4 - k) * 26, mm + pad + 58, 10, k < world.wanted.stars, unseen && Math.floor(now * 4) % 2 ? 'rgba(253,240,90,0.35)' : '#fdf05a'); + floaters.forEach((f, i) => text(f.text, W - pad, mm + pad + 92 + i * 22 - (1.4 - f.t) * 14, 18, f.colour, 'right', 800)); + + // the district you just drove into + if (districtTimer > 0) { ctx.globalAlpha = Math.min(1, districtTimer); text(lastDistrict.toUpperCase(), pad, H - 96, 22, '#ffffff', 'left', 800); text('SOLARA BAY', pad, H - 76, 12, '#9aa7b4', 'left', 600); ctx.globalAlpha = 1; } + // speed, car and radio, bottom left + const car = world.player.car; + if (car) { + const kmh = Math.round(Math.hypot(car.vx, car.vy) / T * 3 * 3.6); + panel(pad, H - 64, 230, 50); + text(String(kmh), pad + 16, H - 28, 26, '#ffffff', 'left', 800); + text('km/h', pad + 16 + ctx.measureText(String(kmh)).width + 6, H - 28, 12, '#9aa7b4', 'left', 600); + text(NG.MODELS[car.model].name, pad + 214, H - 40, 13, '#ffffff', 'right', 700); + text(`📻 ${audio.stationName()}`, pad + 214, H - 22, 11, '#9aa7b4', 'right', 600); + } + // mission box, top left + let y = pad; + if (world.mission || world.job) { + const st = world.mission ? NG.MISSIONS[world.mission.idx].steps[world.mission.step] : null; + const title = world.mission ? NG.MISSIONS[world.mission.idx].title : 'Fare'; + const textLine = st ? st.text : `Drop-off: ${Math.max(0, Math.ceil(world.job.timer))}s · $${world.job.pay}`; + const timer = world.mission && world.mission.timer != null ? Math.max(0, Math.ceil(world.mission.timer)) : null; + const lines = wrap(textLine, 320, 14); + const h = 44 + lines.length * 18; + panel(pad, y, 350, h); + text(title.toUpperCase(), pad + 14, y + 24, 12, '#fdf05a', 'left', 800); + if (timer != null) text(`${Math.floor(timer / 60)}:${String(timer % 60).padStart(2, '0')}`, pad + 336, y + 24, 16, timer < 10 ? '#ff6b8a' : '#ffffff', 'right', 800); + if (world.race) text(`CHECKPOINT ${Math.min(world.race.cp + 1, world.race.checkpoints.length)}/${world.race.checkpoints.length}`, pad + 336, y + 24, 12, '#ffffff', 'right', 800); + lines.forEach((l, i) => text(l, pad + 14, y + 46 + i * 18, 14, '#e8edf2', 'left', 500)); + y += h + 10; + } + toasts.forEach(t => { + ctx.globalAlpha = Math.min(1, t.t * 2); + const lines = wrap(t.text, 320, 13), h = 18 + lines.length * 17; + panel(pad, y, 350, h); + lines.forEach((l, i) => text(l, pad + 14, y + 22 + i * 17, 13, t.kind === 'bad' ? '#ff9db0' : t.kind === 'good' ? '#9ff5dc' : t.kind === 'mission' ? '#fff3a6' : '#e8edf2', 'left', 500)); + y += h + 8; ctx.globalAlpha = 1; + }); + // what you can do here + const hint = prompt(); + if (hint) { ctx.font = '700 14px "Segoe UI", sans-serif'; const w = ctx.measureText(hint).width + 36; panel(W / 2 - w / 2, H - 70, w, 38); text(hint, W / 2, H - 45, 14, '#ffffff', 'center', 700); } + // banners + const b = banners[0]; + if (b) { + const a = Math.min(1, b.t * 2, (b.life - b.t) * 4); + ctx.globalAlpha = a; + ctx.fillStyle = 'rgba(7,8,26,0.55)'; ctx.fillRect(0, H * 0.32, W, b.sub ? 110 : 80); + ctx.save(); ctx.shadowColor = b.colour; ctx.shadowBlur = 24; + text(b.text, W / 2, H * 0.32 + 52, Math.min(46, W / 16), b.colour, 'center', 900); + ctx.restore(); + if (b.sub) wrap(b.sub, Math.min(760, W - 60), 15).slice(0, 2).forEach((l, i) => text(l, W / 2, H * 0.32 + 80 + i * 19, 15, '#e8edf2', 'center', 500)); + ctx.globalAlpha = 1; + } + if (showHelp) drawHelp(); + } + + function prompt() { + const p = world.player, [x, y] = NG.playerPos(world), poi = world.city.poi; + const next = NG.MISSIONS[world.save.story]; + if (!world.mission && next && Math.hypot(x - poi[next.start].x, y - poi[next.start].y) < 80) return `Enter Start "${next.title}"`; + if (!world.mission && Math.hypot(x - poi.garage.x, y - poi.garage.y) < 80) return "Enter Rico's Garage: buy and change cars"; + if (p.car && world.wanted.stars && Math.hypot(x - poi.spray.x, y - poi.spray.y) < 80) return 'Enter Fresh paint: lose the cops ($250)'; + if (p.car && !world.mission && !world.job && poi.taxi.some(t => Math.hypot(x - t.x, y - t.y) < 80)) return 'Enter Take a fare'; + if (!p.car && world.cars.some(c => Math.hypot(c.x - p.x, c.y - p.y) < 50)) return 'E Get in'; + return ''; + } + + function wrap(t, width, size) { + ctx.font = `500 ${size}px "Segoe UI", sans-serif`; + const out = []; let line = ''; + for (const word of String(t).split(' ')) { const test = line ? line + ' ' + word : word; if (ctx.measureText(test).width > width && line) { out.push(line); line = word; } else line = test; } + if (line) out.push(line); + return out; + } + + // minimap: the whole city drawn once at 2px a tile, then the area around you + let mapImage = null; + function cityMap() { + if (mapImage) return mapImage; + const c = document.createElement('canvas'); c.width = NG.W * 2; c.height = NG.H * 2; + const g = c.getContext('2d'); + const MC = { [TILE.WATER]: '#0b1a3d', [TILE.SAND]: '#3d3436', [TILE.ROAD]: '#7d7f98', [TILE.WALK]: '#23253a', [TILE.BUILD]: '#2a2148', [TILE.GRASS]: '#16402a', [TILE.TREE]: '#16402a', [TILE.LOT]: '#2c2f45', [TILE.PIER]: '#6b4a2e' }; + for (let y = 0; y < NG.H; y++) for (let x = 0; x < NG.W; x++) { g.fillStyle = MC[world.city.get(x, y)]; g.fillRect(x * 2, y * 2, 2, 2); } + return (mapImage = c); + } + function mapDots(g, sx, sy, scale, now) { + const dot = (x, y, r, colour) => { g.fillStyle = colour; g.beginPath(); g.arc(sx(x), sy(y), r, 0, 7); g.fill(); }; + const poi = world.city.poi; + dot(poi.garage.x, poi.garage.y, 4, '#68f4d1'); + if (world.wanted.stars) dot(poi.spray.x, poi.spray.y, 4, '#ff3fa4'); + const next = NG.MISSIONS[world.save.story]; + if (!world.mission && next) dot(poi[next.start].x, poi[next.start].y, 5, '#fdf05a'); + const o = NG.objective(world); if (o) dot(o.x, o.y, 5 + Math.sin(now * 6), o.colour); + for (const c of world.cars) if (c.kind === 'police') dot(c.x, c.y, 3, Math.floor(now * 6) % 2 ? '#ff2d55' : '#2d7bff'); + for (const c of world.cars) if (c.kind === 'rival') dot(c.x, c.y, 3, '#ff9f43'); + const [px, py] = NG.playerPos(world), a = world.player.car ? world.player.car.a : world.player.a; + g.save(); g.translate(sx(px), sy(py)); g.rotate(a); + g.fillStyle = '#ffffff'; g.beginPath(); g.moveTo(7, 0); g.lineTo(-5, -5); g.lineTo(-2, 0); g.lineTo(-5, 5); g.closePath(); g.fill(); + g.restore(); + void scale; + } + function drawMinimap(x, y, size, now) { + const img = cityMap(), [px, py] = NG.playerPos(world); + const scale = 2 / T * 1.4; // minimap px per world px + ctx.save(); + rr(ctx, x, y, size, size, 14); ctx.fillStyle = '#07081a'; ctx.fill(); ctx.clip(); + const sx = wx => x + size / 2 + (wx - px) * scale, sy = wy => y + size / 2 + (wy - py) * scale; + ctx.imageSmoothingEnabled = false; + ctx.drawImage(img, sx(0), sy(0), img.width * 1.4, img.height * 1.4); + mapDots(ctx, sx, sy, scale, now); + ctx.restore(); + ctx.strokeStyle = world.wanted.stars ? (Math.floor(now * 3) % 2 ? '#ff2d55' : '#2d7bff') : 'rgba(104,244,209,0.6)'; ctx.lineWidth = 2; + rr(ctx, x, y, size, size, 14); ctx.stroke(); + } + function drawMap(now) { + ctx.fillStyle = 'rgba(5,6,16,0.9)'; ctx.fillRect(0, 0, W, H); + const size = Math.min(W, H - 110), x = (W - size) / 2, y = 76, img = cityMap(), scale = size / (NG.W * T); + ctx.imageSmoothingEnabled = false; ctx.drawImage(img, x, y, size, size); + const half = size / 2; + NG.DISTRICTS.forEach((d, i) => { ctx.globalAlpha = 0.55; text(d.name.toUpperCase(), x + half * (i % 2) + half / 2, y + half * Math.floor(i / 2) + half / 2, Math.max(12, size / 34), d.neon[0], 'center', 900); ctx.globalAlpha = 1; }); + const poi = world.city.poi; + for (const k of ['garage', 'police', 'spray', 'bank', 'raceStart', 'pier']) { const q = poi[k]; text(q.label, x + q.x * scale, y + q.y * scale - 9, 11, '#ffffff', 'center', 700); } + mapDots(ctx, wx => x + wx * scale, wy => y + wy * scale, scale, now); + text('SOLARA BAY', W / 2, 40, 22, '#ffffff', 'center', 900); + const legend = [['#68f4d1', "Rico's Garage"], ['#fdf05a', 'Next mission'], ['#ff3fa4', 'Spray shop'], ['#ff2d55', 'Police']]; + const lx = W / 2 - legend.length * 65; + legend.forEach(([c, l], i) => { ctx.fillStyle = c; ctx.beginPath(); ctx.arc(lx + 8 + i * 130, H - 14, 5, 0, 7); ctx.fill(); text(l, lx + 20 + i * 130, H - 9, 13, '#c9d4de', 'left', 600); }); + text(`Tapes ${world.save.tapes.length}/20 · Missions ${world.save.story}/${NG.MISSIONS.length} · Tab to close`, W / 2, 62, 13, '#9aa7b4', 'center', 600); + } + + function drawHelp() { + const w = Math.min(560, W - 40), h = 300, x = (W - w) / 2, y = (H - h) / 2; + panel(x, y, w, h); + text('HOW TO PLAY', x + 24, y + 38, 14, '#68f4d1', 'left', 800); + const rows = [['W A S D / arrows', 'Drive or walk'], ['Space', 'Handbrake: drift!'], ['E', 'Get in or out of a car'], ['Enter / F', 'Start missions, garage, spray shop, fares'], ['Shift', 'Run'], ['Tab', 'City map'], ['R · M · H', 'Radio station · sound on/off · horn'], ['Esc / P', 'Pause']]; + rows.forEach(([k, v], i) => { text(k, x + 24, y + 72 + i * 25, 14, '#ffffff', 'left', 800); text(v, x + 210, y + 72 + i * 25, 14, '#c9d4de', 'left', 500); }); + text('Press Enter to start. The yellow marker is your first job.', x + w / 2, y + h - 18, 13, '#fdf05a', 'center', 700); + } + + function drawPause() { + ctx.fillStyle = 'rgba(5,6,16,0.75)'; ctx.fillRect(0, 0, W, H); + text('PAUSED', W / 2, H / 2 - 120, 40, '#ffffff', 'center', 900); + PAUSE.forEach((item, i) => { + const label = i === 3 ? `Sound: ${soundSetting ? 'on' : 'off'}` : item; + text((i === menuIndex ? '▶ ' : '') + label, W / 2, H / 2 - 50 + i * 40, 20, i === menuIndex ? '#68f4d1' : '#c9d4de', 'center', 700); + }); + const s = world.save.stats; + text(`Missions ${world.save.story}/${NG.MISSIONS.length} · Tapes ${world.save.tapes.length}/20 · Escapes ${s.escapes} · Busted ${s.busted} · Top speed ${s.topSpeed} km/h · Earned by coding $${s.paychecks.toLocaleString('en')}`, W / 2, H - 40, 13, '#9aa7b4', 'center', 600); + } + + function drawGarage(now) { + ctx.fillStyle = 'rgba(5,6,16,0.88)'; ctx.fillRect(0, 0, W, H); + const model = NG.GARAGE[garageIndex], m = NG.MODELS[model], owned = world.save.owned.includes(model); + text("RICO'S GARAGE", W / 2, 70, 30, '#68f4d1', 'center', 900); + text('← → choose Enter ' + (owned ? 'drive it' : `buy for $${m.price.toLocaleString('en')}`) + ' Esc leave', W / 2, 98, 14, '#9aa7b4', 'center', 600); + // the car, big and slowly turning + const s = carSprite({ model, color: m.colors[0], kind: 'parked' }); + ctx.save(); ctx.translate(W / 2, H / 2 - 20); ctx.rotate(Math.sin(now * 0.8) * 0.3 - 0.2); ctx.scale(3.2, 3.2); + ctx.drawImage(s, -s.width / 4, -s.height / 4, s.width / 2, s.height / 2); ctx.restore(); + text(m.name, W / 2, H / 2 + 80, 28, '#ffffff', 'center', 900); + text(owned ? (world.save.car === model ? 'Yours · parked outside' : 'Yours') : `$${m.price.toLocaleString('en')}`, W / 2, H / 2 + 106, 16, owned ? '#68f4d1' : world.save.cash >= m.price ? '#fdf05a' : '#ff6b8a', 'center', 700); + const bars = [['Top speed', m.max / 725], ['Acceleration', m.accel / 570], ['Handling', (m.turn - 2.3) / 1.1 * 0.5 + m.grip * 0.5]]; + bars.forEach(([l, v], i) => { + const bx = W / 2 - 150, by = H / 2 + 136 + i * 28; + text(l, bx, by + 10, 13, '#c9d4de', 'left', 600); + ctx.fillStyle = 'rgba(255,255,255,0.1)'; ctx.fillRect(bx + 110, by, 190, 10); + ctx.fillStyle = '#68f4d1'; ctx.fillRect(bx + 110, by, 190 * Math.min(1, v), 10); + }); + NG.GARAGE.forEach((g, i) => { ctx.fillStyle = i === garageIndex ? '#68f4d1' : 'rgba(255,255,255,0.25)'; ctx.beginPath(); ctx.arc(W / 2 - 36 + i * 24, H - 40, 5, 0, 7); ctx.fill(); }); + text(`$${Math.round(cashShown).toLocaleString('en')}`, W - 24, 40, 22, '#68f4d1', 'right', 800); + } + + // ---------------------------------------------------------------- title screen + + function drawTitle(now) { + // a slow flight over the city at night + const t = now * 0.04; + const cx = (NG.W * T) / 2 + Math.cos(t) * 1300, cy = (NG.H * T) / 2 + Math.sin(t * 0.8) * 1100; + const z = Math.max(0.55, Math.min(1.1, Math.min(W, H) / 900)); + ctx.save(); ctx.translate(W / 2, H / 2); ctx.scale(z, z); ctx.translate(-cx, -cy); + const vw = W / z, vh = H / z, S = CHUNK * T; + for (let y = Math.floor((cy - vh / 2) / S); y <= Math.floor((cy + vh / 2) / S); y++) for (let x = Math.floor((cx - vw / 2) / S); x <= Math.floor((cx + vw / 2) / S); x++) { + if (x < 0 || y < 0 || x * CHUNK >= NG.W || y * CHUNK >= NG.H) continue; + ctx.drawImage(chunkCanvas(x, y), x * S, y * S); + } + for (const c of world.cars) { const s = carSprite(c); ctx.save(); ctx.translate(c.x, c.y); ctx.rotate(c.a); ctx.drawImage(s, -s.width / 4, -s.height / 4, s.width / 2, s.height / 2); ctx.restore(); } + ctx.restore(); + NG.step(world, {}, 1 / 60); // the city keeps moving behind the menu + const g = ctx.createLinearGradient(0, 0, 0, H); + g.addColorStop(0, 'rgba(7,8,26,0.85)'); g.addColorStop(0.5, 'rgba(7,8,26,0.35)'); g.addColorStop(1, 'rgba(7,8,26,0.9)'); + ctx.fillStyle = g; ctx.fillRect(0, 0, W, H); + // the logo + const size = Math.min(96, W / 8); + ctx.save(); ctx.translate(W / 2, H * 0.4); ctx.transform(1, 0, -0.18, 1, 0, 0); + ctx.font = `900 ${size}px "Segoe UI", Inter, sans-serif`; ctx.textAlign = 'center'; + const lg = ctx.createLinearGradient(-size * 3, 0, size * 3, 0); + lg.addColorStop(0, '#ff3fa4'); lg.addColorStop(0.5, '#ff8a5c'); lg.addColorStop(1, '#fdf05a'); + ctx.shadowColor = '#ff3fa4'; ctx.shadowBlur = 30; ctx.fillStyle = lg; ctx.fillText('NEON', 0, 0); + ctx.shadowColor = '#4cdcf2'; ctx.fillStyle = '#4cdcf2'; ctx.fillText('GETAWAY', 0, size * 0.95); + ctx.restore(); + text('SOLARA BAY · OPEN WORLD', W / 2, H * 0.4 + size * 1.55, 14, '#c9d4de', 'center', 700); + if (Math.floor(now * 2) % 2 === 0) text('Press Enter to play', W / 2, H * 0.78, 20, '#ffffff', 'center', 800); + text('W A S D drive · Space drift · E steal a car · Tab map · M sound', W / 2, H * 0.78 + 30, 13, '#9aa7b4', 'center', 600); + if (world.save.cash) text(`$${world.save.cash.toLocaleString('en')} · missions ${world.save.story}/${NG.MISSIONS.length}`, W / 2, H - 24, 13, '#68f4d1', 'center', 700); + } + + vscode.postMessage({ type: 'ready' }); + window.__neonGetaway = { get world() { return world; }, get mode() { return mode; }, set mode(v) { mode = v; }, cam, banner, toast, clear() { banners.length = 0; toasts.length = 0; floaters.length = 0; } }; + requestAnimationFrame(frame); +})(); diff --git a/extensions/neon-getaway/media/icon.png b/extensions/neon-getaway/media/icon.png new file mode 100644 index 0000000..ab2b525 Binary files /dev/null and b/extensions/neon-getaway/media/icon.png differ diff --git a/extensions/neon-getaway/media/readme/chase.png b/extensions/neon-getaway/media/readme/chase.png new file mode 100644 index 0000000..83e6a4d Binary files /dev/null and b/extensions/neon-getaway/media/readme/chase.png differ diff --git a/extensions/neon-getaway/media/readme/drift.png b/extensions/neon-getaway/media/readme/drift.png new file mode 100644 index 0000000..71fa21b Binary files /dev/null and b/extensions/neon-getaway/media/readme/drift.png differ diff --git a/extensions/neon-getaway/media/readme/garage.png b/extensions/neon-getaway/media/readme/garage.png new file mode 100644 index 0000000..1b23cd7 Binary files /dev/null and b/extensions/neon-getaway/media/readme/garage.png differ diff --git a/extensions/neon-getaway/media/readme/map.png b/extensions/neon-getaway/media/readme/map.png new file mode 100644 index 0000000..9f76153 Binary files /dev/null and b/extensions/neon-getaway/media/readme/map.png differ diff --git a/extensions/neon-getaway/media/readme/passed.png b/extensions/neon-getaway/media/readme/passed.png new file mode 100644 index 0000000..974070d Binary files /dev/null and b/extensions/neon-getaway/media/readme/passed.png differ diff --git a/extensions/neon-getaway/media/readme/title.png b/extensions/neon-getaway/media/readme/title.png new file mode 100644 index 0000000..5a470cf Binary files /dev/null and b/extensions/neon-getaway/media/readme/title.png differ diff --git a/extensions/neon-getaway/package-lock.json b/extensions/neon-getaway/package-lock.json new file mode 100644 index 0000000..55499f2 --- /dev/null +++ b/extensions/neon-getaway/package-lock.json @@ -0,0 +1,4783 @@ +{ + "name": "neon-getaway", + "version": "1.0.0", + "lockfileVersion": 3, + "requires": true, + "packages": { + "": { + "name": "neon-getaway", + "version": "1.0.0", + "license": "MIT", + "devDependencies": { + "@types/node": "^22.0.0", + "@types/vscode": "~1.85.0", + "@vscode/test-electron": "^2.5.2", + "@vscode/vsce": "^3.6.0", + "esbuild": "^0.25.0", + "typescript": "^5.9.0" + }, + "engines": { + "vscode": "^1.85.0" + } + }, + "node_modules/@azu/format-text": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/@azu/format-text/-/format-text-1.0.2.tgz", + "integrity": "sha512-Swi4N7Edy1Eqq82GxgEECXSSLyn6GOb5htRFPzBDdUkECGXtlf12ynO5oJSpWKPwCaUssOu7NfhDcCWpIC6Ywg==", + "dev": true, + "license": "BSD-3-Clause" + }, + "node_modules/@azu/style-format": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/@azu/style-format/-/style-format-1.0.1.tgz", + "integrity": "sha512-AHcTojlNBdD/3/KxIKlg8sxIWHfOtQszLvOpagLTO+bjC3u7SAszu1lf//u7JJC50aUSH+BVWDD/KvaA6Gfn5g==", + "dev": true, + "license": "WTFPL", + "dependencies": { + "@azu/format-text": "^1.0.1" + } + }, + "node_modules/@azure/abort-controller": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/@azure/abort-controller/-/abort-controller-2.2.0.tgz", + "integrity": "sha512-fNAjWnA/nZ2jz31kxR/AqRaUT8ewHBw/WuBIosK0moMy1C9e5ValbDfFdIxJzVOOYaYkV/b2F1S4H/aHiqfVQg==", + "dev": true, + "license": "MIT", + "dependencies": { + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/@azure/core-auth": { + "version": "1.11.0", + "resolved": "https://registry.npmjs.org/@azure/core-auth/-/core-auth-1.11.0.tgz", + "integrity": "sha512-IUZydyTUkDnYdstOW9pFOOUQlBjAepK5teihDE3x6yxsPJs/hsAaaYpeGxdxrgtOiJbBKSjKW7MDk7AEhb4LRg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@azure/abort-controller": "^2.1.2", + "@azure/core-util": "^1.13.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/@azure/core-client": { + "version": "1.11.2", + "resolved": "https://registry.npmjs.org/@azure/core-client/-/core-client-1.11.2.tgz", + "integrity": "sha512-ajuIU1aMoTs/ERYrKnIqQrV5Vz3RL8mwDC5RdedIXUvR7pi6cWzeYmt0LfNz6+W91CuCO4WJG0zA6+PhU1X+hw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@azure/abort-controller": "^2.1.2", + "@azure/core-auth": "^1.10.0", + "@azure/core-rest-pipeline": "^1.22.0", + "@azure/core-tracing": "^1.3.0", + "@azure/core-util": "^1.13.0", + "@azure/logger": "^1.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/@azure/core-process": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/@azure/core-process/-/core-process-1.0.0.tgz", + "integrity": "sha512-/shnJ+ooO8WPxDhPEeI/2oRQuubn16gZ6CvlbpWbEswZfzwI9tI/sMAHmF3x1LuQ9yZYXfLW3TjzGMLEC5blKg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/@azure/core-rest-pipeline": { + "version": "1.25.1", + "resolved": "https://registry.npmjs.org/@azure/core-rest-pipeline/-/core-rest-pipeline-1.25.1.tgz", + "integrity": "sha512-fTIA3CAm/cdODqiXkO6jYOIkU2Ylld7vq65KGc70gTwl12sLQsC8v7I5t6tp2N2CfUONzZBXyeFw7KEu6Ks2zg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@azure/abort-controller": "^2.1.2", + "@azure/core-auth": "^1.10.0", + "@azure/core-tracing": "^1.3.0", + "@azure/core-util": "^1.13.0", + "@azure/logger": "^1.3.0", + "@typespec/ts-http-runtime": "^0.3.10", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/@azure/core-tracing": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/@azure/core-tracing/-/core-tracing-1.4.0.tgz", + "integrity": "sha512-eGwxD0AtncrxeBM4tG8R55Pc3rdX1hNW2WibJAgYpCVA6E93mvvVH+LcssoVjOBrSKWS55yEIHsk0X8ctHmfOQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/@azure/core-util": { + "version": "1.14.0", + "resolved": "https://registry.npmjs.org/@azure/core-util/-/core-util-1.14.0.tgz", + "integrity": "sha512-9n2pWK61veAuN0V20t9lOuoV4CFMdyAZ1ygZzvBGk/pBBJRib/PjL9PLXa/aI2CcPpyHfqVsxxqLCYl6uZlfDw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@azure/abort-controller": "^2.1.2", + "@typespec/ts-http-runtime": "^0.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/@azure/identity": { + "version": "4.14.1", + "resolved": "https://registry.npmjs.org/@azure/identity/-/identity-4.14.1.tgz", + "integrity": "sha512-HHuuFrmN1uuF9D5A6aAo5eHzNFNX4Q+P4SksZqDKse5YaJFFy/zDLG3wXHEV2FVGgetZ3QM8jGURNBtnQYf1NQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@azure/abort-controller": "^2.0.0", + "@azure/core-auth": "^1.9.0", + "@azure/core-client": "^1.9.2", + "@azure/core-process": "^1.0.0", + "@azure/core-rest-pipeline": "^1.17.0", + "@azure/core-tracing": "^1.0.0", + "@azure/core-util": "^1.11.0", + "@azure/logger": "^1.0.0", + "@azure/msal-browser": "^5.5.0", + "@azure/msal-node": "^7.1.0", + "open": "^11.0.0", + "tslib": "^2.2.0" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/@azure/logger": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/@azure/logger/-/logger-1.4.0.tgz", + "integrity": "sha512-rbAE25KUfjU/s3XHUdJgceoCP5dEOpMx85J04kF+QMdta73XkuG9JGHHinch+XIoKpBdqljin+KqURpJriSzLA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@typespec/ts-http-runtime": "^0.3.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/@azure/msal-browser": { + "version": "5.30.0", + "resolved": "https://registry.npmjs.org/@azure/msal-browser/-/msal-browser-5.30.0.tgz", + "integrity": "sha512-o/ADxWxEFcVrE65a7ssOGuxnivq8lcy+2hSGlOOwtn0gGd6iiwl3q8/BMVRorYE81UB/r4B+8WGEUxWnqP7ryA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@azure/msal-common": "16.17.0" + }, + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/@azure/msal-common": { + "version": "16.17.0", + "resolved": "https://registry.npmjs.org/@azure/msal-common/-/msal-common-16.17.0.tgz", + "integrity": "sha512-rNvtEm7Axzj18neIk0C8kjr1ZXbJsHkWDqGedCfOiLVBjSCxWBcbJ26/I7g9owoeGKUoyrOgs73cIk7WxLd9qA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.8.0" + } + }, + "node_modules/@azure/msal-node": { + "version": "7.2.3", + "resolved": "https://registry.npmjs.org/@azure/msal-node/-/msal-node-7.2.3.tgz", + "integrity": "sha512-eRIo5XuQAJrubo4514gEnmREKI35045LItjucOEK/YNQYj3LhEpYEbBdqjlu/wmd9Rcqp2c3GJ4ynFoEqby3sg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@azure/msal-common": "16.17.0", + "jsonwebtoken": "^9.0.0" + }, + "engines": { + "node": ">=20" + } + }, + "node_modules/@babel/code-frame": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/code-frame/-/code-frame-7.29.7.tgz", + "integrity": "sha512-Aup7aUOfpbAUg2ROOJN6Iw5f9DMBlzu0mIkm/malLQFN/YQgO48wCj0Kxa3sEHJvPVFg7siR+qRInwXd2qhQKw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/helper-validator-identifier": "^7.29.7", + "js-tokens": "^4.0.0", + "picocolors": "^1.1.1" + }, + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@babel/helper-validator-identifier": { + "version": "7.29.7", + "resolved": "https://registry.npmjs.org/@babel/helper-validator-identifier/-/helper-validator-identifier-7.29.7.tgz", + "integrity": "sha512-qehxGkRj55h/ff8EMaJ+cYhyaKlHIxqYDn682wQD7RNp9UujOQsHog2uS0r2vzr4pW+sXf90NeeayjcNaX3fFg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6.9.0" + } + }, + "node_modules/@esbuild/aix-ppc64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/aix-ppc64/-/aix-ppc64-0.25.12.tgz", + "integrity": "sha512-Hhmwd6CInZ3dwpuGTF8fJG6yoWmsToE+vYgD4nytZVxcu1ulHpUQRAB1UJ8+N1Am3Mz4+xOByoQoSZf4D+CpkA==", + "cpu": [ + "ppc64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "aix" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm/-/android-arm-0.25.12.tgz", + "integrity": "sha512-VJ+sKvNA/GE7Ccacc9Cha7bpS8nyzVv0jdVgwNDaR4gDMC/2TTRc33Ip8qrNYUcpkOHUT5OZ0bUcNNVZQ9RLlg==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-arm64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/android-arm64/-/android-arm64-0.25.12.tgz", + "integrity": "sha512-6AAmLG7zwD1Z159jCKPvAxZd4y/VTO0VkprYy+3N2FtJ8+BQWFXU+OxARIwA46c5tdD9SsKGZ/1ocqBS/gAKHg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/android-x64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/android-x64/-/android-x64-0.25.12.tgz", + "integrity": "sha512-5jbb+2hhDHx5phYR2By8GTWEzn6I9UqR11Kwf22iKbNpYrsmRB18aX/9ivc5cabcUiAT/wM+YIZ6SG9QO6a8kg==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "android" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-arm64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-arm64/-/darwin-arm64-0.25.12.tgz", + "integrity": "sha512-N3zl+lxHCifgIlcMUP5016ESkeQjLj/959RxxNYIthIg+CQHInujFuXeWbWMgnTo4cp5XVHqFPmpyu9J65C1Yg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/darwin-x64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/darwin-x64/-/darwin-x64-0.25.12.tgz", + "integrity": "sha512-HQ9ka4Kx21qHXwtlTUVbKJOAnmG1ipXhdWTmNXiPzPfWKpXqASVcWdnf2bnL73wgjNrFXAa3yYvBSd9pzfEIpA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "darwin" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-arm64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-arm64/-/freebsd-arm64-0.25.12.tgz", + "integrity": "sha512-gA0Bx759+7Jve03K1S0vkOu5Lg/85dou3EseOGUes8flVOGxbhDDh/iZaoek11Y8mtyKPGF3vP8XhnkDEAmzeg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/freebsd-x64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/freebsd-x64/-/freebsd-x64-0.25.12.tgz", + "integrity": "sha512-TGbO26Yw2xsHzxtbVFGEXBFH0FRAP7gtcPE7P5yP7wGy7cXK2oO7RyOhL5NLiqTlBh47XhmIUXuGciXEqYFfBQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "freebsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm/-/linux-arm-0.25.12.tgz", + "integrity": "sha512-lPDGyC1JPDou8kGcywY0YILzWlhhnRjdof3UlcoqYmS9El818LLfJJc3PXXgZHrHCAKs/Z2SeZtDJr5MrkxtOw==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-arm64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-arm64/-/linux-arm64-0.25.12.tgz", + "integrity": "sha512-8bwX7a8FghIgrupcxb4aUmYDLp8pX06rGh5HqDT7bB+8Rdells6mHvrFHHW2JAOPZUbnjUpKTLg6ECyzvas2AQ==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ia32": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ia32/-/linux-ia32-0.25.12.tgz", + "integrity": "sha512-0y9KrdVnbMM2/vG8KfU0byhUN+EFCny9+8g202gYqSSVMonbsCfLjUO+rCci7pM0WBEtz+oK/PIwHkzxkyharA==", + "cpu": [ + "ia32" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-loong64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-loong64/-/linux-loong64-0.25.12.tgz", + "integrity": "sha512-h///Lr5a9rib/v1GGqXVGzjL4TMvVTv+s1DPoxQdz7l/AYv6LDSxdIwzxkrPW438oUXiDtwM10o9PmwS/6Z0Ng==", + "cpu": [ + "loong64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-mips64el": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-mips64el/-/linux-mips64el-0.25.12.tgz", + "integrity": "sha512-iyRrM1Pzy9GFMDLsXn1iHUm18nhKnNMWscjmp4+hpafcZjrr2WbT//d20xaGljXDBYHqRcl8HnxbX6uaA/eGVw==", + "cpu": [ + "mips64el" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-ppc64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-ppc64/-/linux-ppc64-0.25.12.tgz", + "integrity": "sha512-9meM/lRXxMi5PSUqEXRCtVjEZBGwB7P/D4yT8UG/mwIdze2aV4Vo6U5gD3+RsoHXKkHCfSxZKzmDssVlRj1QQA==", + "cpu": [ + "ppc64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-riscv64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-riscv64/-/linux-riscv64-0.25.12.tgz", + "integrity": "sha512-Zr7KR4hgKUpWAwb1f3o5ygT04MzqVrGEGXGLnj15YQDJErYu/BGg+wmFlIDOdJp0PmB0lLvxFIOXZgFRrdjR0w==", + "cpu": [ + "riscv64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-s390x": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-s390x/-/linux-s390x-0.25.12.tgz", + "integrity": "sha512-MsKncOcgTNvdtiISc/jZs/Zf8d0cl/t3gYWX8J9ubBnVOwlk65UIEEvgBORTiljloIWnBzLs4qhzPkJcitIzIg==", + "cpu": [ + "s390x" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/linux-x64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/linux-x64/-/linux-x64-0.25.12.tgz", + "integrity": "sha512-uqZMTLr/zR/ed4jIGnwSLkaHmPjOjJvnm6TVVitAa08SLS9Z0VM8wIRx7gWbJB5/J54YuIMInDquWyYvQLZkgw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "linux" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/netbsd-arm64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-arm64/-/netbsd-arm64-0.25.12.tgz", + "integrity": "sha512-xXwcTq4GhRM7J9A8Gv5boanHhRa/Q9KLVmcyXHCTaM4wKfIpWkdXiMog/KsnxzJ0A1+nD+zoecuzqPmCRyBGjg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/netbsd-x64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/netbsd-x64/-/netbsd-x64-0.25.12.tgz", + "integrity": "sha512-Ld5pTlzPy3YwGec4OuHh1aCVCRvOXdH8DgRjfDy/oumVovmuSzWfnSJg+VtakB9Cm0gxNO9BzWkj6mtO1FMXkQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "netbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-arm64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-arm64/-/openbsd-arm64-0.25.12.tgz", + "integrity": "sha512-fF96T6KsBo/pkQI950FARU9apGNTSlZGsv1jZBAlcLL1MLjLNIWPBkj5NlSz8aAzYKg+eNqknrUJ24QBybeR5A==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openbsd-x64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/openbsd-x64/-/openbsd-x64-0.25.12.tgz", + "integrity": "sha512-MZyXUkZHjQxUvzK7rN8DJ3SRmrVrke8ZyRusHlP+kuwqTcfWLyqMOE3sScPPyeIXN/mDJIfGXvcMqCgYKekoQw==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openbsd" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/openharmony-arm64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/openharmony-arm64/-/openharmony-arm64-0.25.12.tgz", + "integrity": "sha512-rm0YWsqUSRrjncSXGA7Zv78Nbnw4XL6/dzr20cyrQf7ZmRcsovpcRBdhD43Nuk3y7XIoW2OxMVvwuRvk9XdASg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "openharmony" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/sunos-x64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/sunos-x64/-/sunos-x64-0.25.12.tgz", + "integrity": "sha512-3wGSCDyuTHQUzt0nV7bocDy72r2lI33QL3gkDNGkod22EsYl04sMf0qLb8luNKTOmgF/eDEDP5BFNwoBKH441w==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "sunos" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-arm64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/win32-arm64/-/win32-arm64-0.25.12.tgz", + "integrity": "sha512-rMmLrur64A7+DKlnSuwqUdRKyd3UE7oPJZmnljqEptesKM8wx9J8gx5u0+9Pq0fQQW8vqeKebwNXdfOyP+8Bsg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-ia32": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/win32-ia32/-/win32-ia32-0.25.12.tgz", + "integrity": "sha512-HkqnmmBoCbCwxUKKNPBixiWDGCpQGVsrQfJoVGYLPT41XWF8lHuE5N6WhVia2n4o5QK5M4tYr21827fNhi4byQ==", + "cpu": [ + "ia32" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@esbuild/win32-x64": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/@esbuild/win32-x64/-/win32-x64-0.25.12.tgz", + "integrity": "sha512-alJC0uCZpTFrSL0CCDjcgleBXPnCrEAhTBILpeAp7M/OFgoqtAetfBzX0xM00MUsVVPpVjlPuMbREqnZCXaTnA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "MIT", + "optional": true, + "os": [ + "win32" + ], + "engines": { + "node": ">=18" + } + }, + "node_modules/@nodelib/fs.scandir": { + "version": "2.1.5", + "resolved": "https://registry.npmjs.org/@nodelib/fs.scandir/-/fs.scandir-2.1.5.tgz", + "integrity": "sha512-vq24Bq3ym5HEQm2NKCr3yXDwjc7vTsEThRDnkp2DK9p1uqLR+DHurm/NOTo0KG7HYHU7eppKZj3MyqYuMBf62g==", + "dev": true, + "license": "MIT", + "dependencies": { + "@nodelib/fs.stat": "2.0.5", + "run-parallel": "^1.1.9" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.stat": { + "version": "2.0.5", + "resolved": "https://registry.npmjs.org/@nodelib/fs.stat/-/fs.stat-2.0.5.tgz", + "integrity": "sha512-RkhPPp2zrqDAQA/2jNhnztcPAlv64XdhIp7a7454A5ovI7Bukxgt7MX7udwAu3zg1DcpPU0rz3VV1SeaqvY4+A==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 8" + } + }, + "node_modules/@nodelib/fs.walk": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/@nodelib/fs.walk/-/fs.walk-1.2.8.tgz", + "integrity": "sha512-oGB+UxlgWcgQkgwo8GcEGwemoTFt3FIO9ababBmaGwXIoBKZ+GTy0pP185beGg7Llih/NSHSV2XAs1lnznocSg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@nodelib/fs.scandir": "2.1.5", + "fastq": "^1.6.0" + }, + "engines": { + "node": ">= 8" + } + }, + "node_modules/@secretlint/config-creator": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/@secretlint/config-creator/-/config-creator-10.2.2.tgz", + "integrity": "sha512-BynOBe7Hn3LJjb3CqCHZjeNB09s/vgf0baBaHVw67w7gHF0d25c3ZsZ5+vv8TgwSchRdUCRrbbcq5i2B1fJ2QQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@secretlint/types": "^10.2.2" + }, + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/@secretlint/config-loader": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/@secretlint/config-loader/-/config-loader-10.2.2.tgz", + "integrity": "sha512-ndjjQNgLg4DIcMJp4iaRD6xb9ijWQZVbd9694Ol2IszBIbGPPkwZHzJYKICbTBmh6AH/pLr0CiCaWdGJU7RbpQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@secretlint/profiler": "^10.2.2", + "@secretlint/resolver": "^10.2.2", + "@secretlint/types": "^10.2.2", + "ajv": "^8.17.1", + "debug": "^4.4.1", + "rc-config-loader": "^4.1.3" + }, + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/@secretlint/core": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/@secretlint/core/-/core-10.2.2.tgz", + "integrity": "sha512-6rdwBwLP9+TO3rRjMVW1tX+lQeo5gBbxl1I5F8nh8bgGtKwdlCMhMKsBWzWg1ostxx/tIG7OjZI0/BxsP8bUgw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@secretlint/profiler": "^10.2.2", + "@secretlint/types": "^10.2.2", + "debug": "^4.4.1", + "structured-source": "^4.0.0" + }, + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/@secretlint/formatter": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/@secretlint/formatter/-/formatter-10.2.2.tgz", + "integrity": "sha512-10f/eKV+8YdGKNQmoDUD1QnYL7TzhI2kzyx95vsJKbEa8akzLAR5ZrWIZ3LbcMmBLzxlSQMMccRmi05yDQ5YDA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@secretlint/resolver": "^10.2.2", + "@secretlint/types": "^10.2.2", + "@textlint/linter-formatter": "^15.2.0", + "@textlint/module-interop": "^15.2.0", + "@textlint/types": "^15.2.0", + "chalk": "^5.4.1", + "debug": "^4.4.1", + "pluralize": "^8.0.0", + "strip-ansi": "^7.1.0", + "table": "^6.9.0", + "terminal-link": "^4.0.0" + }, + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/@secretlint/formatter/node_modules/chalk": { + "version": "5.6.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.6.2.tgz", + "integrity": "sha512-7NzBL0rN6fMUW+f7A6Io4h40qQlG+xGmtMxfbnH/K7TAtt8JQWVQK+6g0UXKMeVJoyV5EkkNsErQ8pVD3bLHbA==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^12.17.0 || ^14.13 || >=16.0.0" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/@secretlint/node": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/@secretlint/node/-/node-10.2.2.tgz", + "integrity": "sha512-eZGJQgcg/3WRBwX1bRnss7RmHHK/YlP/l7zOQsrjexYt6l+JJa5YhUmHbuGXS94yW0++3YkEJp0kQGYhiw1DMQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@secretlint/config-loader": "^10.2.2", + "@secretlint/core": "^10.2.2", + "@secretlint/formatter": "^10.2.2", + "@secretlint/profiler": "^10.2.2", + "@secretlint/source-creator": "^10.2.2", + "@secretlint/types": "^10.2.2", + "debug": "^4.4.1", + "p-map": "^7.0.3" + }, + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/@secretlint/profiler": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/@secretlint/profiler/-/profiler-10.2.2.tgz", + "integrity": "sha512-qm9rWfkh/o8OvzMIfY8a5bCmgIniSpltbVlUVl983zDG1bUuQNd1/5lUEeWx5o/WJ99bXxS7yNI4/KIXfHexig==", + "dev": true, + "license": "MIT" + }, + "node_modules/@secretlint/resolver": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/@secretlint/resolver/-/resolver-10.2.2.tgz", + "integrity": "sha512-3md0cp12e+Ae5V+crPQYGd6aaO7ahw95s28OlULGyclyyUtf861UoRGS2prnUrKh7MZb23kdDOyGCYb9br5e4w==", + "dev": true, + "license": "MIT" + }, + "node_modules/@secretlint/secretlint-formatter-sarif": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/@secretlint/secretlint-formatter-sarif/-/secretlint-formatter-sarif-10.2.2.tgz", + "integrity": "sha512-ojiF9TGRKJJw308DnYBucHxkpNovDNu1XvPh7IfUp0A12gzTtxuWDqdpuVezL7/IP8Ua7mp5/VkDMN9OLp1doQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "node-sarif-builder": "^3.2.0" + } + }, + "node_modules/@secretlint/secretlint-rule-no-dotenv": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/@secretlint/secretlint-rule-no-dotenv/-/secretlint-rule-no-dotenv-10.2.2.tgz", + "integrity": "sha512-KJRbIShA9DVc5Va3yArtJ6QDzGjg3PRa1uYp9As4RsyKtKSSZjI64jVca57FZ8gbuk4em0/0Jq+uy6485wxIdg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@secretlint/types": "^10.2.2" + }, + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/@secretlint/secretlint-rule-preset-recommend": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/@secretlint/secretlint-rule-preset-recommend/-/secretlint-rule-preset-recommend-10.2.2.tgz", + "integrity": "sha512-K3jPqjva8bQndDKJqctnGfwuAxU2n9XNCPtbXVI5JvC7FnQiNg/yWlQPbMUlBXtBoBGFYp08A94m6fvtc9v+zA==", + "deprecated": "Built into secretlint v14 and later. Remove this package; the rule id still works. https://github.com/secretlint/secretlint/blob/HEAD/docs/rules/preset-recommend.md", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/@secretlint/source-creator": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/@secretlint/source-creator/-/source-creator-10.2.2.tgz", + "integrity": "sha512-h6I87xJfwfUTgQ7irWq7UTdq/Bm1RuQ/fYhA3dtTIAop5BwSFmZyrchph4WcoEvbN460BWKmk4RYSvPElIIvxw==", + "dev": true, + "license": "MIT", + "dependencies": { + "@secretlint/types": "^10.2.2", + "istextorbinary": "^9.5.0" + }, + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/@secretlint/types": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/@secretlint/types/-/types-10.2.2.tgz", + "integrity": "sha512-Nqc90v4lWCXyakD6xNyNACBJNJ0tNCwj2WNk/7ivyacYHxiITVgmLUFXTBOeCdy79iz6HtN9Y31uw/jbLrdOAg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/@sindresorhus/merge-streams": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/@sindresorhus/merge-streams/-/merge-streams-2.3.0.tgz", + "integrity": "sha512-LtoMMhxAlorcGhmFYI+LhPgbPZCkgP6ra1YL604EeF6U98pLlQ3iWIGMdWSC+vWmPBWBNgmDBAhnAobLROJmwg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/@textlint/ast-node-types": { + "version": "15.8.0", + "resolved": "https://registry.npmjs.org/@textlint/ast-node-types/-/ast-node-types-15.8.0.tgz", + "integrity": "sha512-5CiH9COYmovWmExQgs7763DzX6Gy9zjkjJ7JxCC95wyTcjwQn/8poNF6fv3qzRlmx8CRRde8DHr9FcgAAiPzgw==", + "dev": true, + "license": "MIT" + }, + "node_modules/@textlint/linter-formatter": { + "version": "15.8.0", + "resolved": "https://registry.npmjs.org/@textlint/linter-formatter/-/linter-formatter-15.8.0.tgz", + "integrity": "sha512-+oU3A235NATv6Lzi4xa4kJ65PuNJlIxesaO4AvDhDWA9FWm7y4XKWaoQCW1esgaQQ6dwnUiFKArQ8TcJ86mC4w==", + "dev": true, + "license": "MIT", + "dependencies": { + "@azu/format-text": "^1.0.2", + "@azu/style-format": "^1.0.1", + "@textlint/module-interop": "15.8.0", + "@textlint/resolver": "15.8.0", + "@textlint/types": "15.8.0", + "debug": "^4.4.3", + "js-yaml": "^4.3.0", + "lodash": "^4.18.1", + "pluralize": "^2.0.0", + "string-width": "^4.2.3", + "strip-ansi": "^6.0.1", + "table": "^6.9.0", + "text-table": "^0.2.0" + }, + "engines": { + "node": ">=20.18.0" + } + }, + "node_modules/@textlint/linter-formatter/node_modules/ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/@textlint/linter-formatter/node_modules/pluralize": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/pluralize/-/pluralize-2.0.0.tgz", + "integrity": "sha512-TqNZzQCD4S42De9IfnnBvILN7HAW7riLqsCyp8lgjXeysyPlX5HhqKAcJHHHb9XskE4/a+7VGC9zzx8Ls0jOAw==", + "dev": true, + "license": "MIT" + }, + "node_modules/@textlint/linter-formatter/node_modules/strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/@textlint/module-interop": { + "version": "15.8.0", + "resolved": "https://registry.npmjs.org/@textlint/module-interop/-/module-interop-15.8.0.tgz", + "integrity": "sha512-rt+OR1WYGoLOY8HkA/aBPrqufF6yUUEsKEAh7XohTsT3lp9IyZFT6zOIbjul9P4FAzsmSPkcrYjVx3Bz/IUfkg==", + "dev": true, + "license": "MIT" + }, + "node_modules/@textlint/resolver": { + "version": "15.8.0", + "resolved": "https://registry.npmjs.org/@textlint/resolver/-/resolver-15.8.0.tgz", + "integrity": "sha512-E88tzfX3K8Jykk+38aJ9cy8RquD8ABVOPTO2rFEESq0wcg8x6/ypdAS8ZgR7OKiGqlRF0hkO/m5PbQwVfKM3VA==", + "dev": true, + "license": "MIT" + }, + "node_modules/@textlint/types": { + "version": "15.8.0", + "resolved": "https://registry.npmjs.org/@textlint/types/-/types-15.8.0.tgz", + "integrity": "sha512-Anhc6y5736YIsvqae0U6k0YmB2M/QVHkEeOv2aydAn/WIkdI69dCOiDbe3/+RagS3qstFTSFWJzNRA2lUjv19w==", + "dev": true, + "license": "MIT", + "dependencies": { + "@textlint/ast-node-types": "15.8.0" + } + }, + "node_modules/@types/node": { + "version": "22.20.5", + "resolved": "https://registry.npmjs.org/@types/node/-/node-22.20.5.tgz", + "integrity": "sha512-U2+DNr+wSjpsTS/wZGYHq7GcwfuSmKiKvoPvK22zwTlRhU91yOniN4qRR5KhIjvif7ysw/dz/hKmfDH0Ris4aA==", + "dev": true, + "license": "MIT", + "dependencies": { + "undici-types": "~6.21.0" + } + }, + "node_modules/@types/normalize-package-data": { + "version": "2.4.4", + "resolved": "https://registry.npmjs.org/@types/normalize-package-data/-/normalize-package-data-2.4.4.tgz", + "integrity": "sha512-37i+OaWTh9qeK4LSHPsyRC7NahnGotNuZvjLSgcPzblpHB3rrCJxAOgI5gCdKm7coonsaX1Of0ILiTcnZjbfxA==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/sarif": { + "version": "2.1.7", + "resolved": "https://registry.npmjs.org/@types/sarif/-/sarif-2.1.7.tgz", + "integrity": "sha512-kRz0VEkJqWLf1LLVN4pT1cg1Z9wAuvI6L97V3m2f5B76Tg8d413ddvLBPTEHAZJlnn4XSvu0FkZtViCQGVyrXQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/@types/vscode": { + "version": "1.85.0", + "resolved": "https://registry.npmjs.org/@types/vscode/-/vscode-1.85.0.tgz", + "integrity": "sha512-CF/RBon/GXwdfmnjZj0WTUMZN5H6YITOfBCP4iEZlOtVQXuzw6t7Le7+cR+7JzdMrnlm7Mfp49Oj2TuSXIWo3g==", + "dev": true, + "license": "MIT" + }, + "node_modules/@typespec/ts-http-runtime": { + "version": "0.3.11", + "resolved": "https://registry.npmjs.org/@typespec/ts-http-runtime/-/ts-http-runtime-0.3.11.tgz", + "integrity": "sha512-KZlacW7zFdcIOAcpNiV5U9fy0Tfgw7xdEc4rVyuUtQS+UR1Sn32PXuAz+AJ70Y0yzTWh62/pEEpFmWUJl6YySw==", + "dev": true, + "license": "MIT", + "dependencies": { + "http-proxy-agent": "^7.0.0", + "https-proxy-agent": "^7.0.0", + "tslib": "^2.6.2" + }, + "engines": { + "node": ">=22.0.0" + } + }, + "node_modules/@vscode/test-electron": { + "version": "2.5.2", + "resolved": "https://registry.npmjs.org/@vscode/test-electron/-/test-electron-2.5.2.tgz", + "integrity": "sha512-8ukpxv4wYe0iWMRQU18jhzJOHkeGKbnw7xWRX3Zw1WJA4cEKbHcmmLPdPrPtL6rhDcrlCZN+xKRpv09n4gRHYg==", + "dev": true, + "license": "MIT", + "dependencies": { + "http-proxy-agent": "^7.0.2", + "https-proxy-agent": "^7.0.5", + "jszip": "^3.10.1", + "ora": "^8.1.0", + "semver": "^7.6.2" + }, + "engines": { + "node": ">=16" + } + }, + "node_modules/@vscode/vsce": { + "version": "3.9.2", + "resolved": "https://registry.npmjs.org/@vscode/vsce/-/vsce-3.9.2.tgz", + "integrity": "sha512-XSxMosEEDO6vLxELAHVkwmhC0qe0ijZni2jB9Rcs8kQsW4lhTDQ/wMzmwFs/buotAWSnpmUp/dRWD2ufG3UYKA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@azure/identity": "^4.1.0", + "@secretlint/node": "^10.1.2", + "@secretlint/secretlint-formatter-sarif": "^10.1.2", + "@secretlint/secretlint-rule-no-dotenv": "^10.1.2", + "@secretlint/secretlint-rule-preset-recommend": "^10.1.2", + "@vscode/vsce-sign": "^2.0.0", + "azure-devops-node-api": "^12.5.0", + "chalk": "^4.1.2", + "cheerio": "^1.0.0-rc.9", + "cockatiel": "^3.1.2", + "commander": "^12.1.0", + "form-data": "^4.0.0", + "glob": "^13.0.6", + "hosted-git-info": "^4.0.2", + "jsonc-parser": "^3.2.0", + "leven": "^3.1.0", + "markdown-it": "^14.1.0", + "mime": "^1.3.4", + "minimatch": "^10.2.2", + "parse-semver": "^1.1.1", + "read": "^1.0.7", + "secretlint": "^10.1.2", + "semver": "^7.5.2", + "tmp": "^0.2.3", + "typed-rest-client": "^1.8.4", + "url-join": "^4.0.1", + "xml2js": "^0.5.0", + "yauzl": "^3.2.1", + "yazl": "^2.2.2" + }, + "bin": { + "vsce": "vsce" + }, + "engines": { + "node": ">= 20" + }, + "optionalDependencies": { + "keytar": "^7.7.0" + } + }, + "node_modules/@vscode/vsce-sign": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/@vscode/vsce-sign/-/vsce-sign-2.1.1.tgz", + "integrity": "sha512-Fm9SrvxonXpmzN0eKHKS/AHb/3Gc19c7SkGfSnhYOGPiLy2o8hJlIzx314IVSH//uEiKaAbE40P47wwFtyDByg==", + "dev": true, + "hasInstallScript": true, + "license": "SEE LICENSE IN LICENSE.txt", + "optionalDependencies": { + "@vscode/vsce-sign-alpine-arm64": "2.0.8", + "@vscode/vsce-sign-alpine-x64": "2.0.8", + "@vscode/vsce-sign-darwin-arm64": "2.0.8", + "@vscode/vsce-sign-darwin-x64": "2.0.8", + "@vscode/vsce-sign-linux-arm": "2.0.8", + "@vscode/vsce-sign-linux-arm64": "2.0.8", + "@vscode/vsce-sign-linux-x64": "2.0.8", + "@vscode/vsce-sign-win32-arm64": "2.0.8", + "@vscode/vsce-sign-win32-x64": "2.0.8" + } + }, + "node_modules/@vscode/vsce-sign-alpine-arm64": { + "version": "2.0.8", + "resolved": "https://registry.npmjs.org/@vscode/vsce-sign-alpine-arm64/-/vsce-sign-alpine-arm64-2.0.8.tgz", + "integrity": "sha512-3HSEDf4R2zhI3/eckZPWBoeFUiLpnG9O0/NBW8xCM3j+Ri0uhmOPvCDuCYsUmIsFVUJETaMu+JMY2DF8v8hNPg==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "SEE LICENSE IN LICENSE.txt", + "optional": true, + "os": [ + "alpine" + ] + }, + "node_modules/@vscode/vsce-sign-alpine-x64": { + "version": "2.0.8", + "resolved": "https://registry.npmjs.org/@vscode/vsce-sign-alpine-x64/-/vsce-sign-alpine-x64-2.0.8.tgz", + "integrity": "sha512-rHbdV7+esCVn/t8KnbSN9CyMGImAmGnxFb1K9d2uSrt0WNPYfL12FGFekhz2yI8sFhIhyxD+vIKTSp9+kLx+5A==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "SEE LICENSE IN LICENSE.txt", + "optional": true, + "os": [ + "alpine" + ] + }, + "node_modules/@vscode/vsce-sign-darwin-arm64": { + "version": "2.0.8", + "resolved": "https://registry.npmjs.org/@vscode/vsce-sign-darwin-arm64/-/vsce-sign-darwin-arm64-2.0.8.tgz", + "integrity": "sha512-/JSzSLCbXSlc+X7PfmHWnXczFHRmKURCwN1MGmJXjUJlWHgTDpaqjaJNMnBNqruyrbb6LRE/DMXTfRY9iwr4jA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "SEE LICENSE IN LICENSE.txt", + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@vscode/vsce-sign-darwin-x64": { + "version": "2.0.8", + "resolved": "https://registry.npmjs.org/@vscode/vsce-sign-darwin-x64/-/vsce-sign-darwin-x64-2.0.8.tgz", + "integrity": "sha512-iowH17iKIaAiC6TNGIksLmwtcKOHh/HT/pwKHwPZnuTLvdKWZ/8VOT+MphEt71EcWttohqUXx41SjdiCfUPBiA==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "SEE LICENSE IN LICENSE.txt", + "optional": true, + "os": [ + "darwin" + ] + }, + "node_modules/@vscode/vsce-sign-linux-arm": { + "version": "2.0.8", + "resolved": "https://registry.npmjs.org/@vscode/vsce-sign-linux-arm/-/vsce-sign-linux-arm-2.0.8.tgz", + "integrity": "sha512-SVzcxe2fx+1meLyO745eUiywrRDQIXwK/oZcwTrzYEkoVh4Val4/8CtDHIc5Z3EhHnwVBnqGqsbNwkR44k7rXA==", + "cpu": [ + "arm" + ], + "dev": true, + "license": "SEE LICENSE IN LICENSE.txt", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@vscode/vsce-sign-linux-arm64": { + "version": "2.0.8", + "resolved": "https://registry.npmjs.org/@vscode/vsce-sign-linux-arm64/-/vsce-sign-linux-arm64-2.0.8.tgz", + "integrity": "sha512-94aBLOVdO6eAOylUsyJ40/BdHtRrHuKAa/29KNOci2QtwUBAH9jTWJLpn1Yv+xjlUOaSjQC8UlAUtjqz/g6FPA==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "SEE LICENSE IN LICENSE.txt", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@vscode/vsce-sign-linux-x64": { + "version": "2.0.8", + "resolved": "https://registry.npmjs.org/@vscode/vsce-sign-linux-x64/-/vsce-sign-linux-x64-2.0.8.tgz", + "integrity": "sha512-i55pKFRMF1nR94CMcFHbr3VQz7rQ8DFURvUd2Jymcbtv8qzhPX2otIHWzkcmAVr4dQApbYYCvRPjbP+i12ImQQ==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "SEE LICENSE IN LICENSE.txt", + "optional": true, + "os": [ + "linux" + ] + }, + "node_modules/@vscode/vsce-sign-win32-arm64": { + "version": "2.0.8", + "resolved": "https://registry.npmjs.org/@vscode/vsce-sign-win32-arm64/-/vsce-sign-win32-arm64-2.0.8.tgz", + "integrity": "sha512-2CoVlRNow2XkNboxlfx8hGdKLR2hvyBRg1O8gafx8I4F+scm1MLHdGcYV3+u3jXDsJaiSyDshTO5vPcLjQpVug==", + "cpu": [ + "arm64" + ], + "dev": true, + "license": "SEE LICENSE IN LICENSE.txt", + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/@vscode/vsce-sign-win32-x64": { + "version": "2.0.8", + "resolved": "https://registry.npmjs.org/@vscode/vsce-sign-win32-x64/-/vsce-sign-win32-x64-2.0.8.tgz", + "integrity": "sha512-93c+KXIvOsLlNLMEPtQBgJJgn2eaypv3G3+4O9RailUQTh9zL3ul/Fhnqf0O+NKOGKky9d/v+GYWhBwsAjZaww==", + "cpu": [ + "x64" + ], + "dev": true, + "license": "SEE LICENSE IN LICENSE.txt", + "optional": true, + "os": [ + "win32" + ] + }, + "node_modules/agent-base": { + "version": "7.1.4", + "resolved": "https://registry.npmjs.org/agent-base/-/agent-base-7.1.4.tgz", + "integrity": "sha512-MnA+YT8fwfJPgBx3m60MNqakm30XOkyIoH1y6huTQvC0PwZG7ki8NacLBcrPbNoo8vEZy7Jpuk7+jMO+CUovTQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 14" + } + }, + "node_modules/ajv": { + "version": "8.20.0", + "resolved": "https://registry.npmjs.org/ajv/-/ajv-8.20.0.tgz", + "integrity": "sha512-Thbli+OlOj+iMPYFBVBfJ3OmCAnaSyNn4M1vz9T6Gka5Jt9ba/HIR56joy65tY6kx/FCF5VXNB819Y7/GUrBGA==", + "dev": true, + "license": "MIT", + "dependencies": { + "fast-deep-equal": "^3.1.3", + "fast-uri": "^3.0.1", + "json-schema-traverse": "^1.0.0", + "require-from-string": "^2.0.2" + }, + "funding": { + "type": "github", + "url": "https://github.com/sponsors/epoberezkin" + } + }, + "node_modules/ansi-escapes": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/ansi-escapes/-/ansi-escapes-7.3.0.tgz", + "integrity": "sha512-BvU8nYgGQBxcmMuEeUEmNTvrMVjJNSH7RgW24vXexN4Ven6qCvy4TntnvlnwnMLTVlcRQQdbRY8NKnaIoeWDNg==", + "dev": true, + "license": "MIT", + "dependencies": { + "environment": "^1.0.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/ansi-regex": { + "version": "6.6.0", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-6.6.0.tgz", + "integrity": "sha512-XZ5apbzreCbXSKwPjJstu8R0zOi247w3XYwWxtwBXgpZrCyc1Ka7p9/xY0A9/diMewmHbEKz+FIraWaEWjlN5g==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/ansi-regex?sponsor=1" + } + }, + "node_modules/ansi-styles": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/ansi-styles/-/ansi-styles-4.3.0.tgz", + "integrity": "sha512-zbB9rCJAT1rbjiVDb2hqKFHNYLxgtk8NURxZ3IZwD3F6NtxbXZQCnnSi1Lkx+IDohdPlFp222wVALIheZJQSEg==", + "dev": true, + "license": "MIT", + "dependencies": { + "color-convert": "^2.0.1" + }, + "engines": { + "node": ">=8" + }, + "funding": { + "url": "https://github.com/chalk/ansi-styles?sponsor=1" + } + }, + "node_modules/argparse": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-2.0.1.tgz", + "integrity": "sha512-8+9WqebbFzpX9OR+Wa6O29asIogeRMzcGtAINdpMHHyAg10f05aSFVBbcEqGf/PXw1EjAZ+q2/bEBg3DvurK3Q==", + "dev": true, + "license": "Python-2.0" + }, + "node_modules/astral-regex": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/astral-regex/-/astral-regex-2.0.0.tgz", + "integrity": "sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/asynckit": { + "version": "0.4.0", + "resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz", + "integrity": "sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q==", + "dev": true, + "license": "MIT" + }, + "node_modules/azure-devops-node-api": { + "version": "12.5.0", + "resolved": "https://registry.npmjs.org/azure-devops-node-api/-/azure-devops-node-api-12.5.0.tgz", + "integrity": "sha512-R5eFskGvOm3U/GzeAuxRkUsAl0hrAwGgWn6zAd2KrZmrEhWZVqLew4OOupbQlXUuojUzpGtq62SmdhJ06N88og==", + "dev": true, + "license": "MIT", + "dependencies": { + "tunnel": "0.0.6", + "typed-rest-client": "^1.8.4" + } + }, + "node_modules/balanced-match": { + "version": "4.0.4", + "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-4.0.4.tgz", + "integrity": "sha512-BLrgEcRTwX2o6gGxGOCNyMvGSp35YofuYzw9h1IMTRmKqttAZZVU67bdb9Pr2vUHA8+j3i2tJfjO6C6+4myGTA==", + "dev": true, + "license": "MIT", + "engines": { + "node": "18 || 20 || >=22" + } + }, + "node_modules/base64-js": { + "version": "1.5.1", + "resolved": "https://registry.npmjs.org/base64-js/-/base64-js-1.5.1.tgz", + "integrity": "sha512-AKpaYlHn8t4SVbOHCy+b5+KKgvR4vrsD8vbvrbiQJps7fKDTkjkDry6ji0rUJjC0kzbNePLwzxq8iypo41qeWA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "optional": true + }, + "node_modules/binaryextensions": { + "version": "6.11.0", + "resolved": "https://registry.npmjs.org/binaryextensions/-/binaryextensions-6.11.0.tgz", + "integrity": "sha512-sXnYK/Ij80TO3lcqZVV2YgfKN5QjUWIRk/XSm2J/4bd/lPko3lvk0O4ZppH6m+6hB2/GTu+ptNwVFe1xh+QLQw==", + "dev": true, + "license": "Artistic-2.0", + "dependencies": { + "editions": "^6.21.0" + }, + "engines": { + "node": ">=4" + }, + "funding": { + "url": "https://bevry.me/fund" + } + }, + "node_modules/bl": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/bl/-/bl-4.1.0.tgz", + "integrity": "sha512-1W07cM9gS6DcLperZfFSj+bWLtaPGSOHWhPiGzXmvVJbRLdG82sH/Kn8EtW1VqWVA54AKf2h5k5BbnIbwF3h6w==", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "buffer": "^5.5.0", + "inherits": "^2.0.4", + "readable-stream": "^3.4.0" + } + }, + "node_modules/bl/node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/boolbase": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/boolbase/-/boolbase-1.0.0.tgz", + "integrity": "sha512-JZOSA7Mo9sNGB8+UjSgzdLtokWAky1zbztM3WRLCbZ70/3cTANmQmOdR7y2g+J0e2WXywy1yS468tY+IruqEww==", + "dev": true, + "license": "ISC" + }, + "node_modules/boundary": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/boundary/-/boundary-2.0.0.tgz", + "integrity": "sha512-rJKn5ooC9u8q13IMCrW0RSp31pxBCHE3y9V/tp3TdWSLf8Em3p6Di4NBpfzbJge9YjjFEsD0RtFEjtvHL5VyEA==", + "dev": true, + "license": "BSD-2-Clause" + }, + "node_modules/brace-expansion": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-5.1.0.tgz", + "integrity": "sha512-aa11Dv491GKnYqxaul3aRJ0szew7yMJMfZPnqD44NjGrZXoj62l41OEDDpdpC4eE2P88vBFfLuSyRhpG91NUvg==", + "dev": true, + "license": "MIT", + "dependencies": { + "balanced-match": "^4.0.2" + }, + "engines": { + "node": "20 || >=22" + } + }, + "node_modules/braces": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/braces/-/braces-3.0.3.tgz", + "integrity": "sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==", + "dev": true, + "license": "MIT", + "dependencies": { + "fill-range": "^7.1.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/buffer": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/buffer/-/buffer-5.7.1.tgz", + "integrity": "sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "optional": true, + "dependencies": { + "base64-js": "^1.3.1", + "ieee754": "^1.1.13" + } + }, + "node_modules/buffer-crc32": { + "version": "0.2.13", + "resolved": "https://registry.npmjs.org/buffer-crc32/-/buffer-crc32-0.2.13.tgz", + "integrity": "sha512-VO9Ht/+p3SN7SKWqcrgEzjGbRSJYTx+Q1pTQC0wrWqHx0vpJraQ6GtHx8tvcg1rlK1byhU5gccxgOgj7B0TDkQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": "*" + } + }, + "node_modules/buffer-equal-constant-time": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/buffer-equal-constant-time/-/buffer-equal-constant-time-1.0.1.tgz", + "integrity": "sha512-zRpUiDwd/xk6ADqPMATG8vc9VPrkck7T07OIx0gnjmJAnHnTVXNQG3vfvWNuiZIkwu9KrKdA1iJKfsfTVxE6NA==", + "dev": true, + "license": "BSD-3-Clause" + }, + "node_modules/bundle-name": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/bundle-name/-/bundle-name-4.1.1.tgz", + "integrity": "sha512-DdH81/zPLVS11EUgWq3tEu/xn+EzljlMYooDNdzWEnFha3R3NBMpMV1UqYIpjYHV/SgpFKMIX1Oh7o06SjM/oA==", + "dev": true, + "license": "MIT", + "dependencies": { + "run-applescript": "^7.0.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/call-bind-apply-helpers": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/call-bind-apply-helpers/-/call-bind-apply-helpers-1.0.2.tgz", + "integrity": "sha512-Sp1ablJ0ivDkSzjcaJdxEunN5/XvksFJ2sMBFfq6x0ryhQV/2b/KwFe21cMpmHtPOSij8K99/wSfoEuTObmuMQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/call-bound": { + "version": "1.0.4", + "resolved": "https://registry.npmjs.org/call-bound/-/call-bound-1.0.4.tgz", + "integrity": "sha512-+ys997U96po4Kx/ABpBCqhA9EuxJaQWDQg7295H4hBphv3IZg0boBKuwYpt4YXp6MZ5AmZQnU/tyMTlRpaSejg==", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind-apply-helpers": "^1.0.2", + "get-intrinsic": "^1.3.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/chalk": { + "version": "4.1.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-4.1.2.tgz", + "integrity": "sha512-oKnbhFyRIXpUuez8iBMmyEa4nbj4IOQyuhc/wy9kY7/WVPcwIO9VA668Pu8RkO7+0G76SLROeyw9CpQ061i4mA==", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.1.0", + "supports-color": "^7.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/cheerio": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/cheerio/-/cheerio-1.2.0.tgz", + "integrity": "sha512-WDrybc/gKFpTYQutKIK6UvfcuxijIZfMfXaYm8NMsPQxSYvf+13fXUJ4rztGGbJcBQ/GF55gvrZ0Bc0bj/mqvg==", + "dev": true, + "license": "MIT", + "dependencies": { + "cheerio-select": "^2.1.0", + "dom-serializer": "^2.0.0", + "domhandler": "^5.0.3", + "domutils": "^3.2.2", + "encoding-sniffer": "^0.2.1", + "htmlparser2": "^10.1.0", + "parse5": "^7.3.0", + "parse5-htmlparser2-tree-adapter": "^7.1.0", + "parse5-parser-stream": "^7.1.2", + "undici": "^7.19.0", + "whatwg-mimetype": "^4.0.0" + }, + "engines": { + "node": ">=20.18.1" + }, + "funding": { + "url": "https://github.com/cheeriojs/cheerio?sponsor=1" + } + }, + "node_modules/cheerio-select": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/cheerio-select/-/cheerio-select-2.1.0.tgz", + "integrity": "sha512-9v9kG0LvzrlcungtnJtpGNxY+fzECQKhK4EGJX2vByejiMX84MFNQw4UxPJl3bFbTMw+Dfs37XaIkCwTZfLh4g==", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "boolbase": "^1.0.0", + "css-select": "^5.1.0", + "css-what": "^6.1.0", + "domelementtype": "^2.3.0", + "domhandler": "^5.0.3", + "domutils": "^3.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/chownr": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/chownr/-/chownr-1.1.4.tgz", + "integrity": "sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==", + "dev": true, + "license": "ISC", + "optional": true + }, + "node_modules/cli-cursor": { + "version": "5.0.0", + "resolved": "https://registry.npmjs.org/cli-cursor/-/cli-cursor-5.0.0.tgz", + "integrity": "sha512-aCj4O5wKyszjMmDT4tZj93kxyydN/K5zPWSCe6/0AV/AA1pqe5ZBIw0a2ZfPQV7lL5/yb5HsUreJ6UFAF1tEQw==", + "dev": true, + "license": "MIT", + "dependencies": { + "restore-cursor": "^5.0.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/cli-spinners": { + "version": "2.9.2", + "resolved": "https://registry.npmjs.org/cli-spinners/-/cli-spinners-2.9.2.tgz", + "integrity": "sha512-ywqV+5MmyL4E7ybXgKys4DugZbX0FC6LnwrhjuykIjnK9k8OQacQ7axGKnjDXWNhns0xot3bZI5h55H8yo9cJg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/cockatiel": { + "version": "3.2.1", + "resolved": "https://registry.npmjs.org/cockatiel/-/cockatiel-3.2.1.tgz", + "integrity": "sha512-gfrHV6ZPkquExvMh9IOkKsBzNDk6sDuZ6DdBGUBkvFnTCqCxzpuq48RySgP0AnaqQkw2zynOFj9yly6T1Q2G5Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=16" + } + }, + "node_modules/color-convert": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/color-convert/-/color-convert-2.0.1.tgz", + "integrity": "sha512-RRECPsj7iu/xb5oKYcsFHSppFNnsj/52OVTRKb4zP5onXwVF3zVmmToNcOfGC+CRDpfK/U584fMg38ZHCaElKQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "color-name": "~1.1.4" + }, + "engines": { + "node": ">=7.0.0" + } + }, + "node_modules/color-name": { + "version": "1.1.4", + "resolved": "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz", + "integrity": "sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA==", + "dev": true, + "license": "MIT" + }, + "node_modules/combined-stream": { + "version": "1.0.8", + "resolved": "https://registry.npmjs.org/combined-stream/-/combined-stream-1.0.8.tgz", + "integrity": "sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg==", + "dev": true, + "license": "MIT", + "dependencies": { + "delayed-stream": "~1.0.0" + }, + "engines": { + "node": ">= 0.8" + } + }, + "node_modules/commander": { + "version": "12.1.0", + "resolved": "https://registry.npmjs.org/commander/-/commander-12.1.0.tgz", + "integrity": "sha512-Vw8qHK3bZM9y/P10u3Vib8o/DdkvA2OtPtZvD871QKjy74Wj1WSKFILMPRPSdUSx5RFK1arlJzEtA4PkFgnbuA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/core-util-is": { + "version": "1.0.3", + "resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz", + "integrity": "sha512-ZQBvi1DcpJ4GDqanjucZ2Hj3wEO5pZDS89BWbkcrvdxksJorwUDDZamX9ldFkp9aw2lmBDLgkObEA4DWNJ9FYQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/css-select": { + "version": "5.2.2", + "resolved": "https://registry.npmjs.org/css-select/-/css-select-5.2.2.tgz", + "integrity": "sha512-TizTzUddG/xYLA3NXodFM0fSbNizXjOKhqiQQwvhlspadZokn1KDy0NZFS0wuEubIYAV5/c1/lAr0TaaFXEXzw==", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "boolbase": "^1.0.0", + "css-what": "^6.1.0", + "domhandler": "^5.0.2", + "domutils": "^3.0.1", + "nth-check": "^2.0.1" + }, + "funding": { + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/css-what": { + "version": "6.2.2", + "resolved": "https://registry.npmjs.org/css-what/-/css-what-6.2.2.tgz", + "integrity": "sha512-u/O3vwbptzhMs3L1fQE82ZSLHQQfto5gyZzwteVIEyeaY5Fc7R4dapF/BvRoSYFeqfBk4m0V1Vafq5Pjv25wvA==", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">= 6" + }, + "funding": { + "url": "https://github.com/sponsors/fb55" + } + }, + "node_modules/debug": { + "version": "4.4.3", + "resolved": "https://registry.npmjs.org/debug/-/debug-4.4.3.tgz", + "integrity": "sha512-RGwwWnwQvkVfavKVt22FGLw+xYSdzARwm0ru6DhTVA3umU5hZc28V3kO4stgYryrTlLpuvgI9GiijltAjNbcqA==", + "dev": true, + "license": "MIT", + "dependencies": { + "ms": "^2.1.3" + }, + "engines": { + "node": ">=6.0" + }, + "peerDependenciesMeta": { + "supports-color": { + "optional": true + } + } + }, + "node_modules/decompress-response": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/decompress-response/-/decompress-response-6.0.0.tgz", + "integrity": "sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ==", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "mimic-response": "^3.1.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/deep-extend": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/deep-extend/-/deep-extend-0.6.0.tgz", + "integrity": "sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA==", + "dev": true, + "license": "MIT", + "optional": true, + "engines": { + "node": ">=4.0.0" + } + }, + "node_modules/default-browser": { + "version": "5.5.1", + "resolved": "https://registry.npmjs.org/default-browser/-/default-browser-5.5.1.tgz", + "integrity": "sha512-m1pAzaJgZ/gssEqlOhJkPJp8Xly7QyW6xcrkUa2KKcDeDSEMP7X8xipU3snUcfisTQx0w1AGae+9UtJSfVnXGw==", + "dev": true, + "license": "MIT", + "dependencies": { + "bundle-name": "^4.1.0", + "default-browser-id": "^5.0.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/default-browser-id": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/default-browser-id/-/default-browser-id-5.0.1.tgz", + "integrity": "sha512-x1VCxdX4t+8wVfd1so/9w+vQ4vx7lKd2Qp5tDRutErwmR85OgmfX7RlLRMWafRMY7hbEiXIbudNrjOAPa/hL8Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/define-lazy-prop": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/define-lazy-prop/-/define-lazy-prop-3.0.0.tgz", + "integrity": "sha512-N+MeXYoqr3pOgn8xfyRPREN7gHakLYjhsHhWGT3fWAiL4IkAt0iDw14QiiEm2bE30c5XX5q0FtAA3CK5f9/BUg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/delayed-stream": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/delayed-stream/-/delayed-stream-1.0.0.tgz", + "integrity": "sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.4.0" + } + }, + "node_modules/detect-libc": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/detect-libc/-/detect-libc-2.1.2.tgz", + "integrity": "sha512-Btj2BOOO83o3WyH59e8MgXsxEQVcarkUOpEYrubB0urwnN10yQ364rsiByU11nZlqWYZm05i/of7io4mzihBtQ==", + "dev": true, + "license": "Apache-2.0", + "optional": true, + "engines": { + "node": ">=8" + } + }, + "node_modules/dom-serializer": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/dom-serializer/-/dom-serializer-2.0.0.tgz", + "integrity": "sha512-wIkAryiqt/nV5EQKqQpo3SToSOV9J0DnbJqwK7Wv/Trc92zIAYZ4FlMu+JPFW1DfGFt81ZTCGgDEabffXeLyJg==", + "dev": true, + "license": "MIT", + "dependencies": { + "domelementtype": "^2.3.0", + "domhandler": "^5.0.2", + "entities": "^4.2.0" + }, + "funding": { + "url": "https://github.com/cheeriojs/dom-serializer?sponsor=1" + } + }, + "node_modules/domelementtype": { + "version": "2.3.0", + "resolved": "https://registry.npmjs.org/domelementtype/-/domelementtype-2.3.0.tgz", + "integrity": "sha512-OLETBj6w0OsagBwdXnPdN0cnMfF9opN69co+7ZrbfPGrdpPVNBUj02spi6B1N7wChLQiPn4CSH/zJvXw56gmHw==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + ], + "license": "BSD-2-Clause" + }, + "node_modules/domhandler": { + "version": "5.0.3", + "resolved": "https://registry.npmjs.org/domhandler/-/domhandler-5.0.3.tgz", + "integrity": "sha512-cgwlv/1iFQiFnU96XXgROh8xTeetsnJiDsTc7TYCLFd9+/WNkIqPTxiM/8pSd8VIrhXGTf1Ny1q1hquVqDJB5w==", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "domelementtype": "^2.3.0" + }, + "engines": { + "node": ">= 4" + }, + "funding": { + "url": "https://github.com/fb55/domhandler?sponsor=1" + } + }, + "node_modules/domutils": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/domutils/-/domutils-3.2.2.tgz", + "integrity": "sha512-6kZKyUajlDuqlHKVX1w7gyslj9MPIXzIFiz/rGu35uC1wMi+kMhQwGhl4lt9unC9Vb9INnY9Z3/ZA3+FhASLaw==", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "dom-serializer": "^2.0.0", + "domelementtype": "^2.3.0", + "domhandler": "^5.0.3" + }, + "funding": { + "url": "https://github.com/fb55/domutils?sponsor=1" + } + }, + "node_modules/dunder-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/dunder-proto/-/dunder-proto-1.0.1.tgz", + "integrity": "sha512-KIN/nDJBQRcXw0MLVhZE9iQHmG68qAVIBg9CqmUYjmQIhgij9U5MFvrqkUL5FbtyyzZuOeOt0zdeRe4UY7ct+A==", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind-apply-helpers": "^1.0.1", + "es-errors": "^1.3.0", + "gopd": "^1.2.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/ecdsa-sig-formatter": { + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/ecdsa-sig-formatter/-/ecdsa-sig-formatter-1.0.11.tgz", + "integrity": "sha512-nagl3RYrbNv6kQkeJIpt6NJZy8twLB/2vtz6yN9Z4vRKHN4/QZJIEbqohALSgwKdnksuY3k5Addp5lg8sVoVcQ==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "safe-buffer": "^5.0.1" + } + }, + "node_modules/editions": { + "version": "6.22.0", + "resolved": "https://registry.npmjs.org/editions/-/editions-6.22.0.tgz", + "integrity": "sha512-UgGlf8IW75je7HZjNDpJdCv4cGJWIi6yumFdZ0R7A8/CIhQiWUjyGLCxdHpd8bmyD1gnkfUNK0oeOXqUS2cpfQ==", + "dev": true, + "license": "Artistic-2.0", + "dependencies": { + "version-range": "^4.15.0" + }, + "engines": { + "ecmascript": ">= es5", + "node": ">=4" + }, + "funding": { + "url": "https://bevry.me/fund" + } + }, + "node_modules/emoji-regex": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-8.0.0.tgz", + "integrity": "sha512-MSjYzcWNOA0ewAHpz0MxpYFvwg6yjy1NG3xteoqz644VCo/RPgnr1/GGt+ic3iJTzQ8Eu3TdM14SawnVUmGE6A==", + "dev": true, + "license": "MIT" + }, + "node_modules/encoding-sniffer": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/encoding-sniffer/-/encoding-sniffer-0.2.1.tgz", + "integrity": "sha512-5gvq20T6vfpekVtqrYQsSCFZ1wEg5+wW0/QaZMWkFr6BqD3NfKs0rLCx4rrVlSWJeZb5NBJgVLswK/w2MWU+Gw==", + "dev": true, + "license": "MIT", + "dependencies": { + "iconv-lite": "^0.6.3", + "whatwg-encoding": "^3.1.1" + }, + "funding": { + "url": "https://github.com/fb55/encoding-sniffer?sponsor=1" + } + }, + "node_modules/end-of-stream": { + "version": "1.4.5", + "resolved": "https://registry.npmjs.org/end-of-stream/-/end-of-stream-1.4.5.tgz", + "integrity": "sha512-ooEGc6HP26xXq/N+GCGOT0JKCLDGrq2bQUZrQ7gyrJiZANJ/8YDTxTpQBXGMn+WbIQXNVpyWymm7KYVICQnyOg==", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "once": "^1.4.0" + } + }, + "node_modules/entities": { + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/entities/-/entities-4.5.0.tgz", + "integrity": "sha512-V0hjH4dGPh9Ao5p0MoRY6BVqtwCjhz6vI5LT8AJ55H+4g9/4vbHx1I54fS0XuclLhDHArPQCiMjDxjaL8fPxhw==", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=0.12" + }, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/environment": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/environment/-/environment-1.1.0.tgz", + "integrity": "sha512-xUtoPkMggbz0MPyPiIWr1Kp4aeWJjDZ6SMvURhimjdZgsRuDplF5/s9hcgGhyXMhs+6vpnuoiZ2kFiu3FMnS8Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/es-define-property": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/es-define-property/-/es-define-property-1.0.1.tgz", + "integrity": "sha512-e3nRfgfUZ4rNGL232gUgX06QNyyez04KdjFrF+LTRoOXmrOgFKDg4BCdsjW8EnT69eqdYGmRpJwiPVYNrCaW3g==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-errors": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/es-errors/-/es-errors-1.3.0.tgz", + "integrity": "sha512-Zf5H2Kxt2xjTvbJvP2ZWLEICxA6j+hAmMzIlypy4xcBg1vKVnx89Wy0GbS+kf5cwCVFFzdCFh2XSCFNULS6csw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-object-atoms": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/es-object-atoms/-/es-object-atoms-1.1.2.tgz", + "integrity": "sha512-HWcBoN6NileqtSydK2FqHbS/LoDd2pqrnQHLyJzBj4kOp/ky2MWMN694xOfkK8/SnUsW2DH7EfyVlydKCsm1Zw==", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/es-set-tostringtag": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/es-set-tostringtag/-/es-set-tostringtag-2.1.0.tgz", + "integrity": "sha512-j6vWzfrGVfyXxge+O0x5sh6cvxAog0a/4Rdd2K36zCMV5eJ+/+tOAngRO8cODMNWbVRdVlmGZQL2YS3yR8bIUA==", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.6", + "has-tostringtag": "^1.0.2", + "hasown": "^2.0.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/esbuild": { + "version": "0.25.12", + "resolved": "https://registry.npmjs.org/esbuild/-/esbuild-0.25.12.tgz", + "integrity": "sha512-bbPBYYrtZbkt6Os6FiTLCTFxvq4tt3JKall1vRwshA3fdVztsLAatFaZobhkBC8/BrPetoa0oksYoKXoG4ryJg==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "bin": { + "esbuild": "bin/esbuild" + }, + "engines": { + "node": ">=18" + }, + "optionalDependencies": { + "@esbuild/aix-ppc64": "0.25.12", + "@esbuild/android-arm": "0.25.12", + "@esbuild/android-arm64": "0.25.12", + "@esbuild/android-x64": "0.25.12", + "@esbuild/darwin-arm64": "0.25.12", + "@esbuild/darwin-x64": "0.25.12", + "@esbuild/freebsd-arm64": "0.25.12", + "@esbuild/freebsd-x64": "0.25.12", + "@esbuild/linux-arm": "0.25.12", + "@esbuild/linux-arm64": "0.25.12", + "@esbuild/linux-ia32": "0.25.12", + "@esbuild/linux-loong64": "0.25.12", + "@esbuild/linux-mips64el": "0.25.12", + "@esbuild/linux-ppc64": "0.25.12", + "@esbuild/linux-riscv64": "0.25.12", + "@esbuild/linux-s390x": "0.25.12", + "@esbuild/linux-x64": "0.25.12", + "@esbuild/netbsd-arm64": "0.25.12", + "@esbuild/netbsd-x64": "0.25.12", + "@esbuild/openbsd-arm64": "0.25.12", + "@esbuild/openbsd-x64": "0.25.12", + "@esbuild/openharmony-arm64": "0.25.12", + "@esbuild/sunos-x64": "0.25.12", + "@esbuild/win32-arm64": "0.25.12", + "@esbuild/win32-ia32": "0.25.12", + "@esbuild/win32-x64": "0.25.12" + } + }, + "node_modules/expand-template": { + "version": "2.0.3", + "resolved": "https://registry.npmjs.org/expand-template/-/expand-template-2.0.3.tgz", + "integrity": "sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==", + "dev": true, + "license": "(MIT OR WTFPL)", + "optional": true, + "engines": { + "node": ">=6" + } + }, + "node_modules/fast-deep-equal": { + "version": "3.1.3", + "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", + "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", + "dev": true, + "license": "MIT" + }, + "node_modules/fast-glob": { + "version": "3.3.3", + "resolved": "https://registry.npmjs.org/fast-glob/-/fast-glob-3.3.3.tgz", + "integrity": "sha512-7MptL8U0cqcFdzIzwOTHoilX9x5BrNqye7Z/LuC7kCMRio1EMSyqRK3BEAUD7sXRq4iT4AzTVuZdhgQ2TCvYLg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@nodelib/fs.stat": "^2.0.2", + "@nodelib/fs.walk": "^1.2.3", + "glob-parent": "^5.1.2", + "merge2": "^1.3.0", + "micromatch": "^4.0.8" + }, + "engines": { + "node": ">=8.6.0" + } + }, + "node_modules/fast-uri": { + "version": "3.1.9", + "resolved": "https://registry.npmjs.org/fast-uri/-/fast-uri-3.1.9.tgz", + "integrity": "sha512-hS/0Wt3Ya043oKXs0sIxrMpKQITXhMLIrVAKKXi4gozGC9v7YRWVnXIZzjNPTO02M9BdxLCWqK1yRXgNziVyJQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/fastify" + }, + { + "type": "opencollective", + "url": "https://opencollective.com/fastify" + } + ], + "license": "BSD-3-Clause" + }, + "node_modules/fastq": { + "version": "1.20.3", + "resolved": "https://registry.npmjs.org/fastq/-/fastq-1.20.3.tgz", + "integrity": "sha512-XKv5nnLs6nLF71NgiKJLIZFLkPyIEuOselLG7ujZnGrRfQK8HpvY+WqKhAJUAdLomwVHErVS4LfxFlPq0/FTAw==", + "dev": true, + "license": "ISC", + "dependencies": { + "reusify": "^1.0.4" + } + }, + "node_modules/fill-range": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", + "integrity": "sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==", + "dev": true, + "license": "MIT", + "dependencies": { + "to-regex-range": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/form-data": { + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/form-data/-/form-data-4.0.6.tgz", + "integrity": "sha512-vKatAh4SlVfgbv+YtmhiRjhEMJsYpsG1Y2rMQtR+SVSbytsSD1YGzDIcrAJmdFec88u/+VoGmxnl+80gL1tRCQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "asynckit": "^0.4.0", + "combined-stream": "^1.0.8", + "es-set-tostringtag": "^2.1.0", + "hasown": "^2.0.4", + "mime-types": "^2.1.35" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/fs-constants": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/fs-constants/-/fs-constants-1.0.0.tgz", + "integrity": "sha512-y6OAwoSIf7FyjMIv94u+b5rdheZEjzR63GTyZJm5qh4Bi+2YgwLCcI/fPFZkL5PSixOt6ZNKm+w+Hfp/Bciwow==", + "dev": true, + "license": "MIT", + "optional": true + }, + "node_modules/fs-extra": { + "version": "11.4.1", + "resolved": "https://registry.npmjs.org/fs-extra/-/fs-extra-11.4.1.tgz", + "integrity": "sha512-KYAb4c9BJQI6QqGKthV68OHe0badztdXJWKo0WtBA9IuCFPTKvE5ZdUBglP833aMjhaSPNO4A5j/EkzZtGlKjA==", + "dev": true, + "license": "MIT", + "dependencies": { + "graceful-fs": "^4.2.0", + "jsonfile": "^6.0.1", + "universalify": "^2.0.0" + }, + "engines": { + "node": ">=14.14" + } + }, + "node_modules/function-bind": { + "version": "1.1.2", + "resolved": "https://registry.npmjs.org/function-bind/-/function-bind-1.1.2.tgz", + "integrity": "sha512-7XHNxH7qX9xG5mIwxkhumTox/MIRNcOgDrxWsMt2pAr23WHp6MrRlN7FBSFpCpr+oVO0F744iUgR82nJMfG2SA==", + "dev": true, + "license": "MIT", + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-east-asian-width": { + "version": "1.7.0", + "resolved": "https://registry.npmjs.org/get-east-asian-width/-/get-east-asian-width-1.7.0.tgz", + "integrity": "sha512-XjH1AECxf0giL2V1aU8vKyRR2ppRUb5c0EvT7zuJTokQ74bNo52zOtghqdWIqrhUD79fo3x0WfKZdOqxF6LG1Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/get-intrinsic": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/get-intrinsic/-/get-intrinsic-1.3.0.tgz", + "integrity": "sha512-9fSjSaos/fRIVIp+xSJlE6lfwhES7LNtKaCBIamHsjr2na1BiABJPo0mOjjz8GJDURarmCPGqaiVg5mfjb98CQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bind-apply-helpers": "^1.0.2", + "es-define-property": "^1.0.1", + "es-errors": "^1.3.0", + "es-object-atoms": "^1.1.1", + "function-bind": "^1.1.2", + "get-proto": "^1.0.1", + "gopd": "^1.2.0", + "has-symbols": "^1.1.0", + "hasown": "^2.0.2", + "math-intrinsics": "^1.1.0" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/get-proto": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/get-proto/-/get-proto-1.0.1.tgz", + "integrity": "sha512-sTSfBjoXBp89JvIKIefqw7U2CCebsc74kiY6awiGogKtoSGbgjYE/G/+l9sF3MWFPNc9IcoOC4ODfKHfxFmp0g==", + "dev": true, + "license": "MIT", + "dependencies": { + "dunder-proto": "^1.0.1", + "es-object-atoms": "^1.0.0" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/github-from-package": { + "version": "0.0.0", + "resolved": "https://registry.npmjs.org/github-from-package/-/github-from-package-0.0.0.tgz", + "integrity": "sha512-SyHy3T1v2NUXn29OsWdxmK6RwHD+vkj3v8en8AOBZ1wBQ/hCAQ5bAQTD02kW4W9tUp/3Qh6J8r9EvntiyCmOOw==", + "dev": true, + "license": "MIT", + "optional": true + }, + "node_modules/glob": { + "version": "13.0.7", + "resolved": "https://registry.npmjs.org/glob/-/glob-13.0.7.tgz", + "integrity": "sha512-wfsFgXQ8A3SEI9XGf7Nl3Y9l7ffSrGh7SUCT7vU/2CzYPep9kjxAn1S40F9OPKxAMGCVl7HtNlJhrCJUeUq83g==", + "dev": true, + "license": "BlueOak-1.0.0", + "dependencies": { + "minimatch": "^10.2.2", + "minipass": "^7.1.3", + "path-scurry": "^2.0.2" + }, + "engines": { + "node": "18 || 20 || >=22" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/glob-parent": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-5.1.2.tgz", + "integrity": "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==", + "dev": true, + "license": "ISC", + "dependencies": { + "is-glob": "^4.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/globby": { + "version": "14.1.0", + "resolved": "https://registry.npmjs.org/globby/-/globby-14.1.0.tgz", + "integrity": "sha512-0Ia46fDOaT7k4og1PDW4YbodWWr3scS2vAr2lTbsplOt2WkKp0vQbkI9wKis/T5LV/dqPjO3bpS/z6GTJB82LA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@sindresorhus/merge-streams": "^2.1.0", + "fast-glob": "^3.3.3", + "ignore": "^7.0.3", + "path-type": "^6.0.0", + "slash": "^5.1.0", + "unicorn-magic": "^0.3.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/gopd": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/gopd/-/gopd-1.2.0.tgz", + "integrity": "sha512-ZUKRh6/kUFoAiTAtTYPZJ3hw9wNxx+BIBOijnlG9PnrJsCcSjs1wyyD6vJpaYtgnzDrKYRSqf3OO6Rfa93xsRg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/graceful-fs": { + "version": "4.2.12", + "resolved": "https://registry.npmjs.org/graceful-fs/-/graceful-fs-4.2.12.tgz", + "integrity": "sha512-iuyGF2E4oafQfPsRrG2wtY2ILupMhvtdrhzrxB+0VcjsPpSPttpfYdjnGFGsTi5MaJFjI1jOKHPQ6UTbTj9TAw==", + "dev": true, + "license": "BlueOak-1.0.0" + }, + "node_modules/has-flag": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/has-flag/-/has-flag-4.0.0.tgz", + "integrity": "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/has-symbols": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/has-symbols/-/has-symbols-1.1.0.tgz", + "integrity": "sha512-1cDNdwJ2Jaohmb3sg4OmKaMBwuC48sYni5HUw2DvsC8LjGTLK9h+eb1X6RyuOHe4hT0ULCW68iomhjUoKUqlPQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/has-tostringtag": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/has-tostringtag/-/has-tostringtag-1.0.2.tgz", + "integrity": "sha512-NqADB8VjPFLM2V0VvHUewwwsw0ZWBaIdgo+ieHtK3hasLz4qeCRjYcqfB6AQrBggRKppKF8L52/VqdVsO47Dlw==", + "dev": true, + "license": "MIT", + "dependencies": { + "has-symbols": "^1.0.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/hasown": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/hasown/-/hasown-2.0.4.tgz", + "integrity": "sha512-T2UbfbBEF32wiepXIsMlTW9+dDYC6wMh/t/vYA4tuOMKqWz/n3vr1NFSxQiyP+zk2mXsoMA/i/7qV6LKut1t1A==", + "dev": true, + "license": "MIT", + "dependencies": { + "function-bind": "^1.1.2" + }, + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/hosted-git-info": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-4.1.0.tgz", + "integrity": "sha512-kyCuEOWjJqZuDbRHzL8V93NzQhwIB71oFWSyzVo+KPZI+pnQPPxucdkrOZvkLRnrf5URsQM+IJ09Dw29cRALIA==", + "dev": true, + "license": "ISC", + "dependencies": { + "lru-cache": "^6.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/htmlparser2": { + "version": "10.1.0", + "resolved": "https://registry.npmjs.org/htmlparser2/-/htmlparser2-10.1.0.tgz", + "integrity": "sha512-VTZkM9GWRAtEpveh7MSF6SjjrpNVNNVJfFup7xTY3UpFtm67foy9HDVXneLtFVt4pMz5kZtgNcvCniNFb1hlEQ==", + "dev": true, + "funding": [ + "https://github.com/fb55/htmlparser2?sponsor=1", + { + "type": "github", + "url": "https://github.com/sponsors/fb55" + } + ], + "license": "MIT", + "dependencies": { + "domelementtype": "^2.3.0", + "domhandler": "^5.0.3", + "domutils": "^3.2.2", + "entities": "^7.0.1" + } + }, + "node_modules/htmlparser2/node_modules/entities": { + "version": "7.0.1", + "resolved": "https://registry.npmjs.org/entities/-/entities-7.0.1.tgz", + "integrity": "sha512-TWrgLOFUQTH994YUyl1yT4uyavY5nNB5muff+RtWaqNVCAK408b5ZnnbNAUEWLTCpum9w6arT70i1XdQ4UeOPA==", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=0.12" + }, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/http-proxy-agent": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/http-proxy-agent/-/http-proxy-agent-7.0.2.tgz", + "integrity": "sha512-T1gkAiYYDWYx3V5Bmyu7HcfcvL7mUrTWiM6yOfa3PIphViJ/gFPbvidQ+veqSOHci/PxBcDabeUNCzpOODJZig==", + "dev": true, + "license": "MIT", + "dependencies": { + "agent-base": "^7.1.0", + "debug": "^4.3.4" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/https-proxy-agent": { + "version": "7.0.6", + "resolved": "https://registry.npmjs.org/https-proxy-agent/-/https-proxy-agent-7.0.6.tgz", + "integrity": "sha512-vK9P5/iUfdl95AI+JVyUuIcVtd4ofvtrOr3HNtM2yxC9bnMbEdp3x01OhQNnjb8IJYi38VlTE3mBXwcfvywuSw==", + "dev": true, + "license": "MIT", + "dependencies": { + "agent-base": "^7.1.2", + "debug": "4" + }, + "engines": { + "node": ">= 14" + } + }, + "node_modules/iconv-lite": { + "version": "0.6.3", + "resolved": "https://registry.npmjs.org/iconv-lite/-/iconv-lite-0.6.3.tgz", + "integrity": "sha512-4fCk79wshMdzMp2rH06qWrJE4iolqLhCUH+OiuIgU++RB0+94NlDL81atO7GX55uUKueo0txHNtvEyI6D7WdMw==", + "dev": true, + "license": "MIT", + "dependencies": { + "safer-buffer": ">= 2.1.2 < 3.0.0" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/ieee754": { + "version": "1.2.1", + "resolved": "https://registry.npmjs.org/ieee754/-/ieee754-1.2.1.tgz", + "integrity": "sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "BSD-3-Clause", + "optional": true + }, + "node_modules/ignore": { + "version": "7.0.16", + "resolved": "https://registry.npmjs.org/ignore/-/ignore-7.0.16.tgz", + "integrity": "sha512-52N+Y4HRMOJmbLmr+DqO4iSRyyB7N52gm7PWCT6h0p978+oKbqHCB7gIJIwZvBUsjlSdWbrBFqUSmIFNZMpn0A==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 4" + } + }, + "node_modules/immediate": { + "version": "3.0.6", + "resolved": "https://registry.npmjs.org/immediate/-/immediate-3.0.6.tgz", + "integrity": "sha512-XXOFtyqDjNDAQxVfYxuF7g9Il/IbWmmlQg2MYKOH8ExIT1qg6xc4zyS3HaEEATgs1btfzxq15ciUiY7gjSXRGQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/index-to-position": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/index-to-position/-/index-to-position-1.2.0.tgz", + "integrity": "sha512-Yg7+ztRkqslMAS2iFaU+Oa4KTSidr63OsFGlOrJoW981kIYO3CGCS3wA95P1mUi/IVSJkn0D479KTJpVpvFNuw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/inherits": { + "version": "2.0.4", + "resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.4.tgz", + "integrity": "sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ==", + "dev": true, + "license": "ISC" + }, + "node_modules/ini": { + "version": "1.3.8", + "resolved": "https://registry.npmjs.org/ini/-/ini-1.3.8.tgz", + "integrity": "sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==", + "dev": true, + "license": "ISC", + "optional": true + }, + "node_modules/is-docker": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-docker/-/is-docker-3.0.0.tgz", + "integrity": "sha512-eljcgEDlEns/7AXFosB5K/2nCM4P7FQPkGc/DWLy5rmFEWvZayGrik1d9/QIY5nJ4f9YsVvBkA6kJpHn9rISdQ==", + "dev": true, + "license": "MIT", + "bin": { + "is-docker": "cli.js" + }, + "engines": { + "node": "^12.20.0 || ^14.13.1 || >=16.0.0" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-extglob": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/is-extglob/-/is-extglob-2.1.1.tgz", + "integrity": "sha512-SbKbANkN603Vi4jEZv49LeVJMn4yGwsbzZworEoyEiutsN3nJYdbO36zfhGJ6QEDpOZIFkDtnq5JRxmvl3jsoQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-fullwidth-code-point": { + "version": "3.0.0", + "resolved": "https://registry.npmjs.org/is-fullwidth-code-point/-/is-fullwidth-code-point-3.0.0.tgz", + "integrity": "sha512-zymm5+u+sCsSWyD9qNaejV3DFvhCKclKdizYaJUuHA83RLjb7nSuGnddCHGv0hk+KY7BMAlsWeK4Ueg6EV6XQg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/is-glob": { + "version": "4.0.3", + "resolved": "https://registry.npmjs.org/is-glob/-/is-glob-4.0.3.tgz", + "integrity": "sha512-xelSayHH36ZgE7ZWhli7pW34hNbNl8Ojv5KVmkJD4hBdD3th8Tfk9vYasLM+mXWOZhFkgZfxhLSnrwRr4elSSg==", + "dev": true, + "license": "MIT", + "dependencies": { + "is-extglob": "^2.1.1" + }, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/is-in-ssh": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-in-ssh/-/is-in-ssh-1.0.0.tgz", + "integrity": "sha512-jYa6Q9rH90kR1vKB6NM7qqd1mge3Fx4Dhw5TVlK1MUBqhEOuCagrEHMevNuCcbECmXZ0ThXkRm+Ymr51HwEPAw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=20" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-inside-container": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/is-inside-container/-/is-inside-container-1.0.0.tgz", + "integrity": "sha512-KIYLCCJghfHZxqjYBE7rEy0OBuTd5xCHS7tHVgvCLkx7StIoaxwNW3hCALgEUjFfeRk+MG/Qxmp/vtETEF3tRA==", + "dev": true, + "license": "MIT", + "dependencies": { + "is-docker": "^3.0.0" + }, + "bin": { + "is-inside-container": "cli.js" + }, + "engines": { + "node": ">=14.16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-interactive": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/is-interactive/-/is-interactive-2.0.0.tgz", + "integrity": "sha512-qP1vozQRI+BMOPcjFzrjXuQvdak2pHNUMZoeG2eRbiSqyvbEf/wQtEOTOX1guk6E3t36RkaqiSt8A/6YElNxLQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-number": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/is-number/-/is-number-7.0.0.tgz", + "integrity": "sha512-41Cifkg6e8TylSpdtTpeLVMqvSBEVzTttHvERD741+pnZ8ANv0004MRL43QKPDlK9cGvNp6NZWZUBlbGXYxxng==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.12.0" + } + }, + "node_modules/is-unicode-supported": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-2.1.0.tgz", + "integrity": "sha512-mE00Gnza5EEB3Ds0HfMyllZzbBrmLOX3vfWoj9A9PEnTfratQ/BcaJOuMhnkhjXvb2+FkY3VuHqtAGpTPmglFQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/is-wsl": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/is-wsl/-/is-wsl-3.1.1.tgz", + "integrity": "sha512-e6rvdUCiQCAuumZslxRJWR/Doq4VpPR82kqclvcS0efgt430SlGIk05vdCN58+VrzgtIcfNODjozVielycD4Sw==", + "dev": true, + "license": "MIT", + "dependencies": { + "is-inside-container": "^1.0.0" + }, + "engines": { + "node": ">=16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/isarray": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/isarray/-/isarray-1.0.0.tgz", + "integrity": "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/istextorbinary": { + "version": "9.5.0", + "resolved": "https://registry.npmjs.org/istextorbinary/-/istextorbinary-9.5.0.tgz", + "integrity": "sha512-5mbUj3SiZXCuRf9fT3ibzbSSEWiy63gFfksmGfdOzujPjW3k+z8WvIBxcJHBoQNlaZaiyB25deviif2+osLmLw==", + "dev": true, + "license": "Artistic-2.0", + "dependencies": { + "binaryextensions": "^6.11.0", + "editions": "^6.21.0", + "textextensions": "^6.11.0" + }, + "engines": { + "node": ">=4" + }, + "funding": { + "url": "https://bevry.me/fund" + } + }, + "node_modules/js-tokens": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/js-tokens/-/js-tokens-4.0.0.tgz", + "integrity": "sha512-RdJUflcE3cUzKiMqQgsCu06FPu9UdIJO0beYbPhHN4k6apgJtifcoCtT9bcxOpYBtpD2kCM6Sbzg4CausW/PKQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/js-yaml": { + "version": "4.3.2", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-4.3.2.tgz", + "integrity": "sha512-SFNOvSJ+Dgf/9An904Yx+CgSlIPCkIpao4qo51lpee25TIRejdH3rhR4EZMGoNx3/TP3O+wzWuiTFl4sqbltzA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/puzrin" + }, + { + "type": "github", + "url": "https://github.com/sponsors/nodeca" + } + ], + "license": "MIT", + "dependencies": { + "argparse": "^2.0.1" + }, + "bin": { + "js-yaml": "bin/js-yaml.js" + } + }, + "node_modules/json-schema-traverse": { + "version": "1.0.0", + "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz", + "integrity": "sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==", + "dev": true, + "license": "MIT" + }, + "node_modules/json5": { + "version": "2.2.3", + "resolved": "https://registry.npmjs.org/json5/-/json5-2.2.3.tgz", + "integrity": "sha512-XmOWe7eyHYH14cLdVPoyg+GOH3rYX++KpzrylJwSW98t3Nk+U8XOl8FWKOgwtzdb8lXGf6zYwDUzeHMWfxasyg==", + "dev": true, + "license": "MIT", + "bin": { + "json5": "lib/cli.js" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/jsonc-parser": { + "version": "3.3.1", + "resolved": "https://registry.npmjs.org/jsonc-parser/-/jsonc-parser-3.3.1.tgz", + "integrity": "sha512-HUgH65KyejrUFPvHFPbqOY0rsFip3Bo5wb4ngvdi1EpCYWUQDC5V+Y7mZws+DLkr4M//zQJoanu1SP+87Dv1oQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/jsonfile": { + "version": "6.2.1", + "resolved": "https://registry.npmjs.org/jsonfile/-/jsonfile-6.2.1.tgz", + "integrity": "sha512-zwOTdL3rFQ/lRdBnntKVOX6k5cKJwEc1HdilT71BWEu7J41gXIB2MRp+vxduPSwZJPWBxEzv4yH1wYLJGUHX4Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "universalify": "^2.0.0" + }, + "optionalDependencies": { + "graceful-fs": "^4.1.6" + } + }, + "node_modules/jsonwebtoken": { + "version": "9.0.3", + "resolved": "https://registry.npmjs.org/jsonwebtoken/-/jsonwebtoken-9.0.3.tgz", + "integrity": "sha512-MT/xP0CrubFRNLNKvxJ2BYfy53Zkm++5bX9dtuPbqAeQpTVe0MQTFhao8+Cp//EmJp244xt6Drw/GVEGCUj40g==", + "dev": true, + "license": "MIT", + "dependencies": { + "jws": "^4.0.1", + "lodash.includes": "^4.3.0", + "lodash.isboolean": "^3.0.3", + "lodash.isinteger": "^4.0.4", + "lodash.isnumber": "^3.0.3", + "lodash.isplainobject": "^4.0.6", + "lodash.isstring": "^4.0.1", + "lodash.once": "^4.0.0", + "ms": "^2.1.1", + "semver": "^7.5.4" + }, + "engines": { + "node": ">=12", + "npm": ">=6" + } + }, + "node_modules/jszip": { + "version": "3.10.2", + "resolved": "https://registry.npmjs.org/jszip/-/jszip-3.10.2.tgz", + "integrity": "sha512-3l+rb15IOWtUhU0H5MFqES/T6Kh7abYwjosBey/vD6hDt8zoEffkSC5Ws5SGtgVw3gBx2NEbhTeSW1+kWkpyTQ==", + "dev": true, + "license": "(MIT OR GPL-3.0-or-later)", + "dependencies": { + "lie": "~3.3.0", + "pako": "~1.0.2", + "readable-stream": "~2.3.6", + "setimmediate": "^1.0.5" + } + }, + "node_modules/jwa": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/jwa/-/jwa-2.0.1.tgz", + "integrity": "sha512-hRF04fqJIP8Abbkq5NKGN0Bbr3JxlQ+qhZufXVr0DvujKy93ZCbXZMHDL4EOtodSbCWxOqR8MS1tXA5hwqCXDg==", + "dev": true, + "license": "MIT", + "dependencies": { + "buffer-equal-constant-time": "^1.0.1", + "ecdsa-sig-formatter": "1.0.11", + "safe-buffer": "^5.0.1" + } + }, + "node_modules/jws": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/jws/-/jws-4.0.1.tgz", + "integrity": "sha512-EKI/M/yqPncGUUh44xz0PxSidXFr/+r0pA70+gIYhjv+et7yxM+s29Y+VGDkovRofQem0fs7Uvf4+YmAdyRduA==", + "dev": true, + "license": "MIT", + "dependencies": { + "jwa": "^2.0.1", + "safe-buffer": "^5.0.1" + } + }, + "node_modules/keytar": { + "version": "7.9.0", + "resolved": "https://registry.npmjs.org/keytar/-/keytar-7.9.0.tgz", + "integrity": "sha512-VPD8mtVtm5JNtA2AErl6Chp06JBfy7diFQ7TQQhdpWOl6MrCRB+eRbvAZUsbGQS9kiMq0coJsy0W0vHpDCkWsQ==", + "dev": true, + "hasInstallScript": true, + "license": "MIT", + "optional": true, + "dependencies": { + "node-addon-api": "^4.3.0", + "prebuild-install": "^7.0.1" + } + }, + "node_modules/leven": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/leven/-/leven-3.1.0.tgz", + "integrity": "sha512-qsda+H8jTaUaN/x5vzW2rzc+8Rw4TAQ/4KjB46IwK5VH+IlVeeeje/EoZRpiXvIqjFgK84QffqPztGI3VBLG1A==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/lie": { + "version": "3.3.0", + "resolved": "https://registry.npmjs.org/lie/-/lie-3.3.0.tgz", + "integrity": "sha512-UaiMJzeWRlEujzAuw5LokY1L5ecNQYZKfmyZ9L7wDHb/p5etKaxXhohBcrw0EYby+G/NA52vRSN4N39dxHAIwQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "immediate": "~3.0.5" + } + }, + "node_modules/linkify-it": { + "version": "5.0.2", + "resolved": "https://registry.npmjs.org/linkify-it/-/linkify-it-5.0.2.tgz", + "integrity": "sha512-ONTm2jCMAVZjgQa/Fy1kScXsuOoF5NPTsoFBdE1KVIZ2vAh/r9+Bqo+0jINCBYnavTPQZz38QzFTme79ENoN3Q==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/puzrin" + }, + { + "type": "github", + "url": "https://github.com/sponsors/markdown-it" + } + ], + "license": "MIT", + "dependencies": { + "uc.micro": "^2.0.0" + } + }, + "node_modules/lodash": { + "version": "4.18.1", + "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.18.1.tgz", + "integrity": "sha512-dMInicTPVE8d1e5otfwmmjlxkZoUpiVLwyeTdUsi/Caj/gfzzblBcCE5sRHV/AsjuCmxWrte2TNGSYuCeCq+0Q==", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.includes": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/lodash.includes/-/lodash.includes-4.3.0.tgz", + "integrity": "sha512-W3Bx6mdkRTGtlJISOvVD/lbqjTlPPUDTMnlXZFnVwi9NKJ6tiAk6LVdlhZMm17VZisqhKcgzpO5Wz91PCt5b0w==", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.isboolean": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/lodash.isboolean/-/lodash.isboolean-3.0.3.tgz", + "integrity": "sha512-Bz5mupy2SVbPHURB98VAcw+aHh4vRV5IPNhILUCsOzRmsTmSQ17jIuqopAentWoehktxGd9e/hbIXq980/1QJg==", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.isinteger": { + "version": "4.0.4", + "resolved": "https://registry.npmjs.org/lodash.isinteger/-/lodash.isinteger-4.0.4.tgz", + "integrity": "sha512-DBwtEWN2caHQ9/imiNeEA5ys1JoRtRfY3d7V9wkqtbycnAmTvRRmbHKDV4a0EYc678/dia0jrte4tjYwVBaZUA==", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.isnumber": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/lodash.isnumber/-/lodash.isnumber-3.0.3.tgz", + "integrity": "sha512-QYqzpfwO3/CWf3XP+Z+tkQsfaLL/EnUlXWVkIk5FUPc4sBdTehEqZONuyRt2P67PXAk+NXmTBcc97zw9t1FQrw==", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.isplainobject": { + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/lodash.isplainobject/-/lodash.isplainobject-4.0.6.tgz", + "integrity": "sha512-oSXzaWypCMHkPC3NvBEaPHf0KsA5mvPrOPgQWDsbg8n7orZ290M0BmC/jgRZ4vcJ6DTAhjrsSYgdsW/F+MFOBA==", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.isstring": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/lodash.isstring/-/lodash.isstring-4.0.1.tgz", + "integrity": "sha512-0wJxfxH1wgO3GrbuP+dTTk7op+6L41QCXbGINEmD+ny/G/eCqGzxyCsh7159S+mgDDcoarnBw6PC1PS5+wUGgw==", + "dev": true, + "license": "MIT" + }, + "node_modules/lodash.once": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lodash.once/-/lodash.once-4.1.1.tgz", + "integrity": "sha512-Sb487aTOCr9drQVL8pIxOzVhafOjZN9UU54hiN8PU3uAiSV7lx1yYNpbNmex2PK6dSJoNTSJUUswT651yww3Mg==", + "dev": true, + "license": "MIT" + }, + "node_modules/log-symbols": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/log-symbols/-/log-symbols-6.0.0.tgz", + "integrity": "sha512-i24m8rpwhmPIS4zscNzK6MSEhk0DUWa/8iYQWxhffV8jkI4Phvs3F+quL5xvS0gdQR0FyTCMMH33Y78dDTzzIw==", + "dev": true, + "license": "MIT", + "dependencies": { + "chalk": "^5.3.0", + "is-unicode-supported": "^1.3.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/log-symbols/node_modules/chalk": { + "version": "5.6.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.6.2.tgz", + "integrity": "sha512-7NzBL0rN6fMUW+f7A6Io4h40qQlG+xGmtMxfbnH/K7TAtt8JQWVQK+6g0UXKMeVJoyV5EkkNsErQ8pVD3bLHbA==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^12.17.0 || ^14.13 || >=16.0.0" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/log-symbols/node_modules/is-unicode-supported": { + "version": "1.3.0", + "resolved": "https://registry.npmjs.org/is-unicode-supported/-/is-unicode-supported-1.3.0.tgz", + "integrity": "sha512-43r2mRvz+8JRIKnWJ+3j8JtjRKZ6GmjzfaE/qiBJnikNnYv/6bagRJ1kUhNk8R5EX/GkobD+r+sfxCPJsiKBLQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/lru-cache": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-6.0.0.tgz", + "integrity": "sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==", + "dev": true, + "license": "ISC", + "dependencies": { + "yallist": "^4.0.0" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/markdown-it": { + "version": "14.3.3", + "resolved": "https://registry.npmjs.org/markdown-it/-/markdown-it-14.3.3.tgz", + "integrity": "sha512-L//tDAkjTjJCU6pBUSBTgs3Kg4InVaZuUZog/b6V12UKhcDQ7S78877ibbCanRExwPuYP1CZD7Gd2dxSy1GXRg==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/puzrin" + }, + { + "type": "github", + "url": "https://github.com/sponsors/markdown-it" + } + ], + "license": "MIT", + "dependencies": { + "argparse": "^2.0.1", + "entities": "^4.5.0", + "linkify-it": "^5.0.2", + "mdurl": "^2.0.0", + "punycode.js": "^2.3.1", + "uc.micro": "^2.1.0" + }, + "bin": { + "markdown-it": "bin/markdown-it.mjs" + } + }, + "node_modules/math-intrinsics": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/math-intrinsics/-/math-intrinsics-1.1.0.tgz", + "integrity": "sha512-/IXtbwEk5HTPyEwyKX6hGkYXxM9nbj64B+ilVJnC/R6B0pH5G4V3b0pVbL7DBj4tkhBAppbQUlf6F6Xl9LHu1g==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + } + }, + "node_modules/mdurl": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/mdurl/-/mdurl-2.1.0.tgz", + "integrity": "sha512-1+HBaOx0zi/dQWht8rNv9MYf9qqpqL/kxI0hXImU6Y547zM6Sni8BQibt7ifgMcYtQg41ao3Ivd6cnSM86inpg==", + "dev": true, + "license": "MIT" + }, + "node_modules/merge2": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/merge2/-/merge2-1.4.1.tgz", + "integrity": "sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 8" + } + }, + "node_modules/micromatch": { + "version": "4.0.8", + "resolved": "https://registry.npmjs.org/micromatch/-/micromatch-4.0.8.tgz", + "integrity": "sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==", + "dev": true, + "license": "MIT", + "dependencies": { + "braces": "^3.0.3", + "picomatch": "^2.3.1" + }, + "engines": { + "node": ">=8.6" + } + }, + "node_modules/mime": { + "version": "1.6.0", + "resolved": "https://registry.npmjs.org/mime/-/mime-1.6.0.tgz", + "integrity": "sha512-x0Vn8spI+wuJ1O6S7gnbaQg8Pxh4NNHb7KSINmEWKiPE4RKOplvijn+NkmYmmRgP68mc70j2EbeTFRsrswaQeg==", + "dev": true, + "license": "MIT", + "bin": { + "mime": "cli.js" + }, + "engines": { + "node": ">=4" + } + }, + "node_modules/mime-db": { + "version": "1.52.0", + "resolved": "https://registry.npmjs.org/mime-db/-/mime-db-1.52.0.tgz", + "integrity": "sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mime-types": { + "version": "2.1.35", + "resolved": "https://registry.npmjs.org/mime-types/-/mime-types-2.1.35.tgz", + "integrity": "sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==", + "dev": true, + "license": "MIT", + "dependencies": { + "mime-db": "1.52.0" + }, + "engines": { + "node": ">= 0.6" + } + }, + "node_modules/mimic-function": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/mimic-function/-/mimic-function-5.0.1.tgz", + "integrity": "sha512-VP79XUPxV2CigYP3jWwAUFSku2aKqBH7uTAapFWCBqutsbmDo96KY5o8uh6U+/YSIn5OxJnXp73beVkpqMIGhA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/mimic-response": { + "version": "3.1.0", + "resolved": "https://registry.npmjs.org/mimic-response/-/mimic-response-3.1.0.tgz", + "integrity": "sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ==", + "dev": true, + "license": "MIT", + "optional": true, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/minimatch": { + "version": "10.2.6", + "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-10.2.6.tgz", + "integrity": "sha512-vpLQEs+VLCr1nU0BXS07maYoFwlDAH0gngQuuttxIwutDFEMHq2blX+8vpgxDdK3J1PwjCJiep77OitTZ4Ll1A==", + "dev": true, + "license": "BlueOak-1.0.0", + "dependencies": { + "brace-expansion": "^5.0.8" + }, + "engines": { + "node": "18 || 20 || >=22" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/minimist": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.8.tgz", + "integrity": "sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==", + "dev": true, + "license": "MIT", + "optional": true, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/minipass": { + "version": "7.1.3", + "resolved": "https://registry.npmjs.org/minipass/-/minipass-7.1.3.tgz", + "integrity": "sha512-tEBHqDnIoM/1rXME1zgka9g6Q2lcoCkxHLuc7ODJ5BxbP5d4c2Z5cGgtXAku59200Cx7diuHTOYfSBD8n6mm8A==", + "dev": true, + "license": "BlueOak-1.0.0", + "engines": { + "node": ">=16 || 14 >=14.17" + } + }, + "node_modules/mkdirp-classic": { + "version": "0.5.3", + "resolved": "https://registry.npmjs.org/mkdirp-classic/-/mkdirp-classic-0.5.3.tgz", + "integrity": "sha512-gKLcREMhtuZRwRAfqP3RFW+TK4JqApVBtOIftVgjuABpAtpxhPGaDcfvbhNvD0B8iD1oUr/txX35NjcaY6Ns/A==", + "dev": true, + "license": "MIT", + "optional": true + }, + "node_modules/ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", + "dev": true, + "license": "MIT" + }, + "node_modules/mute-stream": { + "version": "0.0.8", + "resolved": "https://registry.npmjs.org/mute-stream/-/mute-stream-0.0.8.tgz", + "integrity": "sha512-nnbWWOkoWyUsTjKrhgD0dcz22mdkSnpYqbEjIm2nhwhuxlSkpywJmBo8h0ZqJdkp73mb90SssHkN4rsRaBAfAA==", + "dev": true, + "license": "ISC" + }, + "node_modules/napi-build-utils": { + "version": "2.0.0", + "resolved": "https://registry.npmjs.org/napi-build-utils/-/napi-build-utils-2.0.0.tgz", + "integrity": "sha512-GEbrYkbfF7MoNaoh2iGG84Mnf/WZfB0GdGEsM8wz7Expx/LlWf5U8t9nvJKXSp3qr5IsEbK04cBGhol/KwOsWA==", + "dev": true, + "license": "MIT", + "optional": true + }, + "node_modules/node-abi": { + "version": "3.104.0", + "resolved": "https://registry.npmjs.org/node-abi/-/node-abi-3.104.0.tgz", + "integrity": "sha512-J2lVAHTQ8v1J7hl2k1eX70d/Fm+HE1EyUes2dOew59JgBlAW6NB7DABI8kdrgRPehhepJd18p1ivekA8BF7AOg==", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "semver": "^7.3.5" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/node-addon-api": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/node-addon-api/-/node-addon-api-4.3.0.tgz", + "integrity": "sha512-73sE9+3UaLYYFmDsFZnqCInzPyh3MqIwZO9cw58yIqAZhONrrabrYyYe3TuIqtIiOuTXVhsGau8hcrhhwSsDIQ==", + "dev": true, + "license": "MIT", + "optional": true + }, + "node_modules/node-sarif-builder": { + "version": "3.4.0", + "resolved": "https://registry.npmjs.org/node-sarif-builder/-/node-sarif-builder-3.4.0.tgz", + "integrity": "sha512-tGnJW6OKRii9u/b2WiUViTJS+h7Apxx17qsMUjsUeNDiMMX5ZFf8F8Fcz7PAQ6omvOxHZtvDTmOYKJQwmfpjeg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/sarif": "^2.1.7", + "fs-extra": "^11.1.1" + }, + "engines": { + "node": ">=20" + } + }, + "node_modules/normalize-package-data": { + "version": "6.0.2", + "resolved": "https://registry.npmjs.org/normalize-package-data/-/normalize-package-data-6.0.2.tgz", + "integrity": "sha512-V6gygoYb/5EmNI+MEGrWkC+e6+Rr7mTmfHrxDbLzxQogBkgzo76rkok0Am6thgSF7Mv2nLOajAJj5vDJZEFn7g==", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "hosted-git-info": "^7.0.0", + "semver": "^7.3.5", + "validate-npm-package-license": "^3.0.4" + }, + "engines": { + "node": "^16.14.0 || >=18.0.0" + } + }, + "node_modules/normalize-package-data/node_modules/hosted-git-info": { + "version": "7.0.2", + "resolved": "https://registry.npmjs.org/hosted-git-info/-/hosted-git-info-7.0.2.tgz", + "integrity": "sha512-puUZAUKT5m8Zzvs72XWy3HtvVbTWljRE66cP60bxJzAqf2DgICo7lYTY2IHUmLnNpjYvw5bvmoHvPc0QO2a62w==", + "dev": true, + "license": "ISC", + "dependencies": { + "lru-cache": "^10.0.1" + }, + "engines": { + "node": "^16.14.0 || >=18.0.0" + } + }, + "node_modules/normalize-package-data/node_modules/lru-cache": { + "version": "10.4.3", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-10.4.3.tgz", + "integrity": "sha512-JNAzZcXrCt42VGLuYz0zfAzDfAvJWW6AfYlDBQyDV5DClI2m5sAmK+OIO7s59XfsRsWHp02jAJrRadPRGTt6SQ==", + "dev": true, + "license": "ISC" + }, + "node_modules/nth-check": { + "version": "2.1.1", + "resolved": "https://registry.npmjs.org/nth-check/-/nth-check-2.1.1.tgz", + "integrity": "sha512-lqjrjmaOoAnWfMmBPL+XNnynZh2+swxiX3WUE0s4yEHI6m+AwrK2UZOimIRl3X/4QctVqS8AiZjFqyOGrMXb/w==", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "boolbase": "^1.0.0" + }, + "funding": { + "url": "https://github.com/fb55/nth-check?sponsor=1" + } + }, + "node_modules/object-inspect": { + "version": "1.14.0", + "resolved": "https://registry.npmjs.org/object-inspect/-/object-inspect-1.14.0.tgz", + "integrity": "sha512-IVgHNlp/jwQX271+Xzoq9LZNTWXxZK+cEOrGBOBxXNbn7fapnZ+Ts6TVMgNOuAezwG2wdtnMX97tTPK6VEnuOQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/once": { + "version": "1.4.0", + "resolved": "https://registry.npmjs.org/once/-/once-1.4.0.tgz", + "integrity": "sha512-lNaJgI+2Q5URQBkccEKHTQOPaXdUxnZZElQTZY0MFUAuaEqe1E+Nyvgdz/aIyNi6Z9MzO5dv1H8n58/GELp3+w==", + "dev": true, + "license": "ISC", + "optional": true, + "dependencies": { + "wrappy": "1" + } + }, + "node_modules/onetime": { + "version": "7.0.0", + "resolved": "https://registry.npmjs.org/onetime/-/onetime-7.0.0.tgz", + "integrity": "sha512-VXJjc87FScF88uafS3JllDgvAm+c/Slfz06lorj2uAY34rlUu0Nt+v8wreiImcrgAjjIHp1rXpTDlLOGw29WwQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "mimic-function": "^5.0.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/open": { + "version": "11.0.4", + "resolved": "https://registry.npmjs.org/open/-/open-11.0.4.tgz", + "integrity": "sha512-++Zlftm0kVLPmzC06t6epuWmcRMDbI4z5P3NNX979WA/k23+NtSOynEGzsVfZwguKw2mi5umVgnBlJQMwRz4Pg==", + "dev": true, + "license": "MIT", + "dependencies": { + "default-browser": "^5.5.1", + "define-lazy-prop": "^3.0.0", + "is-in-ssh": "^1.0.0", + "is-inside-container": "^1.0.0", + "powershell-utils": "^0.2.1", + "wsl-utils": "^1.0.0" + }, + "engines": { + "node": ">=20" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/ora": { + "version": "8.2.0", + "resolved": "https://registry.npmjs.org/ora/-/ora-8.2.0.tgz", + "integrity": "sha512-weP+BZ8MVNnlCm8c0Qdc1WSWq4Qn7I+9CJGm7Qali6g44e/PUzbjNqJX5NJ9ljlNMosfJvg1fKEGILklK9cwnw==", + "dev": true, + "license": "MIT", + "dependencies": { + "chalk": "^5.3.0", + "cli-cursor": "^5.0.0", + "cli-spinners": "^2.9.2", + "is-interactive": "^2.0.0", + "is-unicode-supported": "^2.0.0", + "log-symbols": "^6.0.0", + "stdin-discarder": "^0.2.2", + "string-width": "^7.2.0", + "strip-ansi": "^7.1.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/ora/node_modules/chalk": { + "version": "5.6.2", + "resolved": "https://registry.npmjs.org/chalk/-/chalk-5.6.2.tgz", + "integrity": "sha512-7NzBL0rN6fMUW+f7A6Io4h40qQlG+xGmtMxfbnH/K7TAtt8JQWVQK+6g0UXKMeVJoyV5EkkNsErQ8pVD3bLHbA==", + "dev": true, + "license": "MIT", + "engines": { + "node": "^12.17.0 || ^14.13 || >=16.0.0" + }, + "funding": { + "url": "https://github.com/chalk/chalk?sponsor=1" + } + }, + "node_modules/ora/node_modules/emoji-regex": { + "version": "10.6.0", + "resolved": "https://registry.npmjs.org/emoji-regex/-/emoji-regex-10.6.0.tgz", + "integrity": "sha512-toUI84YS5YmxW219erniWD0CIVOo46xGKColeNQRgOzDorgBi1v4D71/OFzgD9GO2UGKIv1C3Sp8DAn0+j5w7A==", + "dev": true, + "license": "MIT" + }, + "node_modules/ora/node_modules/string-width": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-7.2.0.tgz", + "integrity": "sha512-tsaTIkKW9b4N+AEj+SVA+WhJzV7/zMhcSu78mLKWSk7cXMOSHsBKFWUs0fWwq8QyK3MgJBQRX6Gbi4kYbdvGkQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "emoji-regex": "^10.3.0", + "get-east-asian-width": "^1.0.0", + "strip-ansi": "^7.1.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/p-map": { + "version": "7.1.1", + "resolved": "https://registry.npmjs.org/p-map/-/p-map-7.1.1.tgz", + "integrity": "sha512-6Lh3jQPLthYujSrlw6ccWXBGZTkoTCz27Hd92g79LH/kjAbgoEu0t442cCCNbegPSJsA0lwDX8z0bcKtkpA32g==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/pako": { + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/pako/-/pako-1.0.11.tgz", + "integrity": "sha512-4hLB8Py4zZce5s4yd9XzopqwVv/yGNhV1Bl8NTmCq1763HeK2+EwVTv+leGeL13Dnh2wfbqowVPXCIO0z4taYw==", + "dev": true, + "license": "(MIT AND Zlib)" + }, + "node_modules/parse-json": { + "version": "8.3.0", + "resolved": "https://registry.npmjs.org/parse-json/-/parse-json-8.3.0.tgz", + "integrity": "sha512-ybiGyvspI+fAoRQbIPRddCcSTV9/LsJbf0e/S85VLowVGzRmokfneg2kwVW/KU5rOXrPSbF1qAKPMgNTqqROQQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "@babel/code-frame": "^7.26.2", + "index-to-position": "^1.1.0", + "type-fest": "^4.39.1" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/parse-semver": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/parse-semver/-/parse-semver-1.1.1.tgz", + "integrity": "sha512-Eg1OuNntBMH0ojvEKSrvDSnwLmvVuUOSdylH/pSCPNMIspLlweJyIWXCE+k/5hm3cj/EBUYwmWkjhBALNP4LXQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "semver": "^5.1.0" + } + }, + "node_modules/parse-semver/node_modules/semver": { + "version": "5.7.3", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.3.tgz", + "integrity": "sha512-kM18BPOqTi0+TB68703/GJRpAML5Me+IDQsR1J26YB3EFKKNEyHIVZuWDX7+WKQB3tHwDwgk24BfhdpWUbytvQ==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver" + } + }, + "node_modules/parse5": { + "version": "7.3.0", + "resolved": "https://registry.npmjs.org/parse5/-/parse5-7.3.0.tgz", + "integrity": "sha512-IInvU7fabl34qmi9gY8XOVxhYyMyuH2xUNpb2q8/Y+7552KlejkRvqvD19nMoUW/uQGGbqNpA6Tufu5FL5BZgw==", + "dev": true, + "license": "MIT", + "dependencies": { + "entities": "^6.0.0" + }, + "funding": { + "url": "https://github.com/inikulin/parse5?sponsor=1" + } + }, + "node_modules/parse5-htmlparser2-tree-adapter": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/parse5-htmlparser2-tree-adapter/-/parse5-htmlparser2-tree-adapter-7.1.0.tgz", + "integrity": "sha512-ruw5xyKs6lrpo9x9rCZqZZnIUntICjQAd0Wsmp396Ul9lN/h+ifgVV1x1gZHi8euej6wTfpqX8j+BFQxF0NS/g==", + "dev": true, + "license": "MIT", + "dependencies": { + "domhandler": "^5.0.3", + "parse5": "^7.0.0" + }, + "funding": { + "url": "https://github.com/inikulin/parse5?sponsor=1" + } + }, + "node_modules/parse5-parser-stream": { + "version": "7.1.2", + "resolved": "https://registry.npmjs.org/parse5-parser-stream/-/parse5-parser-stream-7.1.2.tgz", + "integrity": "sha512-JyeQc9iwFLn5TbvvqACIF/VXG6abODeB3Fwmv/TGdLk2LfbWkaySGY72at4+Ty7EkPZj854u4CrICqNk2qIbow==", + "dev": true, + "license": "MIT", + "dependencies": { + "parse5": "^7.0.0" + }, + "funding": { + "url": "https://github.com/inikulin/parse5?sponsor=1" + } + }, + "node_modules/parse5/node_modules/entities": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/entities/-/entities-6.0.1.tgz", + "integrity": "sha512-aN97NXWF6AWBTahfVOIrB/NShkzi5H7F9r1s9mD3cDj4Ko5f2qhhVoYMibXF7GlLveb/D2ioWay8lxI97Ven3g==", + "dev": true, + "license": "BSD-2-Clause", + "engines": { + "node": ">=0.12" + }, + "funding": { + "url": "https://github.com/fb55/entities?sponsor=1" + } + }, + "node_modules/path-scurry": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/path-scurry/-/path-scurry-2.0.2.tgz", + "integrity": "sha512-3O/iVVsJAPsOnpwWIeD+d6z/7PmqApyQePUtCndjatj/9I5LylHvt5qluFaBT3I5h3r1ejfR056c+FCv+NnNXg==", + "dev": true, + "license": "BlueOak-1.0.0", + "dependencies": { + "lru-cache": "^11.0.0", + "minipass": "^7.1.2" + }, + "engines": { + "node": "18 || 20 || >=22" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/path-scurry/node_modules/lru-cache": { + "version": "11.5.3", + "resolved": "https://registry.npmjs.org/lru-cache/-/lru-cache-11.5.3.tgz", + "integrity": "sha512-U4N8FgzmWxc8k1VH8Kr6lQg18U7Fjvby6wXHVRX/ZZ7IwWbRMgrRbP0Wrb5q5NVinryp4SQampHKdvtecItxUg==", + "dev": true, + "license": "BlueOak-1.0.0", + "engines": { + "node": "20 || >=22" + } + }, + "node_modules/path-type": { + "version": "6.0.0", + "resolved": "https://registry.npmjs.org/path-type/-/path-type-6.0.0.tgz", + "integrity": "sha512-Vj7sf++t5pBD637NSfkxpHSMfWaeig5+DKWLhcqIYx6mWQz5hdJTGDVMQiJcw1ZYkhs7AazKDGpRVji1LJCZUQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/pend": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/pend/-/pend-1.2.0.tgz", + "integrity": "sha512-F3asv42UuXchdzt+xXqfW1OGlVBe+mxa2mqI0pg5yAHZPvFmY3Y6drSf/GQ1A86WgWEN9Kzh/WrgKa6iGcHXLg==", + "dev": true, + "license": "MIT" + }, + "node_modules/picocolors": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/picocolors/-/picocolors-1.1.1.tgz", + "integrity": "sha512-xceH2snhtb5M9liqDsmEw56le376mTZkEX/jEb/RxNFyegNul7eNslCXP9FDj/Lcu0X8KEyMceP2ntpaHrDEVA==", + "dev": true, + "license": "ISC" + }, + "node_modules/picomatch": { + "version": "2.3.2", + "resolved": "https://registry.npmjs.org/picomatch/-/picomatch-2.3.2.tgz", + "integrity": "sha512-V7+vQEJ06Z+c5tSye8S+nHUfI51xoXIXjHQ99cQtKUkQqqO1kO/KCJUfZXuB47h/YBlDhah2H3hdUGXn8ie0oA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8.6" + }, + "funding": { + "url": "https://github.com/sponsors/jonschlinkert" + } + }, + "node_modules/pluralize": { + "version": "8.0.0", + "resolved": "https://registry.npmjs.org/pluralize/-/pluralize-8.0.0.tgz", + "integrity": "sha512-Nc3IT5yHzflTfbjgqWcCPpo7DaKy4FnpB0l/zCAW0Tc7jxAiuqSxHasntB3D7887LSrA93kDJ9IXovxJYxyLCA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4" + } + }, + "node_modules/powershell-utils": { + "version": "0.2.1", + "resolved": "https://registry.npmjs.org/powershell-utils/-/powershell-utils-0.2.1.tgz", + "integrity": "sha512-C+y9x90UElAddDZmV4qOx9W53B61PO7cIqWz2dQsWlwswuq4mr8NEwytdGKboYbQlGZ3awrkTeNvcZiZNHnQ8A==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=20" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/prebuild-install": { + "version": "7.1.3", + "resolved": "https://registry.npmjs.org/prebuild-install/-/prebuild-install-7.1.3.tgz", + "integrity": "sha512-8Mf2cbV7x1cXPUILADGI3wuhfqWvtiLA1iclTDbFRZkgRQS0NqsPZphna9V+HyTEadheuPmjaJMsbzKQFOzLug==", + "deprecated": "No longer maintained. Please contact the author of the relevant native addon; alternatives are available.", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "detect-libc": "^2.0.0", + "expand-template": "^2.0.3", + "github-from-package": "0.0.0", + "minimist": "^1.2.3", + "mkdirp-classic": "^0.5.3", + "napi-build-utils": "^2.0.0", + "node-abi": "^3.3.0", + "pump": "^3.0.0", + "rc": "^1.2.7", + "simple-get": "^4.0.0", + "tar-fs": "^2.0.0", + "tunnel-agent": "^0.6.0" + }, + "bin": { + "prebuild-install": "bin.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/process-nextick-args": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/process-nextick-args/-/process-nextick-args-2.0.1.tgz", + "integrity": "sha512-3ouUOpQhtgrbOa17J7+uxOTpITYWaGP7/AhoR3+A+/1e9skrzelGi/dXzEYyvbxubEF6Wn2ypscTKiKJFFn1ag==", + "dev": true, + "license": "MIT" + }, + "node_modules/pump": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/pump/-/pump-3.0.4.tgz", + "integrity": "sha512-VS7sjc6KR7e1ukRFhQSY5LM2uBWAUPiOPa/A3mkKmiMwSmRFUITt0xuj+/lesgnCv+dPIEYlkzrcyXgquIHMcA==", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "end-of-stream": "^1.1.0", + "once": "^1.3.1" + } + }, + "node_modules/punycode.js": { + "version": "2.3.1", + "resolved": "https://registry.npmjs.org/punycode.js/-/punycode.js-2.3.1.tgz", + "integrity": "sha512-uxFIHU0YlHYhDQtV4R9J6a52SLx28BCjT+4ieh7IGbgwVJWO+km431c4yRlREUAsAmt/uMjQUyQHNEPf0M39CA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=6" + } + }, + "node_modules/qs": { + "version": "6.17.1", + "resolved": "https://registry.npmjs.org/qs/-/qs-6.17.1.tgz", + "integrity": "sha512-jd3COkaKVgGUW+ZHyEHCG9bH7RoaaiWuMgzsIBjUMVjLAaWGWpoUAVwljVvBHxRu/2qEHnadLGZrkutYUBPQJA==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "es-define-property": "^1.0.1", + "side-channel": "^1.1.1" + }, + "engines": { + "node": ">=0.6" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/queue-microtask": { + "version": "1.2.3", + "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", + "integrity": "sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT" + }, + "node_modules/rc": { + "version": "1.2.8", + "resolved": "https://registry.npmjs.org/rc/-/rc-1.2.8.tgz", + "integrity": "sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw==", + "dev": true, + "license": "(BSD-2-Clause OR MIT OR Apache-2.0)", + "optional": true, + "dependencies": { + "deep-extend": "^0.6.0", + "ini": "~1.3.0", + "minimist": "^1.2.0", + "strip-json-comments": "~2.0.1" + }, + "bin": { + "rc": "cli.js" + } + }, + "node_modules/rc-config-loader": { + "version": "4.2.0", + "resolved": "https://registry.npmjs.org/rc-config-loader/-/rc-config-loader-4.2.0.tgz", + "integrity": "sha512-PoQabZw5RBxSW9jJhI1WJ8hpLYCjF4PrkhqkkjXYKRpWTo1cn3ovdXku2spdS79dnD3pT/axXeEUnwbG8qxz9A==", + "dev": true, + "license": "MIT", + "dependencies": { + "debug": "^4.4.3", + "js-yaml": "^5.5.0", + "json5": "^2.2.3", + "require-from-string": "^2.0.2" + } + }, + "node_modules/rc-config-loader/node_modules/argparse": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/argparse/-/argparse-3.0.4.tgz", + "integrity": "sha512-fwWK3Zq22l4XJJjx5mcBHGikIk+hJqO+32dPm0Jur7+rtG5x1scOjSfdT9ZKeWHPpsya/l0HHK4tDImBkTrtvA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/puzrin" + }, + { + "type": "github", + "url": "https://github.com/sponsors/nodeca" + } + ], + "license": "PSF-2.0" + }, + "node_modules/rc-config-loader/node_modules/js-yaml": { + "version": "5.5.0", + "resolved": "https://registry.npmjs.org/js-yaml/-/js-yaml-5.5.0.tgz", + "integrity": "sha512-paNr4LFIFPjeeSmwNYdrb8FafLLG/Cr2Af3GjbsHJ5CxIjH4r0c2emlmRdAtpPAieP1gRVzk6buBbVP5gBMGAg==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/puzrin" + }, + { + "type": "github", + "url": "https://github.com/sponsors/nodeca" + } + ], + "license": "MIT", + "dependencies": { + "argparse": "^3.0.3" + }, + "bin": { + "js-yaml": "bin/js-yaml.mjs" + } + }, + "node_modules/read": { + "version": "1.0.7", + "resolved": "https://registry.npmjs.org/read/-/read-1.0.7.tgz", + "integrity": "sha512-rSOKNYUmaxy0om1BNjMN4ezNT6VKK+2xF4GBhc81mkH7L60i6dp8qPYrkndNLT3QPphoII3maL9PVC9XmhHwVQ==", + "dev": true, + "license": "ISC", + "dependencies": { + "mute-stream": "~0.0.4" + }, + "engines": { + "node": ">=0.8" + } + }, + "node_modules/read-pkg": { + "version": "9.0.1", + "resolved": "https://registry.npmjs.org/read-pkg/-/read-pkg-9.0.1.tgz", + "integrity": "sha512-9viLL4/n1BJUCT1NXVTdS1jtm80yDEgR5T4yCelII49Mbj0v1rZdKqj7zCiYdbB0CuCgdrvHcNogAKTFPBocFA==", + "dev": true, + "license": "MIT", + "dependencies": { + "@types/normalize-package-data": "^2.4.3", + "normalize-package-data": "^6.0.0", + "parse-json": "^8.0.0", + "type-fest": "^4.6.0", + "unicorn-magic": "^0.1.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/read-pkg/node_modules/unicorn-magic": { + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/unicorn-magic/-/unicorn-magic-0.1.0.tgz", + "integrity": "sha512-lRfVq8fE8gz6QMBuDM6a+LO3IAzTi05H6gCVaUpir2E1Rwpo4ZUog45KpNXKC/Mn3Yb9UDuHumeFTo9iV/D9FQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/readable-stream": { + "version": "2.3.8", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-2.3.8.tgz", + "integrity": "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA==", + "dev": true, + "license": "MIT", + "dependencies": { + "core-util-is": "~1.0.0", + "inherits": "~2.0.3", + "isarray": "~1.0.0", + "process-nextick-args": "~2.0.0", + "safe-buffer": "~5.1.1", + "string_decoder": "~1.1.1", + "util-deprecate": "~1.0.1" + } + }, + "node_modules/readable-stream/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", + "dev": true, + "license": "MIT" + }, + "node_modules/require-from-string": { + "version": "2.0.2", + "resolved": "https://registry.npmjs.org/require-from-string/-/require-from-string-2.0.2.tgz", + "integrity": "sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/restore-cursor": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/restore-cursor/-/restore-cursor-5.1.0.tgz", + "integrity": "sha512-oMA2dcrw6u0YfxJQXm342bFKX/E4sG9rbTzO9ptUcR/e8A33cHuvStiYOwH7fszkZlZ1z/ta9AAoPk2F4qIOHA==", + "dev": true, + "license": "MIT", + "dependencies": { + "onetime": "^7.0.0", + "signal-exit": "^4.1.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/reusify": { + "version": "1.1.0", + "resolved": "https://registry.npmjs.org/reusify/-/reusify-1.1.0.tgz", + "integrity": "sha512-g6QUff04oZpHs0eG5p83rFLhHeV00ug/Yf9nZM6fLeUrPguBTkTQOdpAWWspMh55TZfVQDPaN3NQJfbVRAxdIw==", + "dev": true, + "license": "MIT", + "engines": { + "iojs": ">=1.0.0", + "node": ">=0.10.0" + } + }, + "node_modules/run-applescript": { + "version": "7.1.0", + "resolved": "https://registry.npmjs.org/run-applescript/-/run-applescript-7.1.0.tgz", + "integrity": "sha512-DPe5pVFaAsinSaV6QjQ6gdiedWDcRCbUuiQfQa2wmWV7+xC9bGulGI8+TdRmoFkAPaBXk8CrAbnlY2ISniJ47Q==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/run-parallel": { + "version": "1.2.0", + "resolved": "https://registry.npmjs.org/run-parallel/-/run-parallel-1.2.0.tgz", + "integrity": "sha512-5l4VyZR86LZ/lDxZTR6jqL8AFE2S0IFLMP26AbjsLVADxHdhB/c0GUsH+y39UfCi3dzz8OlQuPmnaJOMoDHQBA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "dependencies": { + "queue-microtask": "^1.2.2" + } + }, + "node_modules/safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT" + }, + "node_modules/safer-buffer": { + "version": "2.1.2", + "resolved": "https://registry.npmjs.org/safer-buffer/-/safer-buffer-2.1.2.tgz", + "integrity": "sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==", + "dev": true, + "license": "MIT" + }, + "node_modules/sax": { + "version": "1.6.1", + "resolved": "https://registry.npmjs.org/sax/-/sax-1.6.1.tgz", + "integrity": "sha512-42tBVwLWnaQvW5zc4HbZrTuWccECCZfBi92FDuwtqxasH+JbPB3/FOKb1m222K42R4WxuxzzMsTswfzgtSu64Q==", + "dev": true, + "license": "BlueOak-1.0.0", + "engines": { + "node": ">=11.0.0" + } + }, + "node_modules/secretlint": { + "version": "10.2.2", + "resolved": "https://registry.npmjs.org/secretlint/-/secretlint-10.2.2.tgz", + "integrity": "sha512-xVpkeHV/aoWe4vP4TansF622nBEImzCY73y/0042DuJ29iKIaqgoJ8fGxre3rVSHHbxar4FdJobmTnLp9AU0eg==", + "dev": true, + "license": "MIT", + "dependencies": { + "@secretlint/config-creator": "^10.2.2", + "@secretlint/formatter": "^10.2.2", + "@secretlint/node": "^10.2.2", + "@secretlint/profiler": "^10.2.2", + "debug": "^4.4.1", + "globby": "^14.1.0", + "read-pkg": "^9.0.1" + }, + "bin": { + "secretlint": "bin/secretlint.js" + }, + "engines": { + "node": ">=20.0.0" + } + }, + "node_modules/semver": { + "version": "7.8.6", + "resolved": "https://registry.npmjs.org/semver/-/semver-7.8.6.tgz", + "integrity": "sha512-9lpSSU4Mly3mrtruwLs1eLK6+gzbzqeBFwRNjIjE+9LuDpWdYctrQlQ3ej1Ilgi7gknpsTRnPoLP8DpCHqHIJw==", + "dev": true, + "license": "ISC", + "bin": { + "semver": "bin/semver.js" + }, + "engines": { + "node": ">=10" + } + }, + "node_modules/setimmediate": { + "version": "1.0.5", + "resolved": "https://registry.npmjs.org/setimmediate/-/setimmediate-1.0.5.tgz", + "integrity": "sha512-MATJdZp8sLqDl/68LfQmbP8zKPLQNV6BIZoIgrscFDQ+RsvK/BxeDQOgyxKKoh0y/8h3BqVFnCqQ/gd+reiIXA==", + "dev": true, + "license": "MIT" + }, + "node_modules/side-channel": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/side-channel/-/side-channel-1.1.1.tgz", + "integrity": "sha512-6x6dK6zJdpTzF4sQeNYxwtvBzf6Eg4GtlesS94HOvTudUeyK2WXAaIfmDgsyslYrRBeFIlsi54AYsFGUuhmvrQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "object-inspect": "^1.13.4", + "side-channel-list": "^1.0.1", + "side-channel-map": "^1.0.1", + "side-channel-weakmap": "^1.0.2" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-list": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/side-channel-list/-/side-channel-list-1.0.1.tgz", + "integrity": "sha512-mjn/0bi/oUURjc5Xl7IaWi/OJJJumuoJFQJfDDyO46+hBWsfaVM65TBHq2eoZBhzl9EchxOijpkbRC8SVBQU0w==", + "dev": true, + "license": "MIT", + "dependencies": { + "es-errors": "^1.3.0", + "object-inspect": "^1.13.4" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-map": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/side-channel-map/-/side-channel-map-1.0.1.tgz", + "integrity": "sha512-VCjCNfgMsby3tTdo02nbjtM/ewra6jPHmpThenkTYh8pG9ucZ/1P8So4u4FGBek/BjpOVsDCMoLA/iuBKIFXRA==", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.5", + "object-inspect": "^1.13.3" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/side-channel-weakmap": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/side-channel-weakmap/-/side-channel-weakmap-1.0.2.tgz", + "integrity": "sha512-WPS/HvHQTYnHisLo9McqBHOJk2FkHO/tlpvldyrnem4aeQp4hai3gythswg6p01oSoTl58rcpiFAjF2br2Ak2A==", + "dev": true, + "license": "MIT", + "dependencies": { + "call-bound": "^1.0.2", + "es-errors": "^1.3.0", + "get-intrinsic": "^1.2.5", + "object-inspect": "^1.13.3", + "side-channel-map": "^1.0.1" + }, + "engines": { + "node": ">= 0.4" + }, + "funding": { + "url": "https://github.com/sponsors/ljharb" + } + }, + "node_modules/signal-exit": { + "version": "4.1.0", + "resolved": "https://registry.npmjs.org/signal-exit/-/signal-exit-4.1.0.tgz", + "integrity": "sha512-bzyZ1e88w9O1iNJbKnOlvYTrWPDl46O1bG0D3XInv+9tkPrxrN8jUUTiFlDkkmKWgn1M6CfIA13SuGqOa9Korw==", + "dev": true, + "license": "ISC", + "engines": { + "node": ">=14" + }, + "funding": { + "url": "https://github.com/sponsors/isaacs" + } + }, + "node_modules/simple-concat": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/simple-concat/-/simple-concat-1.0.1.tgz", + "integrity": "sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "optional": true + }, + "node_modules/simple-get": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/simple-get/-/simple-get-4.0.1.tgz", + "integrity": "sha512-brv7p5WgH0jmQJr1ZDDfKDOSeWWg+OVypG99A/5vYGPqJ6pxiaHLy8nxtFjBA7oMa01ebA9gfh1uMCFqOuXxvA==", + "dev": true, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "license": "MIT", + "optional": true, + "dependencies": { + "decompress-response": "^6.0.0", + "once": "^1.3.1", + "simple-concat": "^1.0.0" + } + }, + "node_modules/slash": { + "version": "5.1.0", + "resolved": "https://registry.npmjs.org/slash/-/slash-5.1.0.tgz", + "integrity": "sha512-ZA6oR3T/pEyuqwMgAKT0/hAv8oAXckzbkmR0UkUosQ+Mc4RxGoJkRmwHgHufaenlyAgE1Mxgpdcrf75y6XcnDg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=14.16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/slice-ansi": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/slice-ansi/-/slice-ansi-4.0.0.tgz", + "integrity": "sha512-qMCMfhY040cVHT43K9BFygqYbUPFZKHOg7K73mtTWJRb8pyP3fzf4Ixd5SzdEJQ6MRUg/WBnOLxghZtKKurENQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-styles": "^4.0.0", + "astral-regex": "^2.0.0", + "is-fullwidth-code-point": "^3.0.0" + }, + "engines": { + "node": ">=10" + }, + "funding": { + "url": "https://github.com/chalk/slice-ansi?sponsor=1" + } + }, + "node_modules/spdx-correct": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/spdx-correct/-/spdx-correct-3.2.0.tgz", + "integrity": "sha512-kN9dJbvnySHULIluDHy32WHRUu3Og7B9sbY7tsFLctQkIqnMh3hErYgdMjTYuqmcXX+lK5T1lnUt3G7zNswmZA==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "spdx-expression-parse": "^3.0.0", + "spdx-license-ids": "^3.0.0" + } + }, + "node_modules/spdx-exceptions": { + "version": "2.5.0", + "resolved": "https://registry.npmjs.org/spdx-exceptions/-/spdx-exceptions-2.5.0.tgz", + "integrity": "sha512-PiU42r+xO4UbUS1buo3LPJkjlO7430Xn5SVAhdpzzsPHsjbYVflnnFdATgabnLude+Cqu25p6N+g2lw/PFsa4w==", + "dev": true, + "license": "CC-BY-3.0" + }, + "node_modules/spdx-expression-parse": { + "version": "3.0.1", + "resolved": "https://registry.npmjs.org/spdx-expression-parse/-/spdx-expression-parse-3.0.1.tgz", + "integrity": "sha512-cbqHunsQWnJNE6KhVSMsMeH5H/L9EpymbzqTQ3uLwNCLZ1Q481oWaofqH7nO6V07xlXwY6PhQdQ2IedWx/ZK4Q==", + "dev": true, + "license": "MIT", + "dependencies": { + "spdx-exceptions": "^2.1.0", + "spdx-license-ids": "^3.0.0" + } + }, + "node_modules/spdx-license-ids": { + "version": "3.0.24", + "resolved": "https://registry.npmjs.org/spdx-license-ids/-/spdx-license-ids-3.0.24.tgz", + "integrity": "sha512-cLS9TtWkIQFyLkJ3/5aFQAOHOSKTlOs/7WDut/XPSdjom1fJhUdkepeJAKXa9Y05+FabHd0sti+Et559vDtkpQ==", + "dev": true, + "license": "CC0-1.0" + }, + "node_modules/stdin-discarder": { + "version": "0.2.2", + "resolved": "https://registry.npmjs.org/stdin-discarder/-/stdin-discarder-0.2.2.tgz", + "integrity": "sha512-UhDfHmA92YAlNnCfhmq0VeNL5bDbiZGg7sZ2IvPsXubGkiNa9EC+tUTsjBRsYUAz87btI6/1wf4XoVvQ3uRnmQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/string_decoder": { + "version": "1.1.1", + "resolved": "https://registry.npmjs.org/string_decoder/-/string_decoder-1.1.1.tgz", + "integrity": "sha512-n/ShnvDi6FHbbVfviro+WojiFzv+s8MPMHBczVePfUpDJLwoLT0ht1l4YwBCbi8pJAveEEdnkHyPyTP/mzRfwg==", + "dev": true, + "license": "MIT", + "dependencies": { + "safe-buffer": "~5.1.0" + } + }, + "node_modules/string_decoder/node_modules/safe-buffer": { + "version": "5.1.2", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.1.2.tgz", + "integrity": "sha512-Gd2UZBJDkXlY7GbJxfsE8/nvKkUEU1G38c1siN6QP6a9PT9MmHB8GnpscSmMJSoF8LOIrt8ud/wPtojys4G6+g==", + "dev": true, + "license": "MIT" + }, + "node_modules/string-width": { + "version": "4.2.3", + "resolved": "https://registry.npmjs.org/string-width/-/string-width-4.2.3.tgz", + "integrity": "sha512-wKyQRQpjJ0sIp62ErSZdGsjMJWsap5oRNihHhu6G7JVO/9jIB6UyevL+tXuOqrng8j/cxKTWyWUwvSTriiZz/g==", + "dev": true, + "license": "MIT", + "dependencies": { + "emoji-regex": "^8.0.0", + "is-fullwidth-code-point": "^3.0.0", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/string-width/node_modules/ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/string-width/node_modules/strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/strip-ansi": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-7.2.0.tgz", + "integrity": "sha512-yDPMNjp4WyfYBkHnjIRLfca1i6KMyGCtsVgoKe/z1+6vukgaENdgGBZt+ZmKPc4gavvEZ5OgHfHdrazhgNyG7w==", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^6.2.2" + }, + "engines": { + "node": ">=12" + }, + "funding": { + "url": "https://github.com/chalk/strip-ansi?sponsor=1" + } + }, + "node_modules/strip-json-comments": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/strip-json-comments/-/strip-json-comments-2.0.1.tgz", + "integrity": "sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ==", + "dev": true, + "license": "MIT", + "optional": true, + "engines": { + "node": ">=0.10.0" + } + }, + "node_modules/structured-source": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/structured-source/-/structured-source-4.0.0.tgz", + "integrity": "sha512-qGzRFNJDjFieQkl/sVOI2dUjHKRyL9dAJi2gCPGJLbJHBIkyOHxjuocpIEfbLioX+qSJpvbYdT49/YCdMznKxA==", + "dev": true, + "license": "BSD-2-Clause", + "dependencies": { + "boundary": "^2.0.0" + } + }, + "node_modules/supports-color": { + "version": "7.2.0", + "resolved": "https://registry.npmjs.org/supports-color/-/supports-color-7.2.0.tgz", + "integrity": "sha512-qpCAvRl9stuOHveKsn7HncJRvv501qIacKzQlO/+Lwxc9+0q2wLyv4Dfvt80/DPn2pqOBsJdDiogXGR9+OvwRw==", + "dev": true, + "license": "MIT", + "dependencies": { + "has-flag": "^4.0.0" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/supports-hyperlinks": { + "version": "3.2.0", + "resolved": "https://registry.npmjs.org/supports-hyperlinks/-/supports-hyperlinks-3.2.0.tgz", + "integrity": "sha512-zFObLMyZeEwzAoKCyu1B91U79K2t7ApXuQfo8OuxwXLDgcKxuwM+YvcbIhm6QWqz7mHUH1TVytR1PwVVjEuMig==", + "dev": true, + "license": "MIT", + "dependencies": { + "has-flag": "^4.0.0", + "supports-color": "^7.0.0" + }, + "engines": { + "node": ">=14.18" + }, + "funding": { + "url": "https://github.com/chalk/supports-hyperlinks?sponsor=1" + } + }, + "node_modules/table": { + "version": "6.10.2", + "resolved": "https://registry.npmjs.org/table/-/table-6.10.2.tgz", + "integrity": "sha512-8hxlFbKvz0li0OBM24GXVZjoY+tUweFlcLAiJVoSSg9+J/SyigcLPcNDcq9uIH6GaB1P6YN4WLPFblhWxetPHQ==", + "dev": true, + "license": "BSD-3-Clause", + "dependencies": { + "ajv": "^8.0.1", + "slice-ansi": "^4.0.0", + "string-width": "^4.2.3", + "strip-ansi": "^6.0.1" + }, + "engines": { + "node": ">=10.0.0" + } + }, + "node_modules/table/node_modules/ansi-regex": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/ansi-regex/-/ansi-regex-5.0.1.tgz", + "integrity": "sha512-quJQXlTSUGL2LH9SUXo8VwsY4soanhgo6LNSm84E1LBcE8s3O0wpdiRzyR9z/ZZJMlMWv37qOOb9pdJlMUEKFQ==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=8" + } + }, + "node_modules/table/node_modules/strip-ansi": { + "version": "6.0.1", + "resolved": "https://registry.npmjs.org/strip-ansi/-/strip-ansi-6.0.1.tgz", + "integrity": "sha512-Y38VPSHcqkFrCpFnQ9vuSXmquuv5oXOKpGeT6aGrr3o3Gc9AlVa6JBfUSOCnbxGGZF+/0ooI7KrPuUSztUdU5A==", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-regex": "^5.0.1" + }, + "engines": { + "node": ">=8" + } + }, + "node_modules/tar-fs": { + "version": "2.1.6", + "resolved": "https://registry.npmjs.org/tar-fs/-/tar-fs-2.1.6.tgz", + "integrity": "sha512-vsdruOmnweDIXJXWpfc5aszWMVOj6qFI+dXxNuprh6Kt+WrGJh1MQL/2xYUEzI3EX86o9b2Rop8ziIF5Ol/UoQ==", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "chownr": "^1.1.1", + "mkdirp-classic": "^0.5.2", + "pump": "^3.0.0", + "tar-stream": "^2.1.4" + } + }, + "node_modules/tar-stream": { + "version": "2.2.0", + "resolved": "https://registry.npmjs.org/tar-stream/-/tar-stream-2.2.0.tgz", + "integrity": "sha512-ujeqbceABgwMZxEJnk2HDY2DlnUZ+9oEcb1KzTVfYHio0UE6dG71n60d8D2I4qNvleWrrXpmjpt7vZeF1LnMZQ==", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "bl": "^4.0.3", + "end-of-stream": "^1.4.1", + "fs-constants": "^1.0.0", + "inherits": "^2.0.3", + "readable-stream": "^3.1.1" + }, + "engines": { + "node": ">=6" + } + }, + "node_modules/tar-stream/node_modules/readable-stream": { + "version": "3.6.2", + "resolved": "https://registry.npmjs.org/readable-stream/-/readable-stream-3.6.2.tgz", + "integrity": "sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==", + "dev": true, + "license": "MIT", + "optional": true, + "dependencies": { + "inherits": "^2.0.3", + "string_decoder": "^1.1.1", + "util-deprecate": "^1.0.1" + }, + "engines": { + "node": ">= 6" + } + }, + "node_modules/terminal-link": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/terminal-link/-/terminal-link-4.0.0.tgz", + "integrity": "sha512-lk+vH+MccxNqgVqSnkMVKx4VLJfnLjDBGzH16JVZjKE2DoxP57s6/vt6JmXV5I3jBcfGrxNrYtC+mPtU7WJztA==", + "dev": true, + "license": "MIT", + "dependencies": { + "ansi-escapes": "^7.0.0", + "supports-hyperlinks": "^3.2.0" + }, + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/text-table": { + "version": "0.2.0", + "resolved": "https://registry.npmjs.org/text-table/-/text-table-0.2.0.tgz", + "integrity": "sha512-N+8UisAXDGk8PFXP4HAzVR9nbfmVJ3zYLAWiTIoqC5v5isinhr+r5uaO8+7r3BMfuNIufIsA7RdpVgacC2cSpw==", + "dev": true, + "license": "MIT" + }, + "node_modules/textextensions": { + "version": "6.11.0", + "resolved": "https://registry.npmjs.org/textextensions/-/textextensions-6.11.0.tgz", + "integrity": "sha512-tXJwSr9355kFJI3lbCkPpUH5cP8/M0GGy2xLO34aZCjMXBaK3SoPnZwr/oWmo1FdCnELcs4npdCIOFtq9W3ruQ==", + "dev": true, + "license": "Artistic-2.0", + "dependencies": { + "editions": "^6.21.0" + }, + "engines": { + "node": ">=4" + }, + "funding": { + "url": "https://bevry.me/fund" + } + }, + "node_modules/tmp": { + "version": "0.2.7", + "resolved": "https://registry.npmjs.org/tmp/-/tmp-0.2.7.tgz", + "integrity": "sha512-e0votIpp4Uo2AJYSzVHV6xCcawuiez3DzqDAbrTc3YxBkplN6e+dM13ZeIcZnDg/QpSuU2zfZ3rzwY8ukEnaXw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=14.14" + } + }, + "node_modules/to-regex-range": { + "version": "5.0.1", + "resolved": "https://registry.npmjs.org/to-regex-range/-/to-regex-range-5.0.1.tgz", + "integrity": "sha512-65P7iz6X5yEr1cwcgvQxbbIw7Uk3gOy5dIdtZ4rDveLqhrdJP+Li/Hx6tyK0NEb+2GCyneCMJiGqrADCSNk8sQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "is-number": "^7.0.0" + }, + "engines": { + "node": ">=8.0" + } + }, + "node_modules/tslib": { + "version": "2.9.1", + "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.9.1.tgz", + "integrity": "sha512-a4Ux9VKuIMHsOS7ENbEq6hK2ZGYIT27Rtl0E4eD9KqwxhKiQeMZE/9xb3IdYwWaSOyIBQLExhQgXDTYoiCxnWA==", + "dev": true, + "license": "0BSD" + }, + "node_modules/tunnel": { + "version": "0.0.6", + "resolved": "https://registry.npmjs.org/tunnel/-/tunnel-0.0.6.tgz", + "integrity": "sha512-1h/Lnq9yajKY2PEbBadPXj3VxsDDu844OnaAo52UVmIzIvwwtBPIuNvkjuzBlTWpfJyUbG3ez0KSBibQkj4ojg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=0.6.11 <=0.7.0 || >=0.7.3" + } + }, + "node_modules/tunnel-agent": { + "version": "0.6.0", + "resolved": "https://registry.npmjs.org/tunnel-agent/-/tunnel-agent-0.6.0.tgz", + "integrity": "sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w==", + "dev": true, + "license": "Apache-2.0", + "optional": true, + "dependencies": { + "safe-buffer": "^5.0.1" + }, + "engines": { + "node": "*" + } + }, + "node_modules/type-fest": { + "version": "4.41.0", + "resolved": "https://registry.npmjs.org/type-fest/-/type-fest-4.41.0.tgz", + "integrity": "sha512-TeTSQ6H5YHvpqVwBRcnLDCBnDOHWYu7IvGbHT6N8AOymcr9PJGjc1GTtiWZTYg0NCgYwvnYWEkVChQAr9bjfwA==", + "dev": true, + "license": "(MIT OR CC0-1.0)", + "engines": { + "node": ">=16" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/typed-rest-client": { + "version": "1.8.11", + "resolved": "https://registry.npmjs.org/typed-rest-client/-/typed-rest-client-1.8.11.tgz", + "integrity": "sha512-5UvfMpd1oelmUPRbbaVnq+rHP7ng2cE4qoQkQeAqxRL6PklkxsM0g32/HL0yfvruK6ojQ5x8EE+HF4YV6DtuCA==", + "dev": true, + "license": "MIT", + "dependencies": { + "qs": "^6.9.1", + "tunnel": "0.0.6", + "underscore": "^1.12.1" + } + }, + "node_modules/typescript": { + "version": "5.9.3", + "resolved": "https://registry.npmjs.org/typescript/-/typescript-5.9.3.tgz", + "integrity": "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw==", + "dev": true, + "license": "Apache-2.0", + "bin": { + "tsc": "bin/tsc", + "tsserver": "bin/tsserver" + }, + "engines": { + "node": ">=14.17" + } + }, + "node_modules/uc.micro": { + "version": "2.1.0", + "resolved": "https://registry.npmjs.org/uc.micro/-/uc.micro-2.1.0.tgz", + "integrity": "sha512-ARDJmphmdvUk6Glw7y9DQ2bFkKBHwQHLi2lsaH6PPmz/Ka9sFOBsBluozhDltWmnv9u/cF6Rt87znRTPV+yp/A==", + "dev": true, + "license": "MIT" + }, + "node_modules/underscore": { + "version": "1.13.8", + "resolved": "https://registry.npmjs.org/underscore/-/underscore-1.13.8.tgz", + "integrity": "sha512-DXtD3ZtEQzc7M8m4cXotyHR+FAS18C64asBYY5vqZexfYryNNnDc02W4hKg3rdQuqOYas1jkseX0+nZXjTXnvQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/undici": { + "version": "7.30.2", + "resolved": "https://registry.npmjs.org/undici/-/undici-7.30.2.tgz", + "integrity": "sha512-mLyPQnHwUxaM/rideoK/+KL8DaAJLRl4aBCfmX444aCSLnIaomqPLtNRe2jdCYcsk5wZzXrDIQC8ZeYNRAYyIA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=20.18.1" + } + }, + "node_modules/undici-types": { + "version": "6.21.0", + "resolved": "https://registry.npmjs.org/undici-types/-/undici-types-6.21.0.tgz", + "integrity": "sha512-iwDZqg0QAGrg9Rav5H4n0M64c3mkR59cJ6wQp+7C4nI0gsmExaedaYLNO44eT4AtBBwjbTiGPMlt2Md0T9H9JQ==", + "dev": true, + "license": "MIT" + }, + "node_modules/unicorn-magic": { + "version": "0.3.0", + "resolved": "https://registry.npmjs.org/unicorn-magic/-/unicorn-magic-0.3.0.tgz", + "integrity": "sha512-+QBBXBCvifc56fsbuxZQ6Sic3wqqc3WWaqxs58gvJrcOuN83HGTCwz3oS5phzU9LthRNE9VrJCFCLUgHeeFnfA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/universalify": { + "version": "2.0.1", + "resolved": "https://registry.npmjs.org/universalify/-/universalify-2.0.1.tgz", + "integrity": "sha512-gptHNQghINnc/vTGIk0SOFGFNXw7JVrlRUtConJRlvaw6DuX0wO5Jeko9sWrMBhh+PsYAZ7oXAiOnf/UKogyiw==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">= 10.0.0" + } + }, + "node_modules/url-join": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/url-join/-/url-join-4.0.1.tgz", + "integrity": "sha512-jk1+QP6ZJqyOiuEI9AEWQfju/nB2Pw466kbA0LEZljHwKeMgd9WrAEgEGxjPDD2+TNbbb37rTyhEfrCXfuKXnA==", + "dev": true, + "license": "MIT" + }, + "node_modules/util-deprecate": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/util-deprecate/-/util-deprecate-1.0.2.tgz", + "integrity": "sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw==", + "dev": true, + "license": "MIT" + }, + "node_modules/validate-npm-package-license": { + "version": "3.0.4", + "resolved": "https://registry.npmjs.org/validate-npm-package-license/-/validate-npm-package-license-3.0.4.tgz", + "integrity": "sha512-DpKm2Ui/xN7/HQKCtpZxoRWBhZ9Z0kqtygG8XCgNQ8ZlDnxuQmWhj566j8fN4Cu3/JmbhsDo7fcAJq4s9h27Ew==", + "dev": true, + "license": "Apache-2.0", + "dependencies": { + "spdx-correct": "^3.0.0", + "spdx-expression-parse": "^3.0.0" + } + }, + "node_modules/version-range": { + "version": "4.15.0", + "resolved": "https://registry.npmjs.org/version-range/-/version-range-4.15.0.tgz", + "integrity": "sha512-Ck0EJbAGxHwprkzFO966t4/5QkRuzh+/I1RxhLgUKKwEn+Cd8NwM60mE3AqBZg5gYODoXW0EFsQvbZjRlvdqbg==", + "dev": true, + "license": "Artistic-2.0", + "engines": { + "node": ">=4" + }, + "funding": { + "url": "https://bevry.me/fund" + } + }, + "node_modules/whatwg-encoding": { + "version": "3.1.1", + "resolved": "https://registry.npmjs.org/whatwg-encoding/-/whatwg-encoding-3.1.1.tgz", + "integrity": "sha512-6qN4hJdMwfYBtE3YBTTHhoeuUrDBPZmbQaxWAqSALV/MeEnR5z1xd8UKud2RAkFoPkmB+hli1TZSnyi84xz1vQ==", + "deprecated": "Use @exodus/bytes instead for a more spec-conformant and faster implementation", + "dev": true, + "license": "MIT", + "dependencies": { + "iconv-lite": "0.6.3" + }, + "engines": { + "node": ">=18" + } + }, + "node_modules/whatwg-mimetype": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/whatwg-mimetype/-/whatwg-mimetype-4.0.0.tgz", + "integrity": "sha512-QaKxh0eNIi2mE9p2vEdzfagOKHCcj1pJ56EEHGQOVxp8r9/iszLUUV7v89x9O1p/T+NlTM5W7jW6+cz4Fq1YVg==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=18" + } + }, + "node_modules/wrappy": { + "version": "1.0.2", + "resolved": "https://registry.npmjs.org/wrappy/-/wrappy-1.0.2.tgz", + "integrity": "sha512-l4Sp/DRseor9wL6EvV2+TuQn63dMkPjZ/sp9XkghTEbV9KlPS1xUsZ3u7/IQO4wxtcFB4bgpQPRcR3QCvezPcQ==", + "dev": true, + "license": "ISC", + "optional": true + }, + "node_modules/wsl-utils": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/wsl-utils/-/wsl-utils-1.0.1.tgz", + "integrity": "sha512-c16PKLIRxBYpR3jSWsdS7SFp0COm5SOQdiFjY818dYFHJbMGuLBszpF07LBWmOS1uzrHa9VGdynsEgoeKy0oOQ==", + "dev": true, + "license": "MIT", + "dependencies": { + "is-wsl": "^3.1.0", + "powershell-utils": "^0.2.0" + }, + "engines": { + "node": ">=20" + }, + "funding": { + "url": "https://github.com/sponsors/sindresorhus" + } + }, + "node_modules/xml2js": { + "version": "0.5.0", + "resolved": "https://registry.npmjs.org/xml2js/-/xml2js-0.5.0.tgz", + "integrity": "sha512-drPFnkQJik/O+uPKpqSgr22mpuFHqKdbS835iAQrUC73L2F5WkboIRd63ai/2Yg6I1jzifPFKH2NTK+cfglkIA==", + "dev": true, + "license": "MIT", + "dependencies": { + "sax": ">=0.6.0", + "xmlbuilder": "~11.0.0" + }, + "engines": { + "node": ">=4.0.0" + } + }, + "node_modules/xmlbuilder": { + "version": "11.0.1", + "resolved": "https://registry.npmjs.org/xmlbuilder/-/xmlbuilder-11.0.1.tgz", + "integrity": "sha512-fDlsI/kFEx7gLvbecc0/ohLG50fugQp8ryHzMTuW9vSa1GJ0XYWKnhsUx7oie3G98+r56aTQIUB4kht42R3JvA==", + "dev": true, + "license": "MIT", + "engines": { + "node": ">=4.0" + } + }, + "node_modules/yallist": { + "version": "4.0.0", + "resolved": "https://registry.npmjs.org/yallist/-/yallist-4.0.0.tgz", + "integrity": "sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==", + "dev": true, + "license": "ISC" + }, + "node_modules/yauzl": { + "version": "3.4.0", + "resolved": "https://registry.npmjs.org/yauzl/-/yauzl-3.4.0.tgz", + "integrity": "sha512-jIH9yLR9wqr0wOS0TpBvo/g/2UgZH5qePVbjgRliiF0BYvOZyaBknKsF+x9Iht0O6sqgnB93rCICdOZFecJuDw==", + "dev": true, + "license": "MIT", + "dependencies": { + "pend": "~1.2.0" + }, + "engines": { + "node": ">=12" + } + }, + "node_modules/yazl": { + "version": "2.5.1", + "resolved": "https://registry.npmjs.org/yazl/-/yazl-2.5.1.tgz", + "integrity": "sha512-phENi2PLiHnHb6QBVot+dJnaAZ0xosj7p3fWl+znIjBDlnMI2PsZCJZ306BPTFOaHf5qdDEI8x5qFrSOBN5vrw==", + "dev": true, + "license": "MIT", + "dependencies": { + "buffer-crc32": "~0.2.3" + } + } + } +} diff --git a/extensions/neon-getaway/package.json b/extensions/neon-getaway/package.json new file mode 100644 index 0000000..1c18ba6 --- /dev/null +++ b/extensions/neon-getaway/package.json @@ -0,0 +1,120 @@ +{ + "name": "neon-getaway", + "displayName": "Neon Getaway: Open World Driving Game", + "description": "A neon open-world driving game inside VS Code. Steal cars, outrun the cops, drift through Solara Bay, run missions and races, and spend the cash your coding earns. Free, offline, no account.", + "version": "1.0.0", + "publisher": "flightcoders", + "author": { + "name": "Flight Coders" + }, + "license": "MIT", + "icon": "media/icon.png", + "pricing": "Free", + "homepage": "https://veyraeditor.com/neon-getaway", + "repository": { + "type": "git", + "url": "https://github.com/fcopensource/veyraeditor.git", + "directory": "extensions/neon-getaway" + }, + "bugs": { + "url": "https://github.com/fcopensource/veyraeditor/issues" + }, + "qna": "https://github.com/fcopensource/veyraeditor/issues", + "engines": { + "vscode": "^1.85.0" + }, + "categories": [ + "Other" + ], + "keywords": [ + "game", + "games", + "open world", + "driving game", + "car game", + "racing", + "police chase", + "drift", + "arcade", + "retro", + "neon", + "synthwave", + "80s", + "fun", + "break", + "coffee break", + "vscode game" + ], + "galleryBanner": { + "color": "#120b24", + "theme": "dark" + }, + "capabilities": { + "untrustedWorkspaces": { + "supported": true + }, + "virtualWorkspaces": true + }, + "main": "./bundle/extension.js", + "activationEvents": [ + "onStartupFinished" + ], + "contributes": { + "commands": [ + { + "command": "neonGetaway.play", + "title": "Play Neon Getaway", + "category": "Neon Getaway", + "icon": "$(rocket)" + }, + { + "command": "neonGetaway.reset", + "title": "Start Over (delete my save)", + "category": "Neon Getaway" + } + ], + "keybindings": [ + { + "command": "neonGetaway.play", + "key": "ctrl+alt+g", + "mac": "cmd+alt+g" + } + ], + "configuration": { + "title": "Neon Getaway", + "properties": { + "neonGetaway.statusBar": { + "type": "boolean", + "default": true, + "description": "Show the Neon Getaway button, with the cash your coding has earned, in the status bar." + }, + "neonGetaway.paycheck": { + "type": "boolean", + "default": true, + "description": "Earn in-game cash when you save files ($25 a save, up to $1,000 a day)." + }, + "neonGetaway.sound": { + "type": "boolean", + "default": true, + "description": "Play the engine, siren and synthwave radio sounds (they start only after you press a key in the game)." + } + } + } + }, + "scripts": { + "compile": "tsc -p .", + "bundle": "esbuild src/extension.ts --bundle --platform=node --format=cjs --target=node18 --external:vscode --outfile=bundle/extension.js --log-level=warning", + "test": "tsc -p . && node --test test/engine.test.mjs test/pay.test.mjs", + "test:integration": "tsc -p . && npm run bundle && node test/integration/run.mjs", + "package": "npm run bundle && node -e \"require('fs').mkdirSync('dist',{recursive:true})\" && vsce package --no-dependencies --out dist/", + "vscode:prepublish": "npm run bundle" + }, + "devDependencies": { + "@types/node": "^22.0.0", + "@types/vscode": "~1.85.0", + "@vscode/test-electron": "^2.5.2", + "@vscode/vsce": "^3.6.0", + "esbuild": "^0.25.0", + "typescript": "^5.9.0" + } +} diff --git a/extensions/neon-getaway/release/neon-getaway-1.0.0.vsix b/extensions/neon-getaway/release/neon-getaway-1.0.0.vsix new file mode 100644 index 0000000..a09919f Binary files /dev/null and b/extensions/neon-getaway/release/neon-getaway-1.0.0.vsix differ diff --git a/extensions/neon-getaway/src/extension.ts b/extensions/neon-getaway/src/extension.ts new file mode 100644 index 0000000..29ed2a1 --- /dev/null +++ b/extensions/neon-getaway/src/extension.ts @@ -0,0 +1,107 @@ +import * as vscode from 'vscode'; +import * as crypto from 'crypto'; +import { collected, EMPTY, onSave, PayState } from './pay'; + +const SAVE_KEY = 'neonGetaway.save'; +const PAY_KEY = 'neonGetaway.pay'; +const SOUND_KEY = 'neonGetaway.soundOn'; + +type FromGame = + | { type: 'ready' } + | { type: 'save'; save: unknown } + | { type: 'paid'; amount: number } + | { type: 'sound'; on: boolean }; + +let game: GamePanel | undefined; + +export function activate(context: vscode.ExtensionContext) { + const status = vscode.window.createStatusBarItem(vscode.StatusBarAlignment.Right, 50); + status.command = 'neonGetaway.play'; + const config = () => vscode.workspace.getConfiguration('neonGetaway'); + const pay = (): PayState => ({ ...EMPTY, ...context.globalState.get(PAY_KEY) }); + + const refreshStatus = () => { + if (!config().get('statusBar', true)) { status.hide(); return; } + const pending = pay().pending; + status.text = pending > 0 ? `$(rocket) +$${pending.toLocaleString('en')}` : '$(rocket) Neon Getaway'; + status.tooltip = pending > 0 + ? `Your code earned $${pending.toLocaleString('en')} in Neon Getaway. Click to spend it.` + : 'Play Neon Getaway (Ctrl+Alt+G). Saving files earns you in-game cash.'; + status.show(); + }; + + context.subscriptions.push( + status, + vscode.commands.registerCommand('neonGetaway.play', () => { + if (game) { game.panel.reveal(); return; } + game = new GamePanel(context, pay, async p => { await context.globalState.update(PAY_KEY, p); refreshStatus(); }); + game.panel.onDidDispose(() => { game = undefined; }); + }), + vscode.commands.registerCommand('neonGetaway.reset', async () => { + const ok = await vscode.window.showWarningMessage('Delete your Neon Getaway save? Your cash, cars and missions start over.', { modal: true }, 'Start over'); + if (ok !== 'Start over') return; + await context.globalState.update(SAVE_KEY, undefined); + game?.init(); + vscode.window.showInformationMessage('Neon Getaway: a fresh start in Solara Bay.'); + }), + vscode.workspace.onDidSaveTextDocument(async doc => { + if (!config().get('paycheck', true) || doc.uri.scheme === 'vscode-userdata') return; + const { state, paid } = onSave(pay(), new Date()); + await context.globalState.update(PAY_KEY, state); + if (paid && game?.ready) game.sendPaycheck(); + refreshStatus(); + }), + vscode.workspace.onDidChangeConfiguration(e => { if (e.affectsConfiguration('neonGetaway')) refreshStatus(); }), + ); + refreshStatus(); + + // For the integration tests. + return { + isOpen: () => !!game, + isReady: () => !!game?.ready, + pending: () => pay().pending, + save: () => context.globalState.get(SAVE_KEY), + post: (m: unknown) => game?.panel.webview.postMessage(m), + }; +} + +class GamePanel { + readonly panel: vscode.WebviewPanel; + ready = false; + + constructor(private context: vscode.ExtensionContext, private pay: () => PayState, private setPay: (p: PayState) => Promise) { + const media = vscode.Uri.joinPath(context.extensionUri, 'media'); + this.panel = vscode.window.createWebviewPanel('neonGetaway', 'Neon Getaway', vscode.ViewColumn.Active, { + enableScripts: true, retainContextWhenHidden: true, localResourceRoots: [media], + }); + this.panel.iconPath = vscode.Uri.joinPath(media, 'icon.png'); + const web = this.panel.webview; + const nonce = crypto.randomBytes(16).toString('base64'); + const src = (f: string) => web.asWebviewUri(vscode.Uri.joinPath(media, f)); + const csp = `default-src 'none'; img-src ${web.cspSource} data:; style-src ${web.cspSource}; font-src ${web.cspSource}; script-src 'nonce-${nonce}';`; + web.html = ` +Neon Getaway + + +`; + web.onDidReceiveMessage(async (m: FromGame) => { + if (m.type === 'ready') { this.ready = true; this.init(); } + else if (m.type === 'save') await context.globalState.update(SAVE_KEY, m.save); + else if (m.type === 'paid') await this.setPay(collected(this.pay(), m.amount)); + else if (m.type === 'sound') await context.globalState.update(SOUND_KEY, m.on); + }); + } + + /** Load the save into the game, with any cash the player's code earned while they were away. */ + init() { + const sound = vscode.workspace.getConfiguration('neonGetaway').get('sound', true) && this.context.globalState.get(SOUND_KEY) !== false; + void this.panel.webview.postMessage({ type: 'init', save: this.context.globalState.get(SAVE_KEY) ?? null, paycheck: this.pay().pending, sound }); + } + + sendPaycheck() { + const amount = this.pay().pending; + if (amount > 0) void this.panel.webview.postMessage({ type: 'paycheck', amount }); + } +} + +export function deactivate() {} diff --git a/extensions/neon-getaway/src/pay.ts b/extensions/neon-getaway/src/pay.ts new file mode 100644 index 0000000..3f8baa3 --- /dev/null +++ b/extensions/neon-getaway/src/pay.ts @@ -0,0 +1,34 @@ +/** Paychecks: saving files in VS Code earns in-game cash, $25 a save, up to $1,000 a day. */ + +export interface PayState { + /** Cash earned but not yet handed to the game. */ + pending: number; + /** The local day the daily total belongs to, like 2026-11-24. */ + day: string; + earnedToday: number; + /** When the last paid save happened (ms). Saves closer together than MIN_GAP_MS (autosave, save-all) count once. */ + lastAt: number; +} + +export const PER_SAVE = 25; +export const DAILY_CAP = 1000; +export const MIN_GAP_MS = 5000; +export const EMPTY: PayState = { pending: 0, day: '', earnedToday: 0, lastAt: 0 }; + +export const dayKey = (d: Date) => `${d.getFullYear()}-${String(d.getMonth() + 1).padStart(2, '0')}-${String(d.getDate()).padStart(2, '0')}`; + +/** A file was saved: the new state, and how much it paid (0 when capped or too soon after the last one). */ +export function onSave(state: PayState, now: Date): { state: PayState; paid: number } { + const s = { ...EMPTY, ...state }; + const day = dayKey(now); + if (s.day !== day) { s.day = day; s.earnedToday = 0; } + if (now.getTime() - s.lastAt < MIN_GAP_MS) return { state: s, paid: 0 }; + const paid = Math.max(0, Math.min(PER_SAVE, DAILY_CAP - s.earnedToday)); + if (!paid) return { state: s, paid: 0 }; + return { state: { ...s, pending: s.pending + paid, earnedToday: s.earnedToday + paid, lastAt: now.getTime() }, paid }; +} + +/** The game took `amount` of the pending cash. */ +export function collected(state: PayState, amount: number): PayState { + return { ...EMPTY, ...state, pending: Math.max(0, (state.pending || 0) - Math.max(0, amount)) }; +} diff --git a/extensions/neon-getaway/test/engine.test.mjs b/extensions/neon-getaway/test/engine.test.mjs new file mode 100644 index 0000000..65dcf50 --- /dev/null +++ b/extensions/neon-getaway/test/engine.test.mjs @@ -0,0 +1,301 @@ +// The game rules, without a screen: the city, driving, traffic, people, police, missions and money. +import { test } from 'node:test'; +import assert from 'node:assert/strict'; +import { createRequire } from 'node:module'; + +const require = createRequire(import.meta.url); +const NG = require('../media/engine.js'); +const { TILE, T } = NG; +const DT = 1 / 60; +const run = (w, input, seconds) => { const events = []; for (let k = 0; k < seconds * 60; k++) events.push(...NG.step(w, input, DT)); return events; }; +const near = (a, b, d) => Math.hypot(a.x - b.x, a.y - b.y) < d; +/** Put the player in a car of their own at (x, y), facing angle a. */ +function drivingAt(w, x, y, a, model = 'sports') { + const c = NG.makeCar('player', model, x, y, a); + w.cars.push(c); w.player.car = c; + return c; +} + +test('the city is the same for everyone, with a coast, roads and landmarks', () => { + const a = NG.makeCity(), b = NG.makeCity(); + assert.deepEqual(Array.from(a.tiles), Array.from(b.tiles)); + assert.equal(a.get(0, 0), TILE.WATER); + assert.equal(a.get(NG.ROADS[3], 60), TILE.ROAD); + for (const key of ['garage', 'police', 'spray', 'bank', 'raceStart', 'pier', 'busStop', 'lotPalm']) assert.ok(a.poi[key], key); + assert.equal(a.tapes.length, 20); + assert.ok(a.buildings.length > 100 && a.parked.length > 20); +}); + +test('every road connects to every other', () => { + const c = NG.makeCity(); + const seen = new Set(), start = [NG.ROADS[0], NG.ROADS[0]], queue = [start]; + seen.add(start.join()); + while (queue.length) { + const [x, y] = queue.pop(); + for (const [dx, dy] of [[1, 0], [-1, 0], [0, 1], [0, -1]]) { + const k = `${x + dx},${y + dy}`; + if (!seen.has(k) && c.isRoadTile(x + dx, y + dy)) { seen.add(k); queue.push([x + dx, y + dy]); } + } + } + let roads = 0; + for (let y = 0; y < c.H; y++) for (let x = 0; x < c.W; x++) roads += c.isRoadTile(x, y); + assert.equal(seen.size, roads); +}); + +test('every landmark and tape can be reached on foot or by car', () => { + const c = NG.makeCity(); + for (const [key, p] of Object.entries(c.poi)) { + if (Array.isArray(p)) continue; + assert.ok(!NG.hitsSolid(c, p.x, p.y, 8), `${key} is not inside a wall`); + } + for (const t of c.tapes) assert.ok(!NG.hitsSolid(c, t.x, t.y, 6), `tape ${t.id}`); +}); + +test('a car speeds up to its top speed, and stops when you brake', () => { + const w = NG.createWorld(); + const [x, y] = NG.nodeXY(2, 4); + const car = drivingAt(w, x + 2 * T, y - 0.5 * T, 0); + w.cars = [car]; w.peds = []; + for (let k = 0; k < 240; k++) NG.drive(w.city, car, { throttle: 1, steer: 0 }, DT); + const top = Math.hypot(car.vx, car.vy); + assert.ok(top > NG.MODELS.sports.max * 0.85, `fast: ${top}`); + for (let k = 0; k < 50; k++) NG.drive(w.city, car, { throttle: -1, steer: 0 }, DT); + assert.ok(Math.hypot(car.vx, car.vy) < 60, `stopped in under a second: ${Math.hypot(car.vx, car.vy)}`); + for (let k = 0; k < 240; k++) NG.drive(w.city, car, { throttle: -1, steer: 0 }, DT); + assert.ok(car.f < 0 && -car.f <= NG.MODELS.sports.max * 0.4 + 1, 'then reverses, slowly'); +}); + +test('cars never drive through buildings', () => { + const w = NG.createWorld(); + const b = w.city.buildings.find(q => q.w >= 4 && q.h >= 4 && !q.special); + const car = drivingAt(w, (b.x - 1) * T + 4, (b.y + b.h / 2) * T, 0, 'super'); + car.x = (b.x - 0.6) * T; + let crash = 0; + for (let k = 0; k < 180; k++) crash = Math.max(crash, NG.drive(w.city, car, { throttle: 1, steer: 0 }, DT)); + assert.ok(car.x < b.x * T, 'stopped at the wall'); + assert.ok(!NG.hitsSolid(w.city, car.x, car.y, 4)); +}); + +test('handbrake turns make the car slide', () => { + const w = NG.createWorld(); + const [x, y] = NG.nodeXY(4, 4); + const car = drivingAt(w, x - 6 * T, y + 0.5 * T, 0); + car.vx = 560; + let maxDrift = 0; + for (let k = 0; k < 40; k++) { NG.drive(w.city, car, { throttle: 1, steer: 1, handbrake: true }, DT); maxDrift = Math.max(maxDrift, car.drift); } + assert.ok(maxDrift > 110, `drifting: ${maxDrift}`); +}); + +test('traffic stays on the roads, in lanes, for a long drive', () => { + const w = NG.createWorld(); + w.player.x = NG.nodeXY(5, 5)[0]; w.player.y = NG.nodeXY(5, 5)[1]; + run(w, {}, 60); + const traffic = w.cars.filter(c => c.kind === 'traffic'); + assert.ok(traffic.length > 20); + for (const c of traffic) assert.equal(w.city.tileAtPx(c.x, c.y), TILE.ROAD, `traffic car ${c.id} at ${c.x},${c.y}`); + const moved = traffic.filter(c => c.v > 20).length; + assert.ok(moved > traffic.length * 0.4, `traffic flows: ${moved}/${traffic.length}`); +}); + +test('people walk on sidewalks and always dive out of the way', () => { + const w = NG.createWorld(); + const ped = w.peds[0]; + ped.x = w.player.x + 80; ped.y = w.player.y; ped.dodge = 0; + const car = drivingAt(w, ped.x - 70, ped.y, 0); + car.vx = 400; + const events = run(w, { up: true }, 0.5); + assert.ok(ped.shout > 0 || events.some(e => e.type === 'nearMiss'), 'they jumped clear'); +}); + +test('get in a car with E, and out again', () => { + const w = NG.createWorld(); + const parked = w.cars.find(c => c.kind === 'parked' && !c.owned); + w.player.x = parked.x + 30; w.player.y = parked.y; + w.cars = w.cars.filter(c => c.kind !== 'police'); + let ev = NG.step(w, { enter: true }, DT); + assert.equal(w.player.car, parked); + assert.ok(ev.some(e => e.type === 'enterCar')); + ev = NG.step(w, { enter: true }, DT); + assert.equal(w.player.car, null); + assert.ok(ev.some(e => e.type === 'exitCar')); +}); + +test('a cop who sees you take a car gives you a star, and police come after you', () => { + const w = NG.createWorld(); + const traffic = w.cars.find(c => c.kind === 'traffic'); + w.player.x = traffic.x; w.player.y = traffic.y + 30; + const cop = NG.makeCar('police', 'police', traffic.x + 120, traffic.y, Math.PI); + w.cars.push(cop); + NG.step(w, { enter: true }, DT); + assert.equal(w.wanted.stars, 1); + run(w, {}, 4); + assert.ok(w.cars.filter(c => c.kind === 'police').length >= 1); +}); + +test('more stars, more cops; they hunt you down through the streets', () => { + const w = NG.createWorld(); + const [x, y] = NG.nodeXY(5, 5); + drivingAt(w, x, y, 0); + NG.setStars(w, 3, 'test'); + let most = 0, caught = false; + for (let k = 0; k < 60 * 20 && !caught; k++) { + caught = NG.step(w, {}, DT).some(e => e.type === 'busted'); + most = Math.max(most, w.cars.filter(c => c.kind === 'police').length); + } + assert.ok(most >= 3, `three stars bring at least three cops: ${most}`); + assert.ok(caught, 'they reach a player who sits still, and bust them'); +}); + +test('stopping next to a cop gets you busted: a fine, and back at the station', () => { + const w = NG.createWorld({ cash: 1000 }); + const [x, y] = NG.nodeXY(5, 5); + drivingAt(w, x, y, 0); + NG.setStars(w, 1, 'test'); + const cop = NG.makeCar('police', 'police', x + 45, y, Math.PI); + w.cars.push(cop); + const events = run(w, {}, 3); + assert.ok(events.some(e => e.type === 'busted')); + assert.equal(w.wanted.stars, 0); + assert.equal(w.save.cash, 900); + assert.ok(near(w.player, w.city.poi.police, 60)); +}); + +test('staying out of sight long enough loses the cops', () => { + const w = NG.createWorld(); + const [x, y] = NG.nodeXY(5, 5); + drivingAt(w, x, y, 0); + NG.setStars(w, 1, 'test'); + w.lastCopSpawn = 1e9; // no cops arrive: nobody sees you + const events = run(w, {}, 11); + assert.ok(events.some(e => e.type === 'escaped')); + assert.equal(w.wanted.stars, 0); +}); + +test('the spray shop wipes your stars for a price', () => { + const w = NG.createWorld({ cash: 1000 }); + const sp = w.city.poi.spray; + drivingAt(w, sp.x, sp.y, 0); + NG.setStars(w, 3, 'test'); + const ev = NG.step(w, { action: true }, DT); + assert.ok(ev.some(e => e.type === 'sprayed')); + assert.equal(w.wanted.stars, 0); + assert.equal(w.save.cash, 750); +}); + +test('the first mission: find a car, drive to the garage, get paid', () => { + const w = NG.createWorld(); + let ev = NG.step(w, { action: true }, DT); + assert.ok(ev.some(e => e.type === 'missionStart' && e.title === 'Fresh Off the Bus')); + const g = w.city.poi.garage; + const car = drivingAt(w, g.x - 300, g.y, 0); + NG.step(w, {}, DT); + assert.equal(w.mission.step, 1); + car.x = g.x; car.y = g.y; car.vx = car.vy = 0; + ev = run(w, {}, 0.2); + assert.ok(ev.some(e => e.type === 'missionPassed')); + assert.equal(w.save.story, 1); + assert.equal(w.save.cash, 300 + 250); +}); + +test('a timed delivery fails when time runs out', () => { + const w = NG.createWorld({ story: 1 }); + const g = w.city.poi.garage; + w.player.x = g.x; w.player.y = g.y + 20; + NG.step(w, { action: true }, DT); + assert.equal(w.mission.idx, 1); + const car = drivingAt(w, g.x, g.y + 200, 0); + void car; + const ev = run(w, {}, 76); + assert.ok(ev.some(e => e.type === 'missionFailed' && e.why === 'Out of time')); + assert.equal(w.save.story, 1); +}); + +test('"The Getaway": three stars to lose before the garage lets you in', () => { + const w = NG.createWorld({ story: 3 }); + NG.startMission(w, 3); + const b = w.city.poi.bank; + const car = drivingAt(w, b.x, b.y, 0); + run(w, {}, 0.2); + assert.equal(w.mission.step, 1); + assert.equal(w.wanted.stars, 3); + w.wanted.stars = 0; // as if you'd shaken them off + run(w, {}, 0.1); + assert.equal(w.mission.step, 2); + const g = w.city.poi.garage; + car.x = g.x; car.y = g.y; car.vx = car.vy = 0; + const ev = run(w, {}, 0.2); + assert.ok(ev.some(e => e.type === 'missionPassed' && e.reward === 1600)); +}); + +test('the race: rivals drive the course, and finishing first pays', () => { + const w = NG.createWorld({ story: 4 }); + NG.startMission(w, 4); + assert.equal(w.race.rivals.length, 3); + const before = w.race.rivals.map(c => [c.x, c.y]); + run(w, {}, 3); + assert.ok(w.race.rivals.some((c, n) => Math.hypot(c.x - before[n][0], c.y - before[n][1]) > 200), 'rivals are racing'); + const car = drivingAt(w, 0, 0, 0); + for (const cp of [...w.race.checkpoints]) { car.x = cp.x; car.y = cp.y; NG.step(w, {}, DT); } + assert.equal(w.save.story, 5); + assert.ok(w.save.bestRace > 0); +}); + +test('taxi fares pay for getting there in time', () => { + const w = NG.createWorld(); + const stand = w.city.poi.taxi[1]; + const car = drivingAt(w, stand.x, stand.y, 0); + NG.step(w, { action: true }, DT); + assert.ok(w.job); + const pay = w.job.pay; + car.x = w.job.x; car.y = w.job.y; + const ev = run(w, {}, 0.1); + assert.ok(ev.some(e => e.type === 'cash' && e.amount === pay)); + assert.equal(w.save.stats.taxis, 1); +}); + +test('the garage sells cars, and you drive away in the one you pick', () => { + const w = NG.createWorld({ cash: 2000 }); + assert.equal(NG.garagePick(w, 'super'), 'You need $9000.'); + assert.equal(NG.garagePick(w, 'muscle'), null); + assert.equal(w.save.cash, 500); + assert.deepEqual(w.save.owned, ['compact', 'muscle']); + assert.ok(w.cars.some(c => c.owned && c.model === 'muscle')); + assert.equal(NG.garagePick(w, 'compact'), null); + assert.equal(w.save.cash, 500, 'owned cars are free to switch to'); +}); + +test('tapes are collected once, for $100 each', () => { + const w = NG.createWorld(); + const t = w.city.tapes[0]; + w.player.x = t.x; w.player.y = t.y; + let ev = NG.step(w, {}, DT); + assert.ok(ev.some(e => e.type === 'tape' && e.got === 1)); + ev = NG.step(w, {}, DT); + assert.ok(!ev.some(e => e.type === 'tape')); + assert.equal(w.save.cash, 400); +}); + +test('paychecks from coding add up, and the save holds everything', () => { + const w = NG.createWorld(); + NG.paycheck(w, 125); + NG.paycheck(w, -5); + assert.equal(w.save.cash, 425); + const again = NG.createWorld(JSON.parse(JSON.stringify(w.save))); + assert.equal(again.save.cash, 425); + assert.equal(again.save.stats.paychecks, 125); +}); + +test('a long chaotic session never crashes or leaves anything inside a wall', () => { + const w = NG.createWorld({ cash: 50000 }); + const [x, y] = NG.nodeXY(5, 5); + drivingAt(w, x, y, 0); + NG.setStars(w, 5, 'chaos'); + const r = NG.rng(7); + for (let k = 0; k < 60 * 90; k++) { + const input = { up: r() < 0.8, down: r() < 0.1, left: r() < 0.3, right: r() < 0.3, handbrake: r() < 0.1, enter: r() < 0.002, action: r() < 0.002 }; + NG.step(w, input, DT); + } + for (const c of w.cars) assert.ok(Number.isFinite(c.x) && Number.isFinite(c.y), 'positions stay numbers'); + const [px, py] = NG.playerPos(w); + assert.ok(Number.isFinite(px) && Number.isFinite(py)); +}); diff --git a/extensions/neon-getaway/test/harness.html b/extensions/neon-getaway/test/harness.html new file mode 100644 index 0000000..84914f6 --- /dev/null +++ b/extensions/neon-getaway/test/harness.html @@ -0,0 +1,7 @@ + + +Neon Getaway + + + + diff --git a/extensions/neon-getaway/test/integration/run.mjs b/extensions/neon-getaway/test/integration/run.mjs new file mode 100644 index 0000000..2d52f9f --- /dev/null +++ b/extensions/neon-getaway/test/integration/run.mjs @@ -0,0 +1,20 @@ +// Runs test/integration/suite.js inside VS Code (or VSCODE_PATH) with a small project to save files in. +import fs from "node:fs"; +import os from "node:os"; +import path from "node:path"; +import { fileURLToPath } from "node:url"; +import { runTests } from "@vscode/test-electron"; + +const root = path.resolve(path.dirname(fileURLToPath(import.meta.url)), "../.."); +const workspace = process.env.WORKSPACE || fs.mkdtempSync(path.join(os.tmpdir(), "neon-getaway-workspace-")); +fs.mkdirSync(path.join(workspace, "src"), { recursive: true }); +fs.writeFileSync(path.join(workspace, "src", "cart.js"), "export const total = prices => prices.reduce((a, b) => a + b, 0);\n"); + +const userData = fs.mkdtempSync(path.join(os.tmpdir(), "neon-getaway-vscode-")); +await runTests({ + vscodeExecutablePath: process.env.VSCODE_PATH || undefined, + extensionDevelopmentPath: root, + extensionTestsPath: path.join(root, "test", "integration", "suite.js"), + launchArgs: [workspace, "--disable-extensions", "--disable-workspace-trust", "--user-data-dir", userData, "--extensions-dir", path.join(userData, "extensions")], +}); +console.log("Integration tests passed."); diff --git a/extensions/neon-getaway/test/integration/suite.js b/extensions/neon-getaway/test/integration/suite.js new file mode 100644 index 0000000..86d0cdd --- /dev/null +++ b/extensions/neon-getaway/test/integration/suite.js @@ -0,0 +1,74 @@ +// Runs inside VS Code: the game opens and starts, saving a file pays the player, and progress is saved. +const assert = require("node:assert/strict"); +const path = require("node:path"); +const vscode = require("vscode"); + +const wait = ms => new Promise(resolve => setTimeout(resolve, ms)); +async function until(check, what, ms = 30000) { + const end = Date.now() + ms; + let last; + while (Date.now() < end) { try { last = await check(); if (last) return last; } catch (e) { last = e.message; } await wait(200); } + throw new Error(`Timed out waiting for ${what}${last ? ` (last: ${JSON.stringify(last)})` : ""}`); +} +const step = name => console.log(`[suite] ${name}`); + +exports.run = async function run() { + try { await steps(); console.log("[suite] all steps passed"); } + catch (error) { console.error("[suite] FAILED:", error); throw error; } +}; + +async function steps() { + const folder = vscode.workspace.workspaceFolders[0].uri.fsPath; + const ext = vscode.extensions.getExtension("flightcoders.neon-getaway"); + assert.ok(ext, "extension is loaded"); + const api = await ext.activate(); + + step("Commands are registered"); + const commands = await vscode.commands.getCommands(true); + for (const c of ["neonGetaway.play", "neonGetaway.reset"]) assert.ok(commands.includes(c), c); + + step("Saving a file while the game is closed earns $25, waiting in the status bar"); + const cart = await vscode.workspace.openTextDocument(path.join(folder, "src", "cart.js")); + const editor = await vscode.window.showTextDocument(cart); + await editor.edit(e => e.insert(new vscode.Position(0, 0), "// pay day\n")); + await cart.save(); + const firstSave = Date.now(); + await until(() => api.pending() === 25, "a $25 paycheck pending"); + + step("The game opens in a tab, its scripts run under the content security policy, and it says it's ready"); + await vscode.commands.executeCommand("neonGetaway.play"); + assert.ok(api.isOpen()); + await until(() => api.isReady(), "the game to start", 45000); + + step("The game collects the paycheck and saves the new cash"); + await until(() => api.pending() === 0, "the paycheck collected"); + const save = await until(() => api.save(), "a save"); + assert.equal(save.cash, 300 + 25, "starting cash plus the paycheck"); + assert.equal(save.stats.paychecks, 25); + + step("A save while playing pays straight into the open game, and a second save seconds later doesn't pay again"); + await wait(Math.max(0, 5300 - (Date.now() - firstSave))); + const saveAgain = async line => { + const edit = new vscode.WorkspaceEdit(); + edit.insert(cart.uri, new vscode.Position(0, 0), line); + await vscode.workspace.applyEdit(edit); + await cart.save(); + }; + await saveAgain("// again\n"); + await saveAgain("// and again\n"); + await until(() => api.save().cash === 350 && api.pending() === 0, "the second paycheck in the game"); + await wait(800); + assert.equal(api.save().cash, 350, "only one of the two quick saves paid"); + assert.equal(api.save().stats.paychecks, 50); + + step("Running the command again shows the same game instead of a second one"); + await vscode.commands.executeCommand("neonGetaway.play"); + assert.ok(api.isOpen()); + + step("Closing the tab and opening it again keeps the progress"); + await vscode.commands.executeCommand("workbench.action.closeActiveEditor"); + await until(() => !api.isOpen(), "the game to close"); + await vscode.commands.executeCommand("neonGetaway.play"); + await until(() => api.isReady(), "the game to start again", 45000); + assert.equal(api.save().cash, 350); +} diff --git a/extensions/neon-getaway/test/pay.test.mjs b/extensions/neon-getaway/test/pay.test.mjs new file mode 100644 index 0000000..4d56e51 --- /dev/null +++ b/extensions/neon-getaway/test/pay.test.mjs @@ -0,0 +1,40 @@ +import { test } from 'node:test'; +import assert from 'node:assert/strict'; +import { createRequire } from 'node:module'; + +const require = createRequire(import.meta.url); +const { onSave, collected, EMPTY, DAILY_CAP, PER_SAVE } = require('../out/pay.js'); + +const at = (h, m, s = 0, day = 24) => new Date(2026, 10, day, h, m, s); + +test('each save pays $25', () => { + const { state, paid } = onSave(EMPTY, at(9, 0)); + assert.equal(paid, PER_SAVE); + assert.equal(state.pending, 25); +}); + +test('saves seconds apart (autosave, save all) pay once', () => { + let s = onSave(EMPTY, at(9, 0, 0)).state; + const second = onSave(s, at(9, 0, 2)); + assert.equal(second.paid, 0); + s = onSave(second.state, at(9, 0, 6)).state; + assert.equal(s.pending, 50); +}); + +test('a day pays at most $1,000, and the next day starts fresh', () => { + let s = EMPTY; + for (let k = 0; k < 60; k++) s = onSave(s, at(9, k)).state; + assert.equal(s.earnedToday, DAILY_CAP); + assert.equal(s.pending, DAILY_CAP); + const tomorrow = onSave(s, at(9, 0, 0, 25)); + assert.equal(tomorrow.paid, 25); + assert.equal(tomorrow.state.earnedToday, 25); +}); + +test('the game collecting cash takes it out of pending', () => { + let s = onSave(EMPTY, at(9, 0)).state; + s = onSave(s, at(9, 1)).state; + assert.equal(collected(s, 50).pending, 0); + assert.equal(collected(s, 999).pending, 0); + assert.equal(collected(s, -5).pending, 50); +}); diff --git a/extensions/neon-getaway/tsconfig.json b/extensions/neon-getaway/tsconfig.json new file mode 100644 index 0000000..9da1549 --- /dev/null +++ b/extensions/neon-getaway/tsconfig.json @@ -0,0 +1,23 @@ +{ + "compilerOptions": { + "module": "commonjs", + "target": "ES2022", + "lib": [ + "ES2022", + "DOM" + ], + "outDir": "out", + "rootDir": "src", + "strict": true, + "esModuleInterop": true, + "skipLibCheck": true, + "sourceMap": false, + "noUnusedLocals": true, + "noUnusedParameters": true, + "noImplicitReturns": true, + "noFallthroughCasesInSwitch": true + }, + "include": [ + "src" + ] +}