feat(store): add store and marketplace item views and image sources

Add catalogue filters, item detail views, and purchase and resale
actions. Resolve images from the player's asset pack, public image
URLs, or local game data. Add a utility for creating the optional
local asset pack.

Type checking and JavaScript syntax checks passed. Embedded browser
appearance and in-game behavior still need acceptance.
This commit is contained in:
N0VAN0M4LY committed 2026-11-26 07:12:38 +08:00
1 parent a73635407d
commit 98812fa9c2
39 files changed
+1309 -400

No files matched your search

@@ -1,4 +1,4 @@
/** Typed content of tuning/new-profile.jsonc: a new save's starting money (local verification). */
/** Typed starting balances loaded from tuning/new-profile.jsonc. */
import type { TuningReader } from '../tuning/tuning-reader.ts';
import type { Balance } from './profile-currency.ts';
@@ -1,7 +1,7 @@
/**
* A new account's profile: Gaijin's own new-account template from the player's game files
* (config/default_user.blk), plus the offline starting content (starting-content.ts) and the
* starting money (tuning/new-profile.jsonc; local verification), which the template does not have.
* starting balances defined separately in tuning/new-profile.jsonc.
*/
import type { BlkBlock } from '@wto/blk';
import { setGjnCents, setGoldenEagles, setSilverLions } from './profile-currency.ts';
@@ -4,7 +4,7 @@
* weaponPresets{
* fa_18d_late{
* custom0{
* name:t="编组方案 #1"
* name:t="Custom preset #1"
* Weapon{ preset:t="aim_120_default_slot4" slot:i=4 }
* ...
* }
@@ -7,10 +7,10 @@
* only offer reserve vehicles the player owns (scripts/slotbar/slotbarStateData.nut
* checkReserveUnit: isBought), so without them a new player only has aircraft.
* - Rank I open for research in every country's branches (profile-eras.ts), as online;
* without it the whole tech tree is locked (local verification). Higher ranks open through
* this allows research to start immediately. Higher ranks open through
* research.
* - The base tutorials that gate a difficulty count as completed on every difficulty, so no
* game mode asks for a tutorial first (user quotes 87, 92; the tutorials stay playable).
* game mode requires a tutorial first. The tutorials remain playable.
* The stock rule (gui.vromfs.bin scripts/tutorials/tutorialsState.nut isDiffUnlocked)
* locks historical and simulator battles for a vehicle type until the player has either
* played 60 s in one of them or completed the type's required tutorial on that difficulty;