While practicing and trying to get better at scripting, this little snippet was created. This script allows you to implement random shops in your game. Please note that I am not the best scripter out there. I also like to keep my scripts simple. This system is designed to use the same notetags as Galv's Random Loot and will interlock with my other scripts (Random Drops, Simple Rarities) later on to form a little system (Item Suite).
Get the most recent version (1.0) plus a demo project from my DropBox:
This script allows you to use a script call to randomly generate a shop. Add notetags to items to specify level requirements and rarity values. The shop inventory will be generated automatically according to the party level and the notetags provided for items. Shops can sell items of specific types, subtypes or custom defined families. Using a clever combination of type, subtype and families - you can tailor the random shop to offer only items of a very specific type. Like only Armors of the Small Shield type, or just Weapons of the Sword type and so on.
Note that in this very first version, the shop inventory is re-generated every time a player visits the shop. Persistent shop inventories will be added later. Right now its highly fluctuating - a bit like in Disgaea.
Version 1.0
Limit shops to a maximum amount of items
Include only items of certain rarity and level bounds
Use the <noshop> notetag to prevent items from showing up in the shop.
Modify the shop price +/- by a percentage amount (optional).