Traders
Traders reads the trader configuration of a DayZ server: which NPC sells what, at what buy and
sell price, with what stock. You use it when you run a server with TraderX, TraderPlus or Expansion Market and
want to find mistakes players can exploit, edit prices, rebalance the whole catalog from the
rarity of the loot, or move from TraderPlus to TraderX. You need a server profile folder (the
folder given to the server with -profiles=, holding TraderX/, TraderPlus/ or ExpansionMod/); a sample
profile is provided when you have none. For the class checks you need the DayZ folder set in
Settings, and for the rarity checks a mission folder.
The page reads configuration files only. It never opens player data: bank accounts, vaults,
garages, insurance or licence records keyed by SteamID (TraderXDatabase/,
TraderPlusDatabase/), nor logs. Of ExpansionMod/ it reads Market/ and Traders/ only: the
ATM accounts, groups and personal storage next to them are left alone.
The screen
- Header: badges while something loads, the number of changes not written yet, Following saves (reload when the files are saved in another editor), Reload, and Review and write, the only way anything is written.
- Trader mod (line under the toolbar): the trader mods the page knows. TraderX, TraderPlus and Expansion Market are supported; Trader by Dr_J0nes is not yet. The one of the open profile is marked with its file format; hover a name to see what the page does with it and which folder it looks for. With nothing open, a table gives the same per mod, and after opening a folder the page cannot read, a message says what it looked for and which other trader mod it found there.
- Toolbar: the recent profiles, Open profile…, Import TraderPlus…, Rarity from (the
mission whose
types.xmlgives the rarity, and a folder button to pick another one), the number of game classes and mods loaded, a badge with the mod and catalog format detected, and the tabs. - Products tab: on the left, All products, In no category, then each trader with its categories and the categories no trader lists. In the centre, a search box, the bulk price row and the table (icon, in-game name, buy, sell, max stock, coefficient, quantity; a badge counts the product's problems). On the right, the inspector of the selected product: rarity, file and line, categories, findings, and the editable buy, sell and max stock.
- Audit tab: every finding with its severity, check code, message, fix and location. Filter by severity or by check. A click on a row opens the product; Open opens the file at the line in your external editor.
- Plan tab: the economy intent on the left, Compute the plan, and the result: products that change with old and new values and the reason, products kept and why.
- Settings tab: the settings files of the mod on the left, a form for the selected file on the right (general settings, currencies, banking, garage, car lock, safe zones...).
- Backups tab: one row per write, with the files it replaced and Restore.
First steps
- Open the page and click Open profile…, then choose your server profile folder. Without a server, click Open the sample profile on the empty page.
- Next to Rarity from, choose the mission of your server (or pick its folder with the folder button).
- In the left pane, click a category of a trader. The table shows its products.
- Click a product. In the inspector, type a new buy price. The row gets an edited badge and the header counts one change not written.
- Open the Audit tab and read the errors first.
- Stop the server, click Review and write, check the diff, then Write.
Take the tour (in the app)
Common tasks
Find and fix what players can exploit
- Open the profile and choose the mission.
- Open the Audit tab and click Errors.
- Click a finding to open its product, or Open to edit the file in your editor.
- Fix the price in the inspector, then Review and write.
Raise or lower many prices at once
- In the Products tab, click a category or search, and tick the products to change (or tick none and use the scope "products shown").
- In the Prices row choose the scope, buy / sell / both,
+ %or= set, and a number (-10lowers by 10 %). - Click Apply: the prices are staged. Prices of
-1are kept. - Review and write.
Rebalance the catalog from rarity
- Choose the mission, open the Plan tab.
- Set the intent: starting money, reference share, sell ratio; leave the rest at its default at first.
- Compute the plan, read the changes and the kept products.
- Review and write in the plan's header. Tour of this workflow (in the app)
Change a setting (bank fee, safe zone, trader position)
- Open the Settings tab and click the file.
- Edit a field: hover its name for the meaning, type and default from the mod's code. In a list, the bin removes an element and Add appends a copy of the last one.
- Review and write.
Convert a TraderPlus profile to TraderX
- Click Import TraderPlus…, choose the TraderPlus profile folder, then a target profile folder that has no TraderX configuration yet.
- Read the preview: the files to create and the notes.
- Click Create. Nothing is overwritten and the TraderPlus files are not changed.
Undo a write
- Open the Backups tab.
- Click Restore on the row of that write. The current files are backed up first.
Start from a recipe
Its empty state lists the recipes for this page as chips (Set up a trader, Sell new items at the trader, Trader shop): a click starts one in Beans Assistant, which asks a few questions, proposes a plan and works step by step with checks. All recipes opens the whole catalogue. The help panel (F1) lists them too.
Examples
- A sample profile (in the app): a small TraderX profile (LEGACY format) written to
<temp>/beans-examples/trader-sample/: one trader, four categories, eleven vanilla items. Look at how a trader lists categories and a category lists products. It is written again each time you open the example, so edits made to it are reset. - The audit on the sample (in the app): the same profile on the Audit tab. Its night
vision goggles sell for 450 and cost 300 (
sell-above-buy). With a mission chosen, rarity findings can be added. - Settings forms on the sample (in the app): the same profile on the Settings tab: catalog format, general settings (the trader NPC), currencies.
Concepts
- Server profile: the folder passed to the server with
-profiles=. Mods keep their configuration and their data there. You can also give theTraderX/TraderPlusfolder or its config folder: the profile is found from it. - Supported mods: TraderX (contract version 1.0.2), TraderPlus V1 (2.5) and Expansion
Market (category files version 12, trader files version 13): read, audit, edit. Trader by
Dr_J0nes (
Trader/TraderConfig.txt) is recognised and named, but its files are not read: the page cannot open it yet. - Expansion Market layout, under
ExpansionMod/:Market/<Name>.json, one category per file with itsItems, andTraders/<Name>.json, one kind of trader per file with the categories it trades (file names ofMarketwithout.json, optionallyName:0buy only,Name:1buy and sell,Name:2sell only) and the currencies it accepts. A category file with"IsExchange": 1defines the currencies: its items are money, worth their price. - Expansion Market prices and stock: an item has a price range and a stock range. Its
price is
MaxPriceThresholdwhen the trader holdsMinStockThresholdof it and falls toMinPriceThresholdatMaxStockThreshold. Equal stock thresholds above 0 are static stock: always available, atMinPriceThreshold. Here the buy price isMinPriceThreshold(the price of an item in stock); when you change it,MaxPriceThresholdfollows in the same proportion. The sell price is a percentage of the buy price (SellPricePercent): editing it writes that percentage.-1means the trader zone's or the global percentage, which the page does not read and counts as 75. Max stock isMaxStockThreshold; unlimited is written as static stock (both at 1). - Not read for Expansion Market: the trader zones and their current stock, the global
MarketSettings.jsonand the trader NPCs. They are in the mission folder (expansion/traderzones,expansion/settings), not in the profile. - TraderX layout, under
TraderX/TraderXConfig/:SourceConfig.json(preferredFormat),TraderXGeneralSettings.json(traders, licences, accepted item states),TraderXCurrencySettings.json, and the catalog in one of three formats: LEGACY (Products/prod_<name>_NNN.json,Categories/cat_<name>_NNN.json, the file name is the id), CSV (Source/*.csv, compiled by the server at boot) or COMPILED (Compiled/*_compiled.json). AlsoTraderXPresets/presets_*.json, vehicle parkings, and the packagesTraderXBanking/,TraderXGarage/,TraderXCarLock/,TraderXSafeZone/. - TraderPlus layout, under
TraderPlus/TraderPlusConfig/:TraderPlusPriceConfig.json(categories with product linesClassName,Coefficient,MaxStock,TradeQuantity,BuyPrice,SellPrice),TraderPlusGeneralConfig.json,TraderPlusIDsConfig.json, vehicles, insurance, garage, banking, safe zone and logging settings. Product ids are shown as<category>/<class>. - Trader, category, product: a trader (an NPC) lists categories; a category lists
products; a product is a game class with a buy price (what the player pays), a sell price
(what the player gets), a max stock and a coefficient (how the price moves with the stock;
1 = flat).
-1means not for sale, cannot be sold, or unlimited stock. - Rarity: the mission's
db/types.xml(Central Economy) gives each item a nominal (how many the server keeps in the world), tiers and usages. The audit treats nominal 1 to 5 (or Tier4-only military up to 10) as rare. - Audit: checks the mod's own rules and references, the classes against the game data, money loops (sell above buy, buy here and sell there, magazines or boxes cheaper than their rounds) and, with a mission, prices and stock against rarity. Severity: error (broken or exploitable), warning (likely wrong), info.
- Plan and apply: a plan is a dry run computed from the profile, the game data, the mission and the intent; the same input gives the same plan. Writing it goes through the same review as manual edits.
- Writes: only changed values are written, the rest of each file keeps its formatting;
replaced files are copied to
<profile>/TraderX/.beans-trader-backups/<UTC time>/(TraderPlus/for TraderPlus), the newest 20 kept.
Pitfalls
- Editing while the server runs: the server saves its own copy over the files. The review dialog reminds you to stop it first.
- Reading a short audit as a clean profile: without the DayZ folder, classes are not checked; without a mission, rarity is not checked. The Audit tab says which data is missing.
- Classes from mods reported as unknown: add the mods the server runs in Central Economy → Mods; the audit uses that list.
- Editing in another editor with changes staged here: the page warns instead of reloading. Write or drop your changes, then Reload.
- A sell price above the buy price anywhere, even across two traders, is free money: these are errors in the audit.
- The import never overwrites a file: choose a target profile without TraderX configuration.
- The sample profile lives in the temp folder and is reset when you open it again: do not keep work there.
For agents
- Tools of
dzt:trader_detect(mod, format, counts of a profile),trader_audit(findings;mission,mods,other_mods,codes,min_severity,max),trader_plan(dry run of an intent, with the diff),trader_apply(writes a plan, or explicitchanges,values,arrays),trader_import(TraderPlus to TraderX),trader_schemas(JSON Schemas for hand editing). Related:ce_missions(mission folders),server_report(includes the trader audit). Commands:dzt trader-check <profile>,dzt trader-schemas <profile>. - Files read: the files the mod's contract lists under
<profile>/TraderX/or<profile>/TraderPlus/(the layouts above), the mission's types files for the rarity, and the game data already loaded for Central Economy. Player data, logs and backups are not read. - Files written: only through Review and write, Import (new files) and Restore: the
contract's files and the backup folder
.beans-trader-backups/. The sample is written to<temp>/beans-examples/trader-sample/. Settings keep the recent profiles and the mission. - The assistant sees: the profile path, the trader mod and its contract version, the current tab, the search text, the selected product (id and class), the number of pending changes and the audit's warnings and errors. It offers the action "Audit my traders".
- Anchors for
studio_guide:traders-open,traders-mission,traders-tab-audit,traders-reviewand the others listed in the page's guide file. - The format reference, audit codes and pricing formula are in
docs/TRADERS.md.
See also
- Central Economy: the mission's types.xml and the mods list the audit uses.
- Launcher: the server instances; stop the server before writing.
- Settings: the DayZ folder and the external editor.
- The Workbench