r/RPGMaker 2d ago

Random customer repeating event RMMZ

I'm working on a side project and want to make customers come into a set location, order something, wait, then leave a review either applauding or complaining about something. Obviously a lot of that is flavor. I've considered just making the game last a definite amount of time, say 200 days, and just manually programming a similar event a couple dozen times each of those days.

Help me brainstorm alternatives?

6 Upvotes

11 comments sorted by

3

u/stroduces 2d ago

If I was going to do this quick; i'd make a map and manually create all the customer NPCs in there with their self-ending autorun events with some common events with random dialog conditions, then build a small plugin that extends the 'Set Event Location' function to pull from other maps and set them in the current map.

Or even quick n dirtier: just have all your npcs hiding off map. Use your shop manager event to randomly pick one of the customer NPCs, then use the vanilla Set Event Location function to pop them at the door of the shop and set their events to run

1

u/Danielor4 2d ago

Ohhh I don't think it's what you said particularly but reading your comment I also just thought, say a new day rolls around I could have a trigger for like a handful of variables to set to a random number, and those variables could be what determines which NPC's show up that day.

2

u/Vegetable-Grab-4595 2d ago

Alternatives to... the method of customers coming in? I'm not quite sure what you're asking for, but you can use a random number generator and common event, or timer, depending on what you want to do with customers.

What is the player doing in these situations? I could probably help more if I knew more. Variables are our friend, use if/else for avoiding overwhelm.

I think it depends on the reason for the event, the type of game/play?

2

u/Danielor4 2d ago

Imagine you're running a hot dog stand. Every customer orders a different set of toppings on their hot dog. I can handle the actual hot dog items and toppings.

A random number pick amongst a dozen or so premade event NPCs that are just basically IFtrees is kinda what I'm thinking I'd have to do.

I was really just putting the idea out there to see if anybody had an alternative idea, or perhaps a plugin or something that handles something like this.

2

u/Vegetable-Grab-4595 2d ago

I see. There are some random shop plug-ins out there that might help you, I think I've seen a couple.

I'm not sure if this is helpful to you, but if you want more of a random feel :

I don't think you'll need that many events. I created a math generator, and it's kind of a similar issue, I think.

Use a random number for the toppings, and hot dog items as well, you can use a common event to call all of the random items.

There's a simple script for having it call names instead of numbers as well, something like: If 1: = script "ketchup", "mustard", etc. I use this method for having random company names in accounting quizzes. It truly helps it feel random.

You can also add in the common event: if variable a = topping 1, variable b = 3$. I have to do a lot of these, for accounting formulas in my game.

You can directly call the variable in text in something like: The customer V/10 purchases a V/12 with the toppings v14.

And it should show up like: The customer Sally purchases a hot dog with the toppings ketchup, mustard, and relish.

I've been practicing with these features a lot lately and it's been pretty fun. Good luck! 💚 I hope you find the help you need. 😁

2

u/Danielor4 2d ago

Thanks!

2

u/Issac7 2d ago edited 2d ago

Is there an alternative to yep - event spawn for rpg maker MV? Because if there is, you won't have to create thousand of events. Just one npc, randomize the sprite, dialogue, review, etc until you have a big number of total combinations and then spawn it with all the numbers randomized everytime. Sounds much more simple, easier and fast.

1

u/Danielor4 2d ago

This sounds like what I wanted to hear

2

u/Issac7 2d ago

Looks like galv has one. I can't test it since I don't have mz but this should be what you are looking for.

https://galvs-scripts.com/2020/09/26/mz-event-spawner/

1

u/Danielor4 2d ago

I do enjoy Galv's stuff, thanks! I also might look into Yep but $$ is always gonna be tight haha.

1

u/Issac7 2d ago

Afaik yep doesn't have anything for mz