Vǫrðr Forge Steam page

Characters and Gameplay

Shops

A merchant's counter: what they sell, what they buy, what it costs and how prices move. Every project starts with the rules games have always had: a merchant sells at the item's price, pays half of it, has endless money and never restocks. Edit > Project Settings > MONEY > Shops holds the rules every merchant follows, and each shop can set its own in the Shop Editor or the NPC Portfolio.

The Shop Editor

Tools > Shop Editor... opens the Asset Manager on the project's shops. Opening a shop file from the Content Drawer opens the same page.

The Shop Editor on the default shop: the merchant's settings, the project's items and the wares.
The Shop Editor on the default shop: the merchant's settings, the project's items and the wares.
Shops
Every shop in the project, with how many wares it sells. Click one to edit it. New, Rename, Duplicate and Delete sit under the list; New, Rename and Duplicate take the name in a box above the buttons, and Enter makes it.
Wares
The shop's money and merchant settings, then the project's items on the left and the shop's wares on the right. Pick an item and press >> to add it; << takes the picked ware away. Each ware has its count (- at 1 makes it unlimited), its own price and costs, and its currency, as below.
Preview
The counter as the game draws it, in the shop's layout and style, beside the wares when the page is wide enough; otherwise Wares and Preview switch between the two.
Look
The shop's Layout and Interface style, on the right.
Market
When the project has regions, the shop's Region: Where it stands prices by the region around the merchant, or pick one. See Prices by region below.
Merchants
The villagers on the project's maps, with Shop ticked, whose counter is this shop, the map each stands on, and the region it prices by.

A shop's name is the villager's tag or kind: a villager tagged smith_bryn trades from the shop named smith_bryn, else from the shop named for their kind, else from default. A shop with no wares is passed over unless its merchant only buys.

The Shop Editor and the NPC Portfolio's Shop Stock tab edit the same file the same way, and every change is saved as it is made. Shop Stock has a Shop Editor button that opens the villager's shop there.

A shop's look

Layout
How the counter lays out its wares. List: a window with one row per ware, the price on the right. List and Detail: a window with the rows beside a panel showing the pointed-at ware's picture, name, price, type and description. Grid: a window with a grid of framed slots, six across, a ware's picture in each and its price under it, and the pointed-at ware's name, price and description below. Full Screen: the whole screen, with the item types down the left (All, each type the merchant or the player holds, Other), the wares in columns (count, weight when anything weighs, price), the picked ware large on the right with what it does, and the player's money and the merchant's along the foot. Shops page uses the layout on MONEY > Shops.
Interface style
The style pack the counter wears. Project's is the pack on LOOK > Interface Style.

Opening a counter

A villager with Shop ticked on their NPC Portfolio page trades as soon as the player talks to them. A dialog reply that goes to @shop opens the counter from a conversation, and the shop <npc> verb opens it from any script. A schedule can switch shop on and shop off by the hour.

The counter has two sides. Buy lists the merchant's wares; a click buys one. Sell lists the player's pockets; a click sells one of a stack. Esc closes it.

A counter in the List layout, on the Buy side.
A counter in the List layout, on the Buy side.
A counter in the List and Detail layout. The third ware is paid for in pelts.
A counter in the List and Detail layout. The third ware is paid for in pelts.

The Shops page

Every change is saved to the project's game.vdc as it is made.

Sell price
What a merchant pays for an item, as a percent of its price. 50 unless changed.
Discount per point of the price stat
Where Haggle is on, for each point of the attribute that answers the prices role (Attributes and Leveling), buying costs this many percent less and selling pays this many percent more. 2 unless changed.
Lowest buy price
However high the price stat, buying never costs less than this percent of the price. 60 unless changed.
Highest sell price
However high the price stat, a merchant never pays more than this percent of the price. 90 unless changed.
Faction price swing
The most a merchant's opinion of the player moves a price, as a percent either way. 20 unless changed.
Standing per 1% of swing
How many points of standing move the price by one percent. 5 unless changed, so a standing of 100 is 20 percent.
Merchants have their own money
Off: merchants never run out of money, as in every game before. On: each counter starts with its merchant's Starting funds, a sale the merchant cannot pay for is refused ("Brenna has only 12 gold."), what the player spends is added to their money, and the save keeps it.
Restock every
After this many game days, a merchant's counted wares refill. never (0, or blank) turns it off.
Haggle
On: every counter shows a Haggle button.
Haggle with
The attribute the haggle rolls. The price stat is whichever attribute answers the prices role.
Haggle difficulty
The number a d20 roll plus the attribute's modifier must reach, the same quiet stat check a dialog reply rolls. 12 unless changed.
Haggle discount
What a won haggle takes off the price of everything bought on this visit, as a percent. 10 unless changed.
Layout
The layout of every counter whose shop has none of its own: List, List and Detail, Grid, or Full Screen. List unless changed.

