Repository navigation
LiveMarket 0.4.0
Crash-safe persistence, chart ranges, per-item volatility, and a trading pause.
What's new
- Crash-safe persistence —
data.ymlis now written atomically (temp file + atomic move), the previous file is kept asdata.yml.bak, and saves are sequenced so an older async snapshot can never overwrite a newer one. Ifdata.ymlis ever unreadable at startup, LiveMarket restores fromdata.yml.bakwith a console warning instead of silently resetting every price. - Chart ranges in the GUI — the item detail view has a clock button that cycles the price chart through the last 9, 25, or 50 recorded points; the sparkline follows the same range. Price decay now records a history point whenever it moves a price, so charts show the drift between trades too.
- Per-item volatility — any item in
config.ymlcan override the global pricing pressure with its ownpressure-kandmax-move. Make diamonds sluggish and wheat wild, per item. - Admin trading pause —
/market pauseand/market resumefreeze all buying and selling while leaving browsing and price checks open. Setsettings.trading-enabled: falseto start the server paused.
Verified
End-to-end on Paper 1.21.11 with Vault, EssentialsX and PlaceholderAPI, using a bot player and the built-in debug mode: global vs per-item pricing math, the GUI range button, pause blocking buys and sellall while price queries still answer, prices surviving a restart, and a deliberately corrupted data.yml restored from backup (WHEAT 5.0 and DIAMOND 120.24 recovered exactly).
Install
Drop LiveMarket-0.4.0.jar into your server's plugins/ folder and restart. Requires Paper 1.21.x, Vault, and any Vault economy plugin (e.g. EssentialsX). PlaceholderAPI is optional. Existing config.yml / data.yml from 0.3.0 keep working; new options are documented in the bundled config.yml.