🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Crazy decision making idea

Started by
2 comments, last by Saluk 21 years, 10 months ago
Got a crazy idea for decision-making for npcs, and it might have come up in the npcai lists a while ago (I could have easily missed it!), and I wanted to run it by the masters. Probably isn''t really that great of an idea, but anyway... I call it personality wars. You know the old angel and devil on the shoulder? I figured, why not have a devil and an angel in the npc fight for the outcome of each decision making process. We''re looking at high-level not low-level decisions here, although it might work for those as well. Now obviously, just an angel and a devil would not make for a very interesting npc. They would pretty much only choose good or bad morals - nothing in the middle. So what about having a ton of personality traits living in their own little world inside the npc. You would ave greed, jealousy, love, compassion, caution, fear, survival, and so on. What happens is, that every time a decision must be made, all the traits that affect that decision are put in the ring. The different traits become their own little characters, with their own little sets of stats and skills, fighting styles etc. They all battle each other for their very lives! After the battle is over, whichever trait won out translates into the choice that is made. Some choices may call for more than one trait to be on the same team. One more thing - the skills and stats that correspond with each trait change after the battle. Losing traits lose xp, wining traits earn xp. This way, the choices that an npc makes throughout the simulation, affect how they are going to choose later on. A character eventually develops out of simple formula. One problem in implementation of course, is that we still have to know when we need to make a decision, and what all our choices are. But situational circumstances can also influence traits. Money lying on the ground is going to bump the greed trait a few notches because it''s so easy to get wihtout consequence. A good implementation would be fairly difficult, but is this a good idea?
Advertisement
This is a variation on the ''mixture of experts'' model used in decision support systems in AI. While it would be an interesting exercise, it would be computationally intractable in a real time system, since for every decision that needs to be made for each character, they would need to wage their internal personaility war.

In the basic MoE model, several different ''experts'' suggest an action (or an analysis of a situation) and the final decision/analysis is a weighted average of these various experts. The weights can be formed in many different ways... based on pass success/experience... applicability of that expert to this problem type, etc.

Cheers,

Timkin
i think you would also need to have some sort of feedback from the environment about whether the "right" decision was made... i''ve put "right" in quotes because it''s obviously a very subjective thing, but consider the following situation:

if your character had the option of staying on the pavement or walking across the road when there''s traffic passing and the personality trait responsible for making him take the risk of crossing anyway wins the battle (call it pt1), the character crosses the road, yeah? if he manages to get safely to the other side then the xp gained by pt1 are fine...

if the character gets hit by a car, however, there would need to be a method of adjusting the xps so that, despite having won the battle previously, pt1 is actually less likely to win it next time because of what happened... if you don''t have that then a character can''t learn from its mistakes and will probably tend to follow a single trait more and more often (as it continues to build up its xp)...

don't sit back and let life take you where it will...
grab it by the horns and wrestle it to the ground...
you'll only end up talking about missed chances if you don't...
[paulfucius, 2002]
Paulus: true. I did also think of having the LOSING traits be the ones who gain xp, which is kind of weird but...

Also, I was thinking more along the lines of major decisions, it doesn''t really fit for all decisions. Then again, if he crosses the road and gets hit by a car, then his survival trait should definately go up, so feedback is important.

Tinkin: Heh, I figured someone had thought of this before. You''re probably right about it being too computationally expensive, and trying to find a way to seperate using MoE for only major decisions, using a different model for minor decisions, is probably more work than it''s worth. I think having a unified system is more appealing to me than trying to combine many systems. Although human beings function with what seems to be an integration of many systems, they all spring out of small simple building blocks.

Thanks for the - FEEDBACK - hehe.
Gotta love feedback.

This topic is closed to new replies.

Advertisement