The WORDS rows at the top rename the counter's two sides, Buy and Sell.

A merchant's own settings

NPC Portfolio > Edit Inventory > Shop Stock opens with the merchant's settings above the two panes. A blank box uses the Shops page; the page's number shows in it, dimmed.

Starting funds
The money in their purse, used when Merchants have their own money is on.
Sell price
What this merchant pays, as a percent of an item's price. Blank uses the Shops page.
Markup
Added to everything this merchant sells, as a percent. 0 is none; a negative markup is a cheaper merchant.
Buy only
They sell nothing. The counter opens on its Sell side and has no Buy side.
Sell only
They buy nothing from the player; the counter only offers its stock. Buy only and Sell only exclude each other.
Infinite stock
Every ware the stock file lists is uncounted, and a ware never sells out.
Buys
The item types they take. Everything takes every item priced above 0; pick one or more types (Sword, Axe, Chestplate) and they refuse the rest ("They don't buy that.").
Faction
Whose prices they use. Their own is the Faction on the merchant's placed character or their kind; pick a party to price as that party does.
Restock every
Game days before their counted wares refill. Blank uses the Shops page; 0 is never.
Haggle
Shops page follows the page; On or Off decides for this merchant alone.

A ware's price, currency and costs

Each ware in the stock pane has a second line.

Price
The ware's own price. Blank (the item's catalog price shows, dimmed) uses the item's price. The price rules below still apply to it.
Costs
Items the player hands over to buy it: 3 Wolf Pelt, or several joined with + (40 gold is not typed here; the money is the Price). Type an item's name or its id; a name the catalog does not know leaves the costs as they were.
Currency
The currency the Price is paid in, a row of MONEY > Currencies. Click it to step through the project's currencies.

This is barter on the same counter. A ware whose Price is 0 and whose Costs say 3 Wolf Pelt is bought with three pelts and no money. A ware priced 40 with Costs 1 Iron Key takes both. The price column on the counter shows what it takes: 12 g, 12 tokens, 3 Wolf Pelt, 40 g + 1 Iron Key.

Buying checks every part first. When the player is short, nothing is taken and the counter says what is missing ("You are short 2 Wolf Pelt."). When the player has it all, the items leave their pockets, the money leaves their purse, and the ware joins their pockets. Items paid as costs are used up; they do not join the merchant's wares. A merchant's own money counts only the main currency.

Quantities and restocking

A ware with a count sells that many; the last one sold takes it off the counter. Press - on a count of 1 to make it unlimited (an infinity sign shows) and + to give it a count again. What the player sells to a merchant joins their wares and can be bought back.

With restocking on, the days count from the first trade at that counter. On the first visit after they have passed, every counted ware of the stock file is back to its count (a ware the player sold them more of keeps the higher count), the wares the player sold them stay, and the days start again. Days pass with the world clock and with resting. In a project whose sun stands still, played time counts instead, twenty minutes to a day, and an event's time that takes the hour past midnight counts one day more. A time never sets a counter's clock back.

The price formula

What a merchant charges for a ware:

  1. Start from the ware's own Price, or the item's price.
  2. In a region, work it through the region's market: its price rate for the item and the item's supply there (below).
  3. Add the merchant's Markup, and the region's.
  4. Add the faction swing: the merchant's party's standing with the player, divided by Standing per 1% of swing, as a percent, at most Faction price swing either way. Liked is cheaper; disliked is dearer. A merchant with no party prices by whose ground the player is on (Factions and Reputation).
  5. Where Haggle is on for this counter, take off Discount per point for every point of the price stat, never below Lowest buy price percent of step 4.
  6. Take off this visit's haggle discount, after a won haggle.

The answer is a whole number and at least 1, unless the ware's own Price is 0.

