Using Certain Dialogue Options for Specific Events

I have an ambitious dialogue system I'm envisioning and I understand the randomized dialogue with variables and such.

What I want it to do is when you talk to a person it will pull up a random greeting like "Hey!" or "Whats up!" and then proceeds to let you respond leading to another randomized response like "Hey have you seen (Show Topic)" or "I tried some (Meal Topic) it was so tasty.". Obviously this could be made to be very extensive, but the two main things I need help with is Firstly.

I want to know how to limit the randomized greetings with the event. To better explain it for an example there will be normal people that will draw from a general greetings pool, but some people might be rude so they will draw from a rude greeting pool like saying "Whats your problem?", and still others might have special greetings like Familial ones such as "Hey Sis!". Where I am needing guidance is some events might be able to have several options for which greeting pools they can draw from and based on your relationship with the event it might add in friendly or rude greetings. So could I exclude options from an array or is there a better method for what I want.

The next aspect is the (Topics).
What I envision is each character event will have certain likes and dislike a feature in a lot of games with relationship values. I want to be able to declare how these characters feel about things even adding some if your character triggers an event with them like "Watching a show together event" or "Offering them a meal event" It would be based off of outside values like tastes and stuff and the result could be it adds a like, a dislike, or experienced. This adds the thing into a list of that event's (Topics).

Now when you chat with the character event it will choose a random (Topic) from their list and based off of the topic and how they feel about it I want it to generate randomized chatter like "Man! have you seen that show (Show Topic) it is too dumb for me." or "I never miss an episode of (Show Topic) I love it." I guess this would need to be a global array or something.

I want to make a script or something so I can just call the script and give it parameters like this character (Greets Normally, or Greets Friendly, and Likes This, This, and Dislikes This, and Its Topics are These). With Yanfly's scripts I hope to have it so the events can converse with themselves showing dialogue over two events if they get close enough.

Imagine 50+ ways to say Hi, 100+ ways to say I like something, different randomized responses based off of how you reply affecting your relationship with the character. It would feel like actual small talk.

It is frustrating because I know what I want just not HOW to do it.
Handling that inside the editor or the regular engine is effectively impossible.
The number of conditional branches is simply too high as soon as you want more than one or two different responses.

I know a way to handle this by a combination of external text files and random indices, but the plugins for that do not exist yet - and I haven't had the time and money to commission them (which is on my to-do, but that doesn't help you).

Basically you have to get a plugin that adds new replacement textcodes into the show text command, and uses the textkey of that textcode to select one of several lines from the external text files to display in place of the text key.

SES External Text (script for Ace) and Iavra Localisation (plugin for MV) both do the first step, but are lacking the randomizer for the second step. And both programmers are rarely seen anymore on this forum...
This sounds a little bit like my Rem plugin or MoonFlower plugin. Take a look at those at Endless Illusion Software.
Chatter Example.png

See this is how I want it to go. After greeting it will give the player the option to chat, inquire, or request. chatting brings up the chatter topics and then you'll need to respond. Each response affecting your friendship with the character. All parts of this having several similarly ambiguously phrased varieties. Think of the possibilities.

That is why I want to make a script to do this all. So I just have to declare some parameters and call the script, and I could use it for every character, and I doubt such a thing exists so any programmers can you give me advice. Give me somewhere to start.

What sort of methods would you use?
What sort of java scripting methods should I research?

I was thinking a simple randomly generated variable could determine which dialogue is displayed 1=this 2=this. Do you think there is a better way.

How can I make different dialogue pools.
How can I declare parameters like the person's likes, and personality that will determine which responses dialogue pools it will draw from.

And if all else fails who should I commission for this.
Okay, I understand what you're trying to do to a degree. Sounds like complex dialogue trees. Doing trees in MV is a pain but my plugin provides a randomization text code which allows you to effectively have randomized greetings and dialogue.

The thing is what you want should be broken up into several systems.

Characters which feature information on each character such as likes and dislikes.

Dialogue system which uses trees to stem real conversation if you want back and forth dialogue. Both events would need to share some sort of connection.

What you showed me above is an example of that, it's a lot more complex and would require more than just a couple variables and JavaScript parameters.
I've been looking into a similar functionality for MV. What I've arrived to is that you need to classify how the talked-to see the talking character.
This should give you an idea of definition of conversation type and how to address the speaker.
Example:
Generic Line (nice): Good morning (x)
Generic Line (rude): What do you want now, (x))
X is how the spoken-to sees your character. This can be blank, for very generic, or something like "sis", per your example... or if you want to go very rude, or spunky, use "" as X. It would kind of work for both examples above... barely. =)
Once you've broken down your talking options, you have to think in terms of NPCs: there are those with all the generic content, and there are those with "special" conversations (ex: quest related).
I would strongly suggest you take as a practice example "local guards" and/or "shop owners" and try to apply your model to those kinds of NPCs. If it works for those, you would need only small adjustments to fix anyone else into. Thinking in those terms have helped me define my own project.

Original thread: https://forums.rpgmakerweb.com/threads/using-certain-dialogue-options-for-specific-events.86995/