diff options
Diffstat (limited to 'building_guide/mobs.md')
| -rw-r--r-- | building_guide/mobs.md | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/building_guide/mobs.md b/building_guide/mobs.md index c7331da..745fb49 100644 --- a/building_guide/mobs.md +++ b/building_guide/mobs.md @@ -126,6 +126,26 @@ showing the "Okay" option. See the [Talk section of behaviors](behaviors.md#talk-dialog-trees) for the full dialog tree format, including sequences and conditional nodes. +### Shops + +Give a mob a root-level `shop:` block to make it a shopkeeper. Players trade with +it using the ordinary `list`, `buy`, and `sell` commands from the game prompt. +Prices derive from each item's `value:` field. See the +[Shops section of behaviors](behaviors.md#shops) for the full format, pricing +formula, and stock/restock rules. + +```yaml +name: Shopkeeper +protected: true +hp: 50 +shop: + items: + - item_id: fishing_rod + stock: 10 + - item_id: hammer + stock: 10 +``` + Protected mob with combat stats (for internal testing or debug purposes): ```yaml name: "Guard" |