What a merchant pays for an item: its price (through the region's market, in a region), with the faction swing the other way (liked, they pay more), times the Sell price plus, where Haggle is on, Discount per point for every point of the price stat, at most Highest sell price percent. The Sell price is the merchant's own, else the region's, else the Shops page's. At least 1. An item priced 0 is refused.

For example, with Haggle on, the other numbers unchanged and no regions, a player with 3 points of the price stat and a standing of 50 with the merchant's party buys a 120 gold sword for 101: 120 less 10 percent is 108, less 6 percent is 101. She sells it for 73: 120 plus 10 percent is 132, times 56 percent is 73.

Prices by region

Want furs cheap in the north and dear on the coast? Tools > Economy... opens the Economy page: the regions, what goods cost in each, and the trade routes between them. A project with no regions prices every counter as above.

A region covers the places you tick on its page: maps, world map zones and event zones. A counter prices by the region its merchant stands in (an event zone first, then the map, then the map's world map zone), unless its shop names a Region in the Shop Editor.

The list on the left holds Economy, the regions and the routes, with New region, New route, Rename, Duplicate and Delete under it.

Economy
Every item's base price and its price in each region right now. On the right, the currencies' names and the market's five numbers below.
A region
Its goods, an item type to a row with its items under it. Type a good's Price (a percent of the item's own) and Supply (the percent it rests at), and read its Supply now and its Market price. On the right: its name, its places, its merchants (Gold, a percent of each one's starting funds; Markup; Sell) and, with Own market ticked, its own five numbers.
A route
From and To, the goods Carried there and Brought back, and its caravan: Every how many days one leaves, how many days it is On the road, whether it is Open, the Path it walks and the Caravan villager who walks it.

Supply is a percent of normal. Every one the player buys in a region takes Impact points off its supply and every one sold puts them back. Each day the supply closes Recovery percent of its gap to where it rests. Low supply raises the price and high supply lowers it, by as much as Exponent says, never below Floor or above Ceiling percent. A new project's numbers: Impact 4, Recovery 50, Exponent 60, Floor 25, Ceiling 400.

A route's caravan takes its goods out of the supply where it leaves and adds them where it arrives, its days on the road later. Cut a route and the goods stop coming; a caravan already on the road never arrives. When the route's Path is on the map the player is on and its villager has a model, the player can watch the caravan walk it.

Scripts move the market too, and every change rides the save:

price <region|here> <item> [amount|-]
Hold an item's price in a region at an amount of the main currency; - lets the region work it out again. Bare, it reads the price.
market <region|here> <item|type> [percent|-]
A region's price rate for an item or a type.
supply <region|here> <item> [n|+n|-n]
A region's supply of an item: a bare number sets it, a sign moves it.
route <id> [on|off|send]
Cut a route, open it again, or send a caravan now.
price(item), supply(item), route(id), inregion(region)
The same, read in a condition. price(region, item) and supply(region, item) read another region.

The Economy page writes assets/data/economy.vfa.

Haggling

With Haggle on, the Buy side shows a Haggle button. Pressing it rolls the haggle once for this visit. A win shows "10% off" on the button and takes that much off every ware bought until the counter closes; a loss shows "No deal". Either way the button does nothing more until the next visit.

Saves

What a counter has become rides the save: its wares as shopstate, its money as shoppurse, and when it last restocked as shoprestock. Each counter is kept by its stock file, so two villagers who share a file share a counter. A save from an older build has no restock line; its counters count their restock days from the moment the save is loaded.

The files

game.vdc holds the Shops page: shopsell, shopperpoint, shopbuyfloor, shopsellcap, shopfactioncap, shopfactiondiv, shoppurse on|off, shoprestock <days>, haggle on|off, hagglestat <attribute key>|none, haggledc, hagglepct and shoplayout list|detail|grid|full. A key that is not there is the number above.

A merchant's stock is assets/data/shops/<tag or kind>.vfa. The purse funds row holds the merchant's settings; each ware row holds one ware:

VordrAsset { AssetType = ShopTable }
comp purse funds -1 -
field amount 500
field sell 60
field markup 10
field buys sword axe chestplate
field faction ironoak
field restock 7
field haggle on
field layout grid
field uistyle fable
comp ware iron_sword -1 -
field qty 2
comp ware fur_cloak -1 -
field qty 1
field price 0
field cost wolf_pelt 3
comp ware lodge_signet -1 -
field price 15
field currency marks
amount
Starting funds.
sell, markup, restock
Numbers, as above; absent uses the Shops page (markup: none).
buyonly
on when they sell nothing.
sellonly
on when they buy nothing.
infinite
on when every listed ware is uncounted.
buys
Item type ids, separated by spaces; absent is everything.
faction
A party id; absent is their own.
haggle
on or off; absent follows the Shops page.
layout
list, detail, grid or full; absent follows the Shops page.
uistyle
A style pack's folder name under assets/ui_styles; absent, or a pack that is not installed, wears the project's.
region
A region id from the Economy page; absent prices by where the merchant stands.
qty
How many; absent is unlimited.
price
The ware's own price; absent is the item's.
currency
A currency id; absent is the main currency.
cost
An item id and how many, one line per item, up to eight.

A file with none of these fields sells as every counter always has. An older build reads only ware and qty.