Advanced AI

Hello there.
I’m currently working alone on a mmorpg game (I know it’s hard and things like that, but I already decided to start this game as I have plenty of ideea how to give players unlimited content and things to do, not only getting level cap and deleting the game.

Now about my problem. I got to NPC/Quest part system, where I want to implement some special Artificial Intelligente. What I mean by it is that when a player approach to a NPC (it can be villiger, merchant, shop or any other NPC) and type something in chat, like Hello there or anything, it would respond to him.
I know how to implement basic phrase detection, but I want to do something like if player is at a x meters distance and is typing something related to him, it would check for key words like “Quest”, “mission”, “sell”, “buy” it would access player’s stats like “age”, “name”, “crafting job”, “job”, “class”, “battle stats” and so on and depending on those combination, it would respond to him or do some actions.

For example. A player, which is 39 age, name “Bob” Crafting job “WoodCutter”, Job “Worker at xx company”, Class “Mage”, Battle Stats “atk: xx, def: xx” … and if Bob will type “Hello Bill” (Bill is NPC’s Name, which is woodcutter promoter) the NPC will say something like “Hello There Bob, How are you today?”. Now bob should type “I’m fine, just want to increase my job level. Now, after checking the phrase for “Increase, job, level”, it would check Bob’s job level and his “feedback” (something which he will get after each successfull action from this job) it would say like: “Oh, as I can see, your job level is 5, pretty bad huh? Looking at your feedback, I can say that you deserve around level 8. Would you accept to increase your job level to 8?” After that, depending on Bob’s answer (if yes, it would say something like: “Done, have a nice day Bob” and perform the increase level on bob, If no, it would ask which level bob wants and if it’s higher then the max level calculated by the NPC, it would say something like: Sorry, I can’t help you with that”, if the level is lower then the max level calculated, npc will respond with another phrase and increase level by bob’s value.).

Well, it was a really long example.
I think you already understand what my problem is: How can I check the phrase for keywords, make responses by NPC depending on it (I don’t want standart phrases for each “type” of stats and thing like that, I want the entire phrash to be “created” by NPC depending on those factors).

Also, I want to use it also in getting quests.
Instead of old-fashion questing system, I’m using a fully-auto system, which require player to actually interact with NPC, not only accept/complete.
On that system, what I really want is also to read the “player input”.

I know it’s a lot xD but there might be someone good at AI which could explain me the basics of which I want here.

@TonyLi has a couple of assets in the store for NPCs and quest generation that may fit.

It’s also worth checking out game AI by example by m buckland.

1 Like

I want to pick on your game design for a moment… The idea of talking to an NPC is interesting, but has several major problems.

  1. Key words… how will the player know what they are? How will they work it non-English languages (ill give you a hint, it wont - unless you happen to be a linguistic master)

  2. Typing… The number of gamers who want to sit there typing messages to an NPC is very limited. Players want instant gratification these days. Players can easily get lost when all they have to do is read some text and accept. How often do most people spend reading quest text? 0-1 seconds (long enough to click the button at the bottom). Not everyone does this, but most people will in mmos, especially after a few quests.

Of course my biggest concern is that youre trying to create an MMO when you cant write your own text parser, basic ai stuff…

These are the junior development level tasks. Who’s gonna do the heavy lifting in your project? Just food for thought.

1 Like

Thanks for answers.
@JamesLeeNZ Well, basically first I want to put everything up, “writte on paper” the whole game plan, everything and after it learning side by side. I already did the basic movement/stats/lore system.

Mainly, the game will be based on english language, but for non-english languages, if NPC will “find” his name in any of those phrases and he won’t recognize any of the keywords, he will basically say something like “I understand only english” or things like that.
I agree, this typing system is far from being perfect, but at last for me, both as a dev and as a player, it’s a bit booring the traditional quest window.

About the reading quest text, that’s why there won’t be any text quest.
Requesting the quest (through typing) will initiate an audio event which will “say” the entire quest dialogue.
Some of the missions, will initiate a world event, so everyone will hear it and will be able to accept aswell by typing.

I’m really bad at text parsers, and things like that, that’s why I’m not really good at that. After finishing game plan, I’ll see which skills I need to start full development of each part (including skill system, quest system) and learn them.

@Kiwasi Thanks for the answer, I’ll check out those examples.

Any advice which would help me with those problems will be good.
Thanks.

nooooo… you cant do that. You cannot have audio for every dialogue… for one it would make your game FARKING GINORMOUS (file size). Unless you plan on using a text to voice thing. Also deaf people.

Have you ever played any text based games?

Im trying to help you by putting you off wasting year(s) on a game you will never finish. Why MMORPG? Honestly, you should start smaller. Much smaller.

3 Likes