Commit Graph

157 Commits

Author SHA1 Message Date
Matt 92306823cb Merge pull request 'cbc: disable cannon self-failure (RNG self-destruct)' (#47) from config/cbc-disable-self-failure into main 2026-05-28 19:39:44 +00:00
Matt c723a42628 cbc: disable all cannon self-failure
Cannons are expensive to build; users were losing them to RNG
self-destruction (squib, barrel charge burst, overload, interrupted
ignition, catastrophic failure). Per-cannon failure is configurable
via a single master switch in createbigcannons-server.toml:

  [failure]
  disableAllCannonFailure = true

This zeroes out all six failure paths in one go. Applied to the live
server and tracked here under defaultconfigs/ so future server resets
preserve it.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-28 19:39:44 +00:00
Matt 83abbc90d3 Merge pull request 'pack: v0.28.0 - Steam n Rails + Copycats+/Aero weight' (#46) from feature/v0.28.0-rails-and-aero-bridge into main 2026-05-28 19:30:04 +00:00
Matt 5a24801f48 pack: v0.28.0 — Steam 'n' Rails (port) + Copycats+/Aero weight bridge
Adds two mods on top of v0.27.0:

  - Create: Steam 'n' Rails 0.2.0+neoforge-mc1.21.1 (stable). The
    official Steam 'n' Rails team skipped 1.21.1, so this is the
    "Porters of Railways" community port — actively maintained,
    310k downloads on the beta line and 0.2.0 just hit stable.
    Brings train QoL: track tools, semaphores, conductor cap,
    smokestacks, narrow-gauge tracks, etc.

  - Copycats+ aeronautics weight 1.1.1. Small interop mod so
    copycat blocks contribute weight to Create: Aeronautics
    contraptions instead of being treated as massless. ~15KB.

All deps satisfied by mods already in the pack (Create, Copycats+,
Sable, Create: Aeronautics).

Tested live: server boots, port 25565 binds, KubeJS loads 0/0 errors,
aerocopycats logs HELLO FROM COMMON SETUP, Railways registers
55+53+238 entries across its three creative tabs. No new crashes.

Known noise: Steam 'n' Rails ships optional loot tables for tracks
of wood types from many other mods (TwilightForest, BYG, TFC, Blue
Skies, Hex Casting, BoP, etc.). Mods absent from this pack produce
~276 'Unknown registry key' ERROR lines once at boot. Harmless —
loot tables for items that don't exist just fail to parse and get
skipped. Standard behavior for Rails on lean packs.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-28 19:29:43 +00:00
Matt 5e816e1a7a Merge pull request 'kubejs: use kubejs-create builder API for flax press recipe' (#45) from refactor/supplementaries-bridges-kubejs-create-api into main 2026-05-28 19:08:42 +00:00
Matt d2cc179ebd kubejs: use kubejs-create builder API for flax press recipe
Now that v0.27.0 ships kubejs_create, the high-level
event.recipes.create.pressing(out, in) builder works, replacing the
raw event.custom({type: 'create:pressing', ...}) JSON shim we needed
before.

Verified live on the server -- recipe loads cleanly:
[bns/supplementaries_bridges] added flax -> string press recipe

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-28 18:55:43 +00:00
Matt 847ca460ff Merge pull request 'pack: v0.27.0 - Create QoL + aesthetic batch (KubeJS Create + Encased + Bells & Whistles)' (#44) from feature/v0.27.0-create-batch into main 2026-05-28 18:51:06 +00:00
Matt 96d4608e4c pack: v0.27.0 — Create QoL + aesthetic batch
Three small Create addons, no overlap with current 18-mod Create stack:

  + kubejs-create v2101.3.1-build.18
      Recipe builders for KubeJS scripts. Will replace the raw
      Create:pressing JSON in supplementaries_bridges.js with a
      cleaner event.recipes.create.* call.

  + create-encased v1.8.1-ht1
      Encased/cased variants of Create kinetic blocks (shafts,
      gearboxes, cogwheels in compact casings) for cleaner builds.

  + bellsandwhistles v0.4.7-1.21.1
      Train whistles, bells, signal lights, station decoration.

All three already deployed live; pack-version.json bumped, MC
server restarted to sync. No mod-load errors.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-28 13:55:55 +00:00
Matt 61321e5fcd Merge pull request 'ops: cap ZFS ARC at 2GB on glados' (#43) from ops/zfs-arc-cap into main 2026-05-28 13:52:59 +00:00
Matt a8ff660114 Merge pull request 'backup-scheduler: dont replay missed daily slots on startup' (#42) from fix/backup-scheduler-no-replay into main 2026-05-28 13:52:58 +00:00
Matt ab63908d04 Merge pull request 'v0.24.0 -> v0.26.0: content + storage batch' (#41) from feature/v0.26.0-content-and-storage-batch into main 2026-05-28 13:52:56 +00:00
Matt fd211aae51 ops: cap ZFS ARC at 2GB on glados
The cold ZFS pool is a backup tier only — hot data (MC world, Gitea,
Directus DB, containers) lives on NVMe LVM, not ZFS. So ARC's default of
50% RAM was wasted: nothing it could cache was hot enough to matter, and
the ~16GB cache crowded MC out of RAM, pushing 2.4GB into swap.

This file lives in the repo for reproducibility; it gets dropped into
/etc/modprobe.d/ on the host and applied immediately via
/sys/module/zfs/parameters/zfs_arc_{max,min}.

Effect on glados:
  before:  used=27/31GB, free=748MB, ARC=15.6GB
  after:   used=~10GB, free=~14GB, ARC=1.0GB (1-2GB range)

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-27 23:05:52 +00:00
Matt f81bb29fda backup-scheduler: don't replay missed daily slots on startup
The wake loop's daily-times branch was firing one missed slot per minute
on service restart. With a schedule like "00:00,04:00,08:00,12:00,16:00,
20:00" and a restart at 19:00, the wrapper would catch up by firing 5
backups at 1-minute intervals -- each a full-world zip of the same
in-memory world. Pure waste: the live world hasn't diverged across the
missed clock slots, the snapshots would be near-identical, and the rapid
save-off/save-on churn impacts player experience.

Source comment already documented the intended behaviour ("Doesn't catch
up if the server was off when a slot passed -- daily/interval backups
don't need replay logic.") but the code didn't implement it.

Fix: in Start(), pre-populate _firedToday with all times <= now so the
wake loop only fires future slots for the rest of today.

Tested live on glados: switched schedule to clock-aligned daily-times
after deploying the fix, zero catch-up backups fired in the 90s window
after restart (vs 5+ before the fix).

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-27 19:31:32 +00:00
Matt 9f0c9e262a pack: content + storage batch v0.24.0 -> v0.26.0
Mods added (in lockfile):
  v0.24.0  YUNG's structure mods (9):
           - Better Dungeons, Better Mineshafts, Better Ocean
             Monuments, Better Nether Fortresses, Better End Island,
             Better Witch Huts, Better Desert Temples, Better Jungle
             Temples, Bridges, Extras
  v0.24.1  Create: Radars (Aeronautics-compatible from v0.4.5.1+)
  v0.24.2  Ars Creo + Create Ars Compact (the latter removed in 0.25.0)
  v0.24.3  FallingTree (whole-tree chop on axe hit)
  v0.24.4  Copycats+, Create: Connected, Create: Interiors
  v0.24.5  Create: Power Loader (Aeronautics-airship chunkloading)
  v0.24.6  -- KubeJS bridges only (see below)
  v0.24.7  -- Patchouli welcome book attempt 1 (kubejs/data) -- failed
  v0.24.8  -- Patchouli attempt 2 (assets/data split) -- failed
  v0.24.9  -- Patchouli attempt 3 (patchouli_books/ root path) -- worked
  v0.25.0  REMOVED Create Ars Compact (broken sauce:source_fluid recipes,
           no public tracker, half-finished compat layer);
           added Create: Dragons Plus, Create: Enchantment Industry
  v0.26.0  Sophisticated Core/Storage/Backpacks/Create-Integration,
           Create: Additional Logistics

KubeJS additions:
  - supplementaries_bridges.js: flax -> 2x string via Create Press,
    Plunderer drops 1-3 spurs via EntityEvents.drops
  - recipes_numismatics.js: renamed COIN_IDS -> COIN_RECIPE_REMOVE_IDS
    to avoid Rhino global-scope collision with numismatics_tooltips.js,
    added sprocket to the removal list (was missing)
  - welcome.js: migrated from vanilla written_book (broken Filterable
    codec in 1.21) to Patchouli book at patchouli_books/manual/

Patchouli manual:
  - 5 entries (Welcome, Waystones, Money, Plots, Rules) under one
    "Server Basics" category
  - Lives at pack/overrides/patchouli_books/ (root path) -- this is
    the modpack-author path per Patchouli docs, NOT data/+assets/
    which is for mods bundled in jars
  - Book id: patchouli:manual (default namespace in this mode)

All v0.24-v0.26 work has been live on the server and tested.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-24 22:42:32 +00:00
Matt 0cc8effce0 Merge pull request 'v0.23.0: Building mods batch (Tier 1 + 2 minus Chipped, + Effortless Building)' (#40) from feature/v0.23.0-building-batch into main 2026-05-23 18:26:18 +00:00
Matt 42bec33aa1 pack: building-mods batch v0.23.0 (10 mods)
Tier 1 essentials for the spawn-town aesthetic:
- Macaws Roofs 2.3.2          proper sloped roofs (no more staircase hacks)
- Macaws Paths and Pavings 1.1.1  streets + sidewalks + plot boundaries
- Macaws Bridges 3.1.2         covered walkways + market awnings
- Macaws Lights and Lamps 1.1.5  streetlights + decorative lighting
- Supplementaries 3.6.5        vanilla++ decoration (signposts!), needs Moonlight

Tier 2 (skipping Chipped per user -- discuss JEI clutter separately):
- Macaws Windows 2.4.2         window variety
- Macaws Doors 1.1.5           door variety
- Create Deco 2.1.3            Create-aesthetic decoration, fits pack vibe

Bonus:
- Effortless Building 4.1      WorldEdit-lite survival building tool
- Moonlight 3.0.14             required dep for Supplementaries

All side=both. Total added ~25 MB. 62 lockfile entries now.
Pack 0.22.6 -> 0.23.0.
Pre-flight Check-Deps clean: all 87 mod IDs (incl jar-in-jar bundles)
satisfied.
2026-05-23 18:26:18 +00:00
Matt 0d74c9ef97 Merge pull request 'plots: actual coin values (non-uniform chain)' (#39) from fix/coin-values-actual into main 2026-05-23 18:19:37 +00:00
Matt a41ae52d9b plots: AUTHORITATIVE coin values (non-uniform), 0.22.5 -> 0.22.6
User confirmed in-game tooltip values:
  spur=1, bevel=8, sprocket=16, cog=64, crown=512, sun=4096.

Chain is non-uniform (x8, x2, x4, x8, x8). My earlier guesses
(uniform x8, assuming Sun=64 Cogs) gave consistent but wrong
intermediate values. Now sourced from the mod's own tooltip, not
triangulated.

Plot prices at 100/250/600 spurs now mean roughly:
  100 spurs = 6 bevels + 4 spurs (1 sprocket + 5 bevels + 4 spurs)
  250 spurs = 3 cogs + 3 bevels + 2 spurs
  600 spurs = 9 cogs + 3 bevels (... still small change tier)

User-side: edit PLOT_DEFS in plots.js to set real prices once the
spawn marketplace and economy scale are decided.
2026-05-23 18:19:37 +00:00
Matt 59d50c9ee6 Merge pull request 'plots: correct coin chain (6 denoms incl sprocket)' (#38) from fix/coin-values-with-sprocket into main 2026-05-23 17:59:58 +00:00
Matt b85eef04bd plots: correct Numismatics coin chain (6 denoms incl sprocket), 0.22.4 -> 0.22.5
Was: 5-denom x8 chain (spur=1, bevel=8, cog=64, crown=512, sun=4096).
Now: 6-denom x8 chain with sprocket inserted between bevel and cog.

Verified in-game (user reported Sun = 64 Cogs, which only fits these
values: spur=1, bevel=8, sprocket=64, cog=512, crown=4096, sun=32768).

Plot purchase math (countCoins, takeCoins, giveCoins) was using the
old 5-denom map: cog would have been counted as 64 spurs when it's
actually 512, and sprockets weren't counted at all. Plot prices remain
at 100/250/600 spurs which are still appropriate small-change amounts;
user can edit PLOT_DEFS to raise once playtesting confirms desired
economy scale.
2026-05-23 17:59:57 +00:00
Matt 179486bd2c Merge pull request 'Simplify coin tooltips + include sprocket' (#37) from fix/coin-tooltips-simplify into main 2026-05-23 17:55:44 +00:00
Matt fad867976f tooltips: simplify coin tooltips (Numismatics already shows value), include sprocket, 0.22.3 -> 0.22.4
Three corrections per user feedback:
1. Drop the conversion-crib lines -- Numismatics' built-in tooltip
   already shows 'Value: N spurs' so our added lines were duplicate.
2. Include sprocket (numismatics:sprocket) -- the 6th denomination
   I missed when first writing the script. Full set: spur, bevel,
   sprocket, cog, crown, sun.
3. Keep only the actually-useful hint: 'Right-click a Bank Teller
   block to convert denominations' -- the one piece of info that
   isn't on the mod's own tooltip.

Decision punted (deliberately): no 8-spurs-shapeless-to-1-bevel
crafting recipes. The Bank Teller is the spawn-economy anchor;
crafting recipes would let players bypass the bank entirely. Players
who want local conversion can place their own Teller -- which is the
intended Numismatics design.
2026-05-23 17:55:44 +00:00
Matt 858fa690ba Merge pull request 'Build-Pack: tweak jars default to side=server (urgent client fix)' (#36) from fix/tweak-jars-server-only into main 2026-05-23 17:40:35 +00:00
Matt 135ecf4a5a Build-Pack: default tweak jars to side=server, 0.22.2 -> 0.22.3
URGENT client-side fix. brassandsigil_tweaks-1.0.0.jar (built from
pack/tweaks/ into pack/overrides/mods/) declares lithostitched as a
hard dependency in its mods.toml. lithostitched is tagged side=server
in the lockfile because it's worldgen-only. brassandsigil_tweaks had
no explicit side tag so Build-Pack defaulted it to side=both. Clients
downloaded the tweak jar but not the dep -> NeoForge refused to start
with 'Mod brassandsigil_tweaks requires lithostitched 1.7 or above'.

Fix: Build-Pack now injects side='server' on any local-override file
under mods/. All tweak jars are data-only (worldgen modifiers, recipe
overrides) and pure server-side. If a future tweak is actually client-
relevant, this rule will need a per-file exception.

Tested in build output -- the brassandsigil_tweaks entry now shows
side='server' in the generated manifest.
2026-05-23 17:40:34 +00:00
Matt 5813c7555e Merge pull request 'tooltips: correct event name to modifyTooltips' (#35) from fix/tooltip-event-name into main 2026-05-23 17:37:31 +00:00
Matt e1a77d2e19 tooltips: ItemEvents.tooltip -> ItemEvents.modifyTooltips, 0.22.1 -> 0.22.2
KubeJS 2101.x has ModifyItemTooltipsKubeEvent (the modify-tooltips API);
the older 'tooltip' event name doesn't exist in this version.
2026-05-23 17:37:30 +00:00
Matt 31f7d5428c Merge pull request 'Numismatics: conversion-crib coin tooltips' (#34) from feature/numismatics-tooltips into main 2026-05-23 17:36:03 +00:00
Matt f19e7b187e numismatics: add conversion-crib tooltip to each coin, 0.22.0 -> 0.22.1
Numismatics' x8 uniform chain isn't intuitive. Mod values are
hardcoded so we cant fix the ratios, but we can put the conversion
table directly on each coins tooltip via KubeJS ItemEvents.tooltip.
Players hover any coin -> see how it relates to the others + a hint
to use Bank Teller for on-the-fly conversion.

~25 lines, ItemEvents.tooltip hot path is cached per item-id so no
performance concern.
2026-05-23 17:36:02 +00:00
Matt f3134d23c4 Merge pull request 'Add Configured 2.6.3 (CurseForge)' (#33) from feature/add-configured into main 2026-05-23 17:30:53 +00:00
Matt f72be58c6a pack: add MrCrayfish's Configured 2.6.3 (CurseForge), bump to 0.22.0
Configured is the in-game config GUI library JEI suggests when you
press its wrench icon (and the same library a bunch of other mods use
for their config screens). CurseForge-only (not on Modrinth) so we
add as source: curseforge -- following the same pattern as the FTB
mods already in the lockfile.

Tagged side=client because Configured is purely a client-side config
UI provider; the server doesn't need it. Server-side filter will skip
it on sync.

Filename gotcha noted for future CF adds: the CF web page shows the
mod with a friendly name like 'Configured 2.6.3.jar', but the actual
file on mediafilez.forgecdn.net is named 'configured-neoforge-1.21.1
-2.6.3.jar'. Use the CDN filename in the URL, not the web display
name.
2026-05-23 17:30:52 +00:00
Matt 8e816bc067 Merge pull request 'launcher: record 0.4.10 version bump' (#32) from chore/launcher-version-0.4.10 into main 2026-05-23 17:06:30 +00:00
Matt f757c2d31c launcher: record version bump to 0.4.10
The 0.4.10 build was already deployed (replacing the broken 0.4.9 that
shipped without launcher-config.json embedded). This commit just makes
the repo match what's live so a future 'git status' isn't dirty.
2026-05-23 17:06:30 +00:00
Matt 804d085e36 Merge pull request 'rpo: add required:true to force-enable CC pack' (#31) from feature/rpo-required-true into main 2026-05-23 17:05:53 +00:00
Matt 05e700cfc7 rpo: try 'required: true' to force-enable CC ReCreated, 0.21.2 -> 0.21.3
Players with an existing options.txt (i.e. anyone who has launched MC
once) don't get the 'default_packs' applied -- RPO only treats those as
defaults for fresh installs.

Adding 'required: true' to the override entry on the assumption that
the field forces the pack to be enabled on every launch regardless of
player choice. Decompiled the jar for string constants and 'required'
appears alongside 'force_compatible' as a known key.

If the field name is wrong RPO will silently ignore it -- no harm, easy
iteration.
2026-05-23 17:05:52 +00:00
Matt a139196f77 Merge pull request 'launcher: EnableWindowsTargeting for Linux builds' (#30) from feature/cross-compile-launcher-from-linux into main 2026-05-23 16:40:24 +00:00
Matt 4315696136 launcher: add EnableWindowsTargeting for cross-compile from Linux
Microsoft.NET.Sdk.WindowsDesktop emits NETSDK1100 when a Windows-
targeting project is built from a non-Windows host. Setting
EnableWindowsTargeting=true opts in to the cross-compile path, which
works on Linux as long as the WindowsDesktop SDK files are present.

On glados they were copied from a Windows .NET 8 SDK archive into
/usr/lib/dotnet/sdk/8.0.126/Sdks/Microsoft.NET.Sdk.WindowsDesktop/
and /usr/lib/dotnet/packs/Microsoft.WindowsDesktop.App.Ref/. This is
a one-time setup per Linux host -- see the bridge-claude memory note.

No-op on Windows hosts (the flag has no effect when the SDK is native).
Both PC builds and glados builds now produce the same output.
2026-05-23 16:40:23 +00:00
Matt af45997a8b Merge pull request 'launcher: version 0.4.9' (#29) from chore/launcher-version-bump into main 2026-05-23 16:35:13 +00:00
Matt 444cadd921 launcher: bump version 0.4.8 -> 0.4.9 for session-refresh fix
So existing 0.4.8 installs see the upgrade banner in their current
launcher after the next deploy. The actual session-refresh code change
landed in the previous commit (DoLaunchAsync pre-launch refresh).
2026-05-23 16:35:13 +00:00
Matt 36acbafea5 Merge pull request 'launcher: refresh Microsoft session before launch' (#28) from feature/launcher-pre-launch-refresh into main 2026-05-23 16:31:17 +00:00
Matt 8e00526d27 launcher: refresh Microsoft session right before launch
Microsoft access tokens have a ~1 hour TTL. The launcher cached the
MSession once at sign-in and re-used it on every Play click, so leaving
the launcher open for >1 hour and then hitting Play sent stale
credentials to MC -- Mojang's session check on the server then rejected
the join with "Invalid session".

Fix: in DoLaunchAsync, before assembling the MC launch command, call
_auth.TryAuthenticateSilentlyAsync(). XboxAuthNet's silent flow uses
the cached refresh token (~14 day TTL) to mint a fresh access token
transparently. On success ApplySession swaps in the new MSession and
we launch with valid credentials. On failure (refresh token also
stale) the launcher prompts the player to sign in again -- they keep
the launcher open, hit Sign In, no MC restart needed.

No new dependencies, no UI change beyond the brief "Refreshing
session..." status line, no perf cost beyond the ~500ms HTTP roundtrip
to Microsoft each launch.

Bump the launcher version in launcher/ModpackLauncher.csproj before
publishing so old launcher installs see the upgrade banner.
2026-05-23 16:31:17 +00:00
Matt 67870f0648 Merge pull request 'Drop jei_hides.js (wrong JEI API binding)' (#27) from fix/drop-jei-hides into main 2026-05-23 16:22:01 +00:00
Matt d24f7f03a3 kubejs: drop jei_hides.js (wrong API binding), 0.21.1 -> 0.21.2
Two consecutive client_scripts errors traced to jei_hides.js:
1. Array-spread syntax not supported by Rhino (fixed in 0.21.1)
2. JEIEvents global is not defined in KubeJS 2101.7 -- the actual JEI
   event API uses classes like JEIRemoveEntriesKubeEvent but the binding
   name is something different we haven't identified yet.

Rather than ship more guesses, drop the script entirely. Functional
impact is minimal: recipes for waystones + coins are still removed
server-side (recipes_waystones.js, recipes_numismatics.js), so players
cannot craft these items even if they appear in JEI search. The only
loss is some JEI clutter.

When we identify the correct JEI hide API in KubeJS 2101.x, can add
back as kubejs/client_scripts/jei_hides.js with the right binding.
2026-05-23 16:22:01 +00:00
Matt 28a02d0ced Merge pull request 'jei_hides: Rhino-compatible (no array spread)' (#26) from fix/jei-hides-rhino-spread into main 2026-05-23 16:18:51 +00:00
Matt d5fd2c97e9 jei_hides: use .concat instead of array-spread (Rhino compat). 0.21.0 -> 0.21.1.
KubeJS uses Rhino as its JS engine, which doesn't support array-spread
syntax (`[...a, ...b]`). The line `[...WAYSTONE_ITEMS, ...COIN_ITEMS]
.forEach(...)` threw EvaluatorException: syntax error at jei_hides.js:46
on client launch, surfacing the KubeJS client script errors dialog.

Fix: use Array.prototype.concat() which is universal JS. Also extracted
the hide-quietly helper into a named function for readability.
2026-05-23 16:18:50 +00:00
Matt ae061a5035 Merge pull request 'v0.21.0: Plot system V1' (#25) from feature/plots-v1 into main 2026-05-23 16:02:05 +00:00
Matt 6264785f2c plots: v1 spawn-commercial-plots system, bump to 0.21.0
/bns plot list|info|buy|release|reload. Single ~316-line file with
clear sections. Hardcoded PLOT_DEFS Map (3 example plots), ownership
state in server.persistentData.bnsPlots, best-effort Numismatics +
FTB Chunks integration (will be verified in playtest). See file
header for full design notes.
2026-05-23 16:01:47 +00:00
Matt 998ec21bb5 Merge pull request 'Fix bns_admin command registration' (#24) from fix/bns-admin-int-range into main 2026-05-23 15:41:34 +00:00
Matt aa881bfc65 bns_admin: drop INTEGER range args (KubeJS wrapper doesn't expose them), validate in handler instead. 0.20.0 -> 0.20.1. 2026-05-23 15:41:34 +00:00
Matt 3cec2cb69b Merge pull request 'v0.20.0: KubeJS tidying + admin commands' (#23) from feature/v0.20.0-tidying into main 2026-05-23 15:40:00 +00:00
Matt c699dcc77b pack: KubeJS tidying + admin commands, bump to 0.20.0
Tidying pass on the KubeJS suite before plot system V1 lands. Sets up
the file structure + conventions + diagnostics so the larger plot
system has a clean foundation.

Changes:

1. NEW kubejs/README.md
   File layout doc + conventions: logging prefix [bns/<module>],
   persistent-data key naming (bns* prefix), one concern per file,
   performance discipline (O(1) lookups, no polling).

2. Split economy_policy.js -> recipes_waystones.js + recipes_numismatics.js
   Single-concern files. recipes_waystones removes ALL waystones
   crafting (welcome.js distributes the only allowed waystone instead).
   recipes_numismatics removes the 5 coin-denomination crafts.

3. NEW kubejs/server_scripts/bns_admin.js
   /bns admin subcommands for OP diagnostics:
     - info                       calling player's flags+counts
     - waystone-count <player>    read stored count
     - waystone-set <player> <n>  override stored count
     - reset-welcome <player>     clear bnsWelcomeGranted -- replays
                                  the welcome grant on next login
   Registered via ServerEvents.commandRegistry with Brigadier tree,
   permission level 2 (OP). No performance cost (operator-triggered only).

4. Logging added to waystones_policy.js + welcome.js
   Every action prints `[bns/<module>] ...` so server logs can be
   filtered with `journalctl ... | grep '\[bns/'`.

Performance discipline applied:
- All event-handler lookups use Set.has (O(1)), not Array.includes
- No periodic tick polling anywhere
- No network calls in event handlers
- console.info is cheap (no string format unless logged)

Bumps to 0.20.0. Plot system V1 follows in v0.21.x as a separate
multi-file submodule under server_scripts/plots/.
2026-05-23 15:39:59 +00:00