Trilobytes MZ #1: Limited Stock Shop

Alright, leave that with me and I'll see what stupid really obvious thing I buggered up.
Hey Trihan, just wondering but is it possible to trigger a restock via a switch / variable instead?

So the shop will restock after a certain point in the story instead of after X amount of time?

Thanks 🙂
Hey Trihan, just wondering but is it possible to trigger a restock via a switch / variable instead?

So the shop will restock after a certain point in the story instead of after X amount of time?

Thanks 🙂
That's certainly something I can look at adding!
Also, not sure if it would be too out of your initial scope but it would also be cool if you can add in a function to unlock items once you bought enough X amount from the shop.

Like, buy 10 potions unlock super potions etc.
Version 1.08 is now available, fixing a bug with non-restocking items and adding a new parameter to remove the sell option from purchase-only shops! (these only affect the premium version; the fix isn't needed on the free one since it doesn't have auto-restocking)

Hey Trihan, just wondering but is it possible to trigger a restock via a switch / variable instead?

So the shop will restock after a certain point in the story instead of after X amount of time?

Thanks 🙂
You should already be able to do this via the "Add to Stock" command; just provide the map ID and event ID of the shop that you want to restock in the event where you hit the point in the story it happens.
Version 1.09 is now available! This fixes two rather nasty bugs: first one where the "add shop stock" command could put stock above the set maximum, and another where loading a save from before the plugin was installed would cause a crash. You should now be able to use the plugin at any point without it causing issues! (these only affect the premium version)
Since a fair few people have asked about this, I am pleased to announce there there is now an MV version of this plugin available! (for technical reasons there's no free version, though)
Oh, wow! Thank you so much for making this, Trihan! Will this work with VisuStella shop plugins too?
˶ᵔ ᵕ ᵔ˶
Oh, wow! Thank you so much for making this, Trihan! Will this work with VisuStella shop plugins too?
˶ᵔ ᵕ ᵔ˶
The MZ version should be compatible with VisuStella, yes.
I am working with your plugin and am unclear on what it should look like to define stock in one place, but then access that shop from other maps. My intention is to run a map event that sets the shop up, and then run other events in the same map and on other different maps to run the same shop with the same inventory as the set up shop. My expectation is that buying from any of the shops from the map events would deplete the inventory from any of the other map events, but what I am seeing is that accessing the shop from a map event on a map different from the one it was set up on gives a blank inventory. I have checked the save files, and the data looks to be correctly set up, but when running the shop from a second map, the inventory disappears. I am explicitly setting the map and event ids in the shop events, but not setting the inventory outside of the initial setup. Is there an example you could point me to?
I have resolved my issue and in resolving have come to understand my use case is not supported out of the box.

Original thread: https://forums.rpgmakerweb.com/threads/trilobytes-mz-1-limited-stock-shop.147304